-
Notifications
You must be signed in to change notification settings - Fork 161
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue3618 air filter #3986
Issue3618 air filter #3986
Conversation
@JayHuLBL Could you please review this PR? |
@@ -0,0 +1,27 @@ | |||
within Buildings.Fluid.AirFilters.BaseClasses.Characteristics; | |||
record filtrationEfficiencyParameters |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change name to FiltrationEfficiencyParameters
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The record name has been changed.
@@ -0,0 +1,27 @@ | |||
within Buildings.Fluid.AirFilters.BaseClasses.Characteristics; | |||
record filtrationEfficiencyParameters | |||
"Record for filtration efficiency vs. relative mass of the contaminant captured by the filter" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use versus
, rather than vs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replace versus
with vs.
"Name of trace substance"; | ||
parameter | ||
Buildings.Fluid.AirFilters.BaseClasses.Characteristics.filtrationEfficiencyParameters | ||
filterationEfficiencyParameters |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
may use shorter parameter name, like filEffPar
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Replace filterationEfficiencyParameters
with filEffPar
<p> | ||
The record contains one dataset: | ||
relative mass of the contaminant | ||
(see <a href=\"modelica://Buildings.Fluid.AirFilters.BaseClasses.FiltrationEfficiency\"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it the right link to the right class? I think it should like to Buildings.Fluid.AirFilters.BaseClasses.Characteristics.filtrationEfficiencyParameters
?
Or you may mean The record contains one dataset <Characteristics.filtrationEfficiencyParameters> for <Buildings.Fluid.AirFilters.BaseClasses.FiltrationEfficiency>
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I meant the definition of the relative mass is provided in modelica://Buildings.Fluid.AirFilters.BaseClasses.FiltrationEfficiency
.
I update the document to avoid confusions.
annotation (Documentation(info="<html> | ||
<p> | ||
Data record that describes the relative mass of the contaminant captured by the filter <code>rat</code> versus | ||
the filtration efficiency <code>eps</code>. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Data record that describes the relative mass of the contaminant <code>rat</code> captured by the filter when it has the filtration efficiency specified as <code>eps</code>.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update it as suggested
extends Modelica.Icons.Record; | ||
parameter Real mCon_nominal( | ||
final unit = "kg") | ||
"Maximum mass of the contaminant can be captured by the filter"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maximum mass of the contaminant that can be ...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix the typo.
"Relative mass of the contaminant captured by the filter" | ||
annotation (Placement(transformation(extent={{100,40},{140,80}}))); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
add a protected section to find out the total types of the contaminant
protected
parameter Integer nConSub = size(per.substanceName,1) "Total types of contaminant substances";
and then
change above y[size(per.substanceName,1)
to y[nConSub]
, and below the for loop.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change it as suggested
"Maximum mass of the contaminant captured by the filter"; | ||
parameter Integer nin( | ||
min=1)=1 | ||
"Number of input connections"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you mean the total types of contaminant substances? So can we change the nin
to nConSub
and change the comment to Total number of contaminant substance types
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change it as suggested
parameter Integer nin( | ||
min=1)=1 | ||
"Number of input connections"; | ||
parameter Buildings.Fluid.AirFilters.BaseClasses.Data.Generic per |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there is no need to have the per
parameter. We just need the nominal contaminant mass. Why don't we keep the mCon_nominal
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change it as suggested
@@ -1,26 +1,28 @@ | |||
within Buildings.Fluid.AirFilters.BaseClasses; | |||
model FlowCoefficientCorrection | |||
"Component that calculates the flow coefficient correction factor" | |||
parameter Real b | |||
"Resistance coefficient"; | |||
parameter Buildings.Fluid.AirFilters.BaseClasses.Data.Generic per |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need to instantiate the per
parameter in the base class? I think it may be enough to have the per
been instantiated only in the top level class, i.e. Buildings.Fluid.AirFilters.Empirical
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change it as suggested
annotation (Placement(transformation(extent={{100,40},{140,80}}))); | ||
|
||
protected | ||
parameter Real s1[:,:]= { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can add the parameter nConSub
in the protected section and defined it as nConSub=size(substanceName,1)
. This will avoid calculating the size(substanceName,1)
multiple times.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change it as suggested
</li> | ||
<li> | ||
The <code>extraPropertiesNames</code> has to be defined in the medium model. | ||
when the <code>extraPropertiesNames</code> in the medium model don't contain all the contaminants | ||
defined in the <code>per</code>. | ||
</li> | ||
</ul> | ||
</html>", revisions="<html> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we reference for the model development?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't have a reference.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@SenHuang19 Please see the inline comments.
Thanks a lot! I am working on addressing them now. |
@SenHuang19 Is it ready for review? |
@JayHuLBL Yes it is. |
This PR addresses the comments.