Skip to content

Commit

Permalink
Merge pull request #1925 from ibpsa/issue1924_DropdownMediumChoices
Browse files Browse the repository at this point in the history
Issue1924 dropdown medium choices
  • Loading branch information
JayHuLBL authored Aug 30, 2024
2 parents 2930e09 + 59e6930 commit d15193a
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 23 deletions.
31 changes: 18 additions & 13 deletions IBPSA/Fluid/Interfaces/EightPort.mo
Original file line number Diff line number Diff line change
Expand Up @@ -4,39 +4,39 @@ partial model EightPort "Partial model with eight ports"
replaceable package Medium1 =
Modelica.Media.Interfaces.PartialMedium "Medium 1 in the component"
annotation (choices(
choice(redeclare package Medium = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium = IBPSA.Media.Water "Water"),
choice(redeclare package Medium =
choice(redeclare package Medium1 = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium1 = IBPSA.Media.Water "Water"),
choice(redeclare package Medium1 =
IBPSA.Media.Antifreeze.PropyleneGlycolWater (
property_T=293.15,
X_a=0.40)
"Propylene glycol water, 40% mass fraction")));
replaceable package Medium2 =
Modelica.Media.Interfaces.PartialMedium "Medium 2 in the component"
annotation (choices(
choice(redeclare package Medium = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium = IBPSA.Media.Water "Water"),
choice(redeclare package Medium =
choice(redeclare package Medium2 = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium2 = IBPSA.Media.Water "Water"),
choice(redeclare package Medium2 =
IBPSA.Media.Antifreeze.PropyleneGlycolWater (
property_T=293.15,
X_a=0.40)
"Propylene glycol water, 40% mass fraction")));
replaceable package Medium3 =
Modelica.Media.Interfaces.PartialMedium "Medium 3 in the component"
annotation (choices(
choice(redeclare package Medium = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium = IBPSA.Media.Water "Water"),
choice(redeclare package Medium =
choice(redeclare package Medium3 = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium3 = IBPSA.Media.Water "Water"),
choice(redeclare package Medium3 =
IBPSA.Media.Antifreeze.PropyleneGlycolWater (
property_T=293.15,
X_a=0.40)
"Propylene glycol water, 40% mass fraction")));
replaceable package Medium4 =
Modelica.Media.Interfaces.PartialMedium "Medium 4 in the component"
annotation (choices(
choice(redeclare package Medium = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium = IBPSA.Media.Water "Water"),
choice(redeclare package Medium =
choice(redeclare package Medium4 = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium4 = IBPSA.Media.Water "Water"),
choice(redeclare package Medium4 =
IBPSA.Media.Antifreeze.PropyleneGlycolWater (
property_T=293.15,
X_a=0.40)
Expand Down Expand Up @@ -151,9 +151,14 @@ may be used by models that extend this model to treat flow reversal. </p>
</html>", revisions="<html>
<ul>
<li>
August 27, 2024, by Jianjun Hu:<br/>
Corrected dropdown media choice.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/1924\">IBPSA #1924</a>.
</li>
<li>
January 18, 2019, by Jianjun Hu:<br/>
Limited the media choice.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/1050\">#1050</a>.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/1050\">IBPSA #1050</a>.
</li>
<li>July 2014, by Damien Picard:<br/>First implementation. </li>
</ul>
Expand Down
25 changes: 15 additions & 10 deletions IBPSA/Fluid/Interfaces/PartialFourPort.mo
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@ partial model PartialFourPort "Partial model with four ports"
replaceable package Medium1 =
Modelica.Media.Interfaces.PartialMedium "Medium 1 in the component"
annotation (choices(
choice(redeclare package Medium = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium = IBPSA.Media.Water "Water"),
choice(redeclare package Medium =
choice(redeclare package Medium1 = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium1 = IBPSA.Media.Water "Water"),
choice(redeclare package Medium1 =
IBPSA.Media.Antifreeze.PropyleneGlycolWater (
property_T=293.15,
X_a=0.40)
"Propylene glycol water, 40% mass fraction")));
replaceable package Medium2 =
Modelica.Media.Interfaces.PartialMedium "Medium 2 in the component"
annotation (choices(
choice(redeclare package Medium = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium = IBPSA.Media.Water "Water"),
choice(redeclare package Medium =
choice(redeclare package Medium2 = IBPSA.Media.Air "Moist air"),
choice(redeclare package Medium2 = IBPSA.Media.Water "Water"),
choice(redeclare package Medium2 =
IBPSA.Media.Antifreeze.PropyleneGlycolWater (
property_T=293.15,
X_a=0.40)
Expand Down Expand Up @@ -83,20 +83,25 @@ are not implemented.
</html>", revisions="<html>
<ul>
<li>
August 27, 2024, by Jianjun Hu:<br/>
Corrected dropdown media choice.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/1924\">IBPSA #1924</a>.
</li>
<li>
April 6, 2020, by Filip Jorissen:<br/>
Added arrows to the icon indicating the intended flow direction
when <code>allowFlowReversal=false</code>.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/1336\">#1336</a>.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/1336\">IBPSA #1336</a>.
</li>
<li>
January 18, 2019, by Jianjun Hu:<br/>
Limited the media choice.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/1050\">#1050</a>.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/1050\">IBPSA #1050</a>.
</li>
<li>
July 8, 2018, by Filip Jorissen:<br/>
Added nominal value of <code>h_outflow</code> in <code>FluidPorts</code>.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/977\">#977</a>.
See <a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/977\">IBPSA #977</a>.
</li>
<li>
November 12, 2015, by Michael Wetter:<br/>
Expand All @@ -108,7 +113,7 @@ Removed parameters
<code>h_outflow_a2_start</code> and
<code>h_outflow_b2_start</code>.
This is for issue
<a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/299\">#299</a>.
<a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/299\">IBPSA #299</a>.
</li>
<li>
October 30, 2015, by Matthis Thorade:<br/>
Expand Down

0 comments on commit d15193a

Please sign in to comment.