Skip to content
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

Thermal wheels #3554

Open
wants to merge 144 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 14 commits
Commits
Show all changes
144 commits
Select commit Hold shift + click to select a range
3685a5b
first implementation
Sep 28, 2023
12eb4b8
enhance the example by adding one use case
Sep 29, 2023
07dbf26
cleanup
Sep 29, 2023
b149ee5
update the model doc
Sep 29, 2023
c85a367
improve model doc
Oct 9, 2023
0501e4c
update the release note
Oct 9, 2023
bd60f25
Merge pull request #3541 from SenHuang19/issue3538_Air2Air_recovery
JayHuLBL Oct 9, 2023
aa48571
merged master
JayHuLBL Oct 9, 2023
1d1107a
renamed example model, removed obsolete example
JayHuLBL Oct 9, 2023
dc5a245
removed Modelica.Fluid.System
JayHuLBL Oct 10, 2023
7d6d0e0
reverted changes, changed example models name
JayHuLBL Oct 11, 2023
ea482fd
fixed html syntax, corrected release note
JayHuLBL Oct 11, 2023
e2cc156
renamed model
JayHuLBL Oct 25, 2023
9ad06bf
merged master
JayHuLBL Oct 25, 2023
6aa884a
fix typos
Nov 1, 2023
80aa7ed
change parameter names and replace if with approximation
Nov 2, 2023
3b4bddb
reimplement the wheels with different controls
Nov 2, 2023
d0a6f99
fixing naming and icon
Nov 3, 2023
1280ac1
Merge branch 'master' into issue3538_Air2Air_recovery
Nov 8, 2023
6291751
model clean up
Nov 10, 2023
4bfe833
model doc update and clean up
Nov 13, 2023
0c47509
fix issues in examples
Nov 14, 2023
e7720a1
diagram and info updated
Nov 14, 2023
fce7045
model doc enhance
Nov 15, 2023
13e1010
fix typos
Nov 15, 2023
1e772d6
merge the changes from the forked repo
Nov 15, 2023
e596b73
fix html issue and obsolete files
Nov 15, 2023
34a4738
format enhancement
Nov 15, 2023
28288e8
fix model doc
Nov 15, 2023
9043c75
typo fix
Nov 15, 2023
04c4078
Merge branch 'master' into issue3538_Air2Air_recovery
JayHuLBL Nov 27, 2023
2b6df81
Merge branch 'lbl-srg:issue3538_Air2Air_recovery' into issue3538_Air2…
SenHuang19 Nov 28, 2023
0b4a86d
update model doc
Nov 28, 2023
ec1e7c6
model doc update
Nov 29, 2023
2028e45
Merge pull request #3577 from SenHuang19/issue3538_Air2Air_recovery
JayHuLBL Dec 4, 2023
481c258
corrected package order, removed redundant digits
JayHuLBL Dec 4, 2023
f14f28f
improved documentation and the format
JayHuLBL Dec 4, 2023
9804347
fixed html error
JayHuLBL Dec 4, 2023
250f8e3
added git status
JayHuLBL Dec 5, 2023
4296f4a
reverted conf.yml change
JayHuLBL Dec 5, 2023
29e2b79
improved warning messages [ci skip]
JayHuLBL Dec 14, 2023
54ec5d8
improved warning messages [ci skip]
JayHuLBL Dec 14, 2023
1d32a41
renamed connectors [ci skip]
JayHuLBL Dec 14, 2023
e4610fc
removed final for the displayUnit
JayHuLBL Dec 14, 2023
47f9fdf
input limit update and model doc improve
Dec 15, 2023
3cb0b93
Merge pull request #3608 from SenHuang19/issue3538_Air2Air_recovery
JayHuLBL Dec 15, 2023
f8e4d44
improved graphic [ci skip]
JayHuLBL Dec 18, 2023
4b76bcd
add power calculation and remove sensors
Dec 19, 2023
5bc3276
ref data update
Dec 19, 2023
8a466d5
model doc improved
Dec 19, 2023
a76755b
Merge pull request #3615 from SenHuang19/issue3538_Air2Air_recovery
JayHuLBL Dec 19, 2023
cdbaf03
improved comments [ci skip]
JayHuLBL Dec 20, 2023
3291ad3
Merge branch 'master' into issue3538_Air2Air_recovery
JayHuLBL Dec 20, 2023
c50cf08
changed revision note
JayHuLBL Dec 20, 2023
9765dc1
improved error message
JayHuLBL Dec 21, 2023
56163fa
Merge branch 'master' into issue3538_Air2Air_recovery
JayHuLBL Dec 22, 2023
07c23a5
improved text
JayHuLBL Jan 3, 2024
739b7a3
improved comments
JayHuLBL Jan 3, 2024
79ca115
Merge branch 'master' into issue3538_Air2Air_recovery
JayHuLBL Jan 3, 2024
344478b
corrected assertion check
JayHuLBL Jan 3, 2024
c2b9351
Rearranged compoents and connections [ci skip]
mwetter Jan 5, 2024
2dd9393
Added block icon
mwetter Jan 5, 2024
516a325
Corrected typo
mwetter Jan 5, 2024
f8892c9
Corrected typo
mwetter Jan 5, 2024
89bc2a8
Updated assertion message to the same as other models use
mwetter Jan 5, 2024
417263d
Renamed package and models
mwetter Jan 5, 2024
b35367a
Updated comments and default parameter bindings
mwetter Jan 6, 2024
1d88681
Changed dp_nominal to more realistic value
mwetter Jan 6, 2024
e186be0
Removed default values in base class
mwetter Jan 6, 2024
2d2be9d
Moved to Latent package so that Sensible wheels can be added too
mwetter Jan 6, 2024
9716db3
Refactored models to use common base class
mwetter Jan 6, 2024
4c57394
Formatted file
mwetter Jan 6, 2024
18c8160
merged master, correcter package order [ci skip]
JayHuLBL Jan 9, 2024
7ece958
add the sensible wheel package
Jan 10, 2024
3c807aa
model doc update and remove unneeded settings
Jan 10, 2024
0aa1165
add the rest files for sensible wheel
Jan 10, 2024
c9abfbf
update the om scripts
Jan 10, 2024
c51ff77
reference data update
Jan 10, 2024
0b2e9c7
Merge branch 'issue3538_Air2Air_recovery' of https://github.com/SenHu…
Jan 10, 2024
13d5792
model doc update
Jan 12, 2024
6c5932e
release note update
Jan 12, 2024
003bf58
Merge pull request #3636 from SenHuang19/issue3538_Air2Air_recovery
JayHuLBL Mar 1, 2024
22124d8
Merge branch 'master' into issue3538_Air2Air_recovery
JayHuLBL Mar 1, 2024
4c00241
Merge branch 'issue3538_Air2Air_recovery' of https://github.com/lbl-s…
JayHuLBL Mar 1, 2024
4f865a6
changed interface connectors
JayHuLBL Mar 1, 2024
3a63f0a
moved instance to be protected, improved comment
JayHuLBL Mar 4, 2024
d73e1ad
merged master [ci skip]
JayHuLBL Apr 10, 2024
a95f2d2
improved graphics
JayHuLBL Apr 12, 2024
77d6ba5
merged master
JayHuLBL Apr 12, 2024
3cbc5a1
improved text
JayHuLBL Apr 12, 2024
d5549c9
Merge branch 'master' into issue3538_Air2Air_recovery
mwetter Apr 23, 2024
fcff2bf
Improved implementation to avoid non-needed call to regStep
mwetter Apr 23, 2024
5f85b77
Revised implementation and documentation
mwetter Apr 23, 2024
b7c4161
Improved implementation to avoid non-needed call to regStep
mwetter Apr 23, 2024
526249d
Updated comment
mwetter Apr 23, 2024
292edbf
Changed graphical layout
mwetter Apr 24, 2024
ddc8734
Added icons
mwetter Apr 24, 2024
234038d
Updated icon
mwetter Apr 24, 2024
15d5370
Removed connector to itself
mwetter Apr 24, 2024
0fa5da9
Updated release notes
mwetter Apr 24, 2024
dfbe906
Corrected html
mwetter Apr 24, 2024
c973468
Restricted ratio of flow rates
mwetter Apr 24, 2024
40b5d7c
Removed assertion that would trigger each time the fan switches off
mwetter Apr 24, 2024
de43d6c
model implementation improve
SenHuang19 May 6, 2024
40a863c
improve the implementation and examples
SenHuang19 May 8, 2024
e265a62
model improve and clean
SenHuang19 May 9, 2024
c803b24
update the scripts
SenHuang19 May 9, 2024
a11281b
update the reference data
SenHuang19 May 9, 2024
8a14a33
model doc update and example improves
SenHuang19 May 13, 2024
cfdf906
update the power calculation
SenHuang19 Jun 10, 2024
01c29ac
update the model directory
SenHuang19 Jun 14, 2024
0c728c6
update the thermal wheels
SenHuang19 Jun 14, 2024
4c757ae
update scripts
SenHuang19 Jun 14, 2024
d60cb27
update the reference dataset
SenHuang19 Jun 14, 2024
206d94f
improve the model doc
SenHuang19 Jun 17, 2024
c63596a
model doc improve and typo fix
SenHuang19 Jun 20, 2024
030d1cc
reference data update
SenHuang19 Jun 20, 2024
49341ae
model doc update
SenHuang19 Jun 20, 2024
3a28f6d
model doc improve
SenHuang19 Jun 21, 2024
84f9d01
format update
SenHuang19 Jun 22, 2024
822e498
format update
SenHuang19 Jun 22, 2024
5711f57
minor changes to model implementation
SenHuang19 Jun 24, 2024
81b0f28
reference data update
SenHuang19 Jun 24, 2024
1af8bcb
minor change
SenHuang19 Jun 24, 2024
3b4309d
model doc update
SenHuang19 Jul 5, 2024
df18e6b
improve the model doc
SenHuang19 Aug 14, 2024
37f3c7d
model doc improve
SenHuang19 Aug 30, 2024
ee21c9f
model doc update
SenHuang19 Sep 3, 2024
4da862d
change the performance dataset into parameters
Sep 26, 2024
0b7f334
minor doc format update
SenHuang19 Sep 27, 2024
d27b421
fix typos
Nov 22, 2024
1e96958
update reference
Nov 22, 2024
ba6c61e
Merge pull request #3909 from SenHuang19/issue3538_Air2Air_recovery
JayHuLBL Nov 22, 2024
78303a3
use abs path
Dec 3, 2024
c2ef139
improve model doc
Dec 3, 2024
cbe53f4
fix typo
Dec 3, 2024
78ad81d
improve implementation
Dec 3, 2024
d231f09
update refer
Dec 3, 2024
433a7f6
avoid issues in running regression test
Dec 3, 2024
f316242
Merge pull request #4070 from SenHuang19/issue3538_Air2Air_recovery
JayHuLBL Dec 11, 2024
f734d4e
merged master
JayHuLBL Dec 11, 2024
2ed8ca9
updated references
JayHuLBL Dec 11, 2024
017d710
unified the tolerance
JayHuLBL Dec 11, 2024
38263a3
corrected pacakge order
JayHuLBL Dec 11, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,165 @@
within Buildings.Fluid.HeatExchangers.AirToAirHeatRecovery.BaseClasses;
model Effectiveness
"Model for calculating the heat exchange effectiveness of heat exchangers"
extends Modelica.Blocks.Icons.Block;

parameter Modelica.Units.SI.Efficiency epsS_cool_nominal(max=1) = 0.8
"Nominal sensible heat exchanger effectiveness at the cooling mode";
parameter Modelica.Units.SI.Efficiency epsL_cool_nominal(max=1) = 0.8
"Nominal latent heat exchanger effectiveness at the cooling mode";
parameter Modelica.Units.SI.Efficiency epsS_cool_partload(max=1) = 0.75
"Partial load (75%) sensible heat exchanger effectiveness at the cooling mode";
parameter Modelica.Units.SI.Efficiency epsL_cool_partload(max=1) = 0.75
"Partial load (75%) latent heat exchanger effectiveness at the cooling mode";
parameter Modelica.Units.SI.Efficiency epsS_heat_nominal(max=1) = 0.8
"Nominal sensible heat exchanger effectiveness at the heating mode";
parameter Modelica.Units.SI.Efficiency epsL_heat_nominal(max=1) = 0.8
"Nominal latent heat exchanger effectiveness at the heating mode";
parameter Modelica.Units.SI.Efficiency epsS_heat_partload(max=1) = 0.75
"Partial load (75%) sensible heat exchanger effectiveness at the heating mode";
parameter Modelica.Units.SI.Efficiency epsL_heat_partload(max=1) = 0.75
"Partial load (75%) latent heat exchanger effectiveness at the heating mode";
parameter Modelica.Units.SI.VolumeFlowRate v_flow_sup_nominal(min = 100*Modelica.Constants.eps)
mwetter marked this conversation as resolved.
Show resolved Hide resolved
"Nominal supply air flow rate";

Modelica.Blocks.Interfaces.RealInput TSup(
final min=0,
final unit="K",
final displayUnit="degC")
"Supply air temperature"
annotation (Placement(transformation(extent={{-140,20},{-100,60}})));
Modelica.Blocks.Interfaces.RealInput TExh(
final min=0,
final unit="K",
final displayUnit="degC")
"Exhaust air temperature
" annotation (Placement(transformation(extent={{-140,-20},{-100,20}})));
Modelica.Blocks.Interfaces.RealInput v_flow_Sup(final unit="m3/s")
"Volumetric flow rate of the supply air"
annotation (Placement(transformation(extent={{-140,-60},{-100,-20}})));
Modelica.Blocks.Interfaces.RealInput v_flow_Exh( final unit="m3/s")
"Volumetric flow rate of the exhaust air"
annotation (Placement(transformation(extent={{-140,-100},{-100,-60}})));
Modelica.Blocks.Interfaces.RealInput y(final unit="1") "Wheel speed ratio"
annotation (Placement(transformation(extent={{-140,60},{-100,100}})));
Modelica.Blocks.Interfaces.RealOutput epsS(final unit="1")
"Sensible heat exchanger effectiveness"
annotation (Placement(transformation(extent={{100,30},{120,50}})));
Modelica.Blocks.Interfaces.RealOutput epsL(final unit="1")
"Latent heat exchanger effectivenessr"
annotation (Placement(transformation(extent={{100,-50},{120,-30}})));

protected
Real vRat
"Ratio of the average operating volumetric air flow rate to the nominal supply air flow rate";

algorithm
// calculate effectiveness
if TSup > TExh then
// cooling mode
epsS :=y*(epsS_cool_partload + (epsS_cool_nominal - epsS_cool_partload)*(
vRat-0.75)/0.25);
epsL :=y*(epsL_cool_partload + (epsL_cool_nominal - epsL_cool_partload)*(
vRat-0.75)/0.25);
else
// heating mode
epsS :=y*(epsS_heat_partload + (epsS_heat_nominal - epsS_heat_partload)*(
vRat-0.75)/0.25);
epsL :=y*(epsL_heat_partload + (epsL_heat_nominal - epsL_heat_partload)*(
vRat-0.75)/0.25);
end if;
mwetter marked this conversation as resolved.
Show resolved Hide resolved
epsS := Buildings.Utilities.Math.Functions.smoothMax(
x1 = 0.01,
x2 = epsS,
deltaX = 1E-7);
epsS := Buildings.Utilities.Math.Functions.smoothMin(
x1 = 0.99,
x2 = epsS,
deltaX = 1E-7);

epsL := Buildings.Utilities.Math.Functions.smoothMax(
x1 = 0.01,
x2 = epsL,
deltaX = 1E-7);
epsL := Buildings.Utilities.Math.Functions.smoothMin(
x1 = 0.99,
x2 = epsL,
deltaX = 1E-7);

equation
// check if the extrapolation goes too far
assert(v_flow_Sup - 2*v_flow_Exh < 0 or v_flow_Exh - 2*v_flow_Sup < 0,
"Unbalanced air flow ratio",
level=AssertionLevel.warning);
// calculate the average volumetric air flow and flow rate ratio
vRat = (v_flow_Sup + v_flow_Exh)/2/v_flow_sup_nominal;
// check if the extrapolation goes too far
assert(vRat > 0.5 and vRat < 1.3,
"Operatiing flow rate outside full accuracy range",
mwetter marked this conversation as resolved.
Show resolved Hide resolved
level=AssertionLevel.warning);
annotation (Icon(coordinateSystem(preserveAspectRatio=false), graphics={Text(
extent={{-54,28},{50,-40}},
textColor={28,108,200},
textString="eps")}), Diagram(
coordinateSystem(preserveAspectRatio=false)),
defaultComponentName="EffCal",
Documentation(info="<html>
<p>
This block calculates the sensible and latent effectiveness of the heat exchanger
for heating and cooling conditions at different air flow rates of the supply
air stream and the exhaust air stream.
</p>
<p>
It first calculates the average volumetric air flow rate through the heat exchanger by:
</p>
<pre>
v_ave = (v_sup + v_exh)/2,
vRat = v_ave/v_sup_nom,
</pre>
<p>
where <code>v_ave</code> is the average volumetric air flow rate,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See how we otherwise refer to volume or mass flow rates. (Moreover, if you were to use mass flow rate, then the sensor would be simpler, and the result would in my opinion not change much if at all).

<code>v_sup</code> is the air flow of the supply air stream,
<code>v_exh</code> is the air flow of the exhaust air stream,
<code>v_sup_nom</code> is the nominal air flow of the supply air stream and
<code>vRat</code> is the flow ratio.
</p>
<p>
It then calculates the sensible and latent effectiveness by:
</p>
<pre>
epsS = y * (epsS_75 + (epsS_100 - epsS_75) * (vRat - 0.75)/0.25),
epsL = y * (epsL_75 + (epsL_100 - epsL_75) * (vRat - 0.75)/0.25),
</pre>
<p>
where <code>epsS</code> and <code>epsL</code> are the effectiveness
for the sensible and latent heat transfer, respectively.
<code>epsS_100</code> and <code>epsS_75</code> are the effectiveness
for the sensible heat transfer when <code>vRat</code> is 1 and 0.75, respectively.
<code>epsL_100</code> and <code>epsL_75</code> are the effectiveness
for the latent heat transfer when <code>vRat</code> is 1 and 0.75, respectively.
<code>y</code> is an effectiveness associated with the speed of a rotary wheel.
</p>
<p>
<code>epsS_100</code>, <code>epsS_75</code>, <code>epsL_100</code>, and
<code>epsL_75</code> are parameters.
Depending on the cooling or heating mode, their values are different.
In this model, if the supply air temperature is larger than the exhaust air
temperature, the exchanger is considered to operate under the cooling mode;
Otherwise, it is considered to operate under a heating mode.
</p>
<P>
<b>Note:</b> The average volumetric air flow rate should be between 50% and 130% of the nominal supply air flow rate.
In addition, the ratio of the supply air flow rate to the exhaust air flow rate should be between 0.5 and 2.
</P>
mwetter marked this conversation as resolved.
Show resolved Hide resolved
<h4>References</h4>
U.S. Department of Energy 2016.
&quot;EnergyPlus Engineering reference&quot;.
</html>", revisions="<html>
<ul>
<li>
September 29, 2023, by Sen Huang:<br/>
First implementation.
</li>
</ul>
</html>"));
end Effectiveness;
Original file line number Diff line number Diff line change
@@ -0,0 +1,185 @@
within Buildings.Fluid.HeatExchangers.AirToAirHeatRecovery.BaseClasses;
model HeatExchagerWithInputEffectiveness
"Heat and moisture exchanger with varying effectiveness"
extends Buildings.Fluid.HeatExchangers.BaseClasses.PartialEffectiveness(
redeclare replaceable package Medium1 =
Modelica.Media.Interfaces.PartialCondensingGases,
redeclare replaceable package Medium2 =
Modelica.Media.Interfaces.PartialCondensingGases,
sensibleOnly1=false,
sensibleOnly2=false,
final prescribedHeatFlowRate1=true,
final prescribedHeatFlowRate2=true,
Q1_flow = epsS * QMax_flow + QLat_flow,
Q2_flow = -Q1_flow,
mWat1_flow = +mWat_flow,
mWat2_flow = -mWat_flow);

Modelica.Blocks.Interfaces.RealInput epsS(unit="1")
"Sensible heat exchanger effectiveness"
annotation (Placement(transformation(extent={{-140,20},{-100,60}})));
Modelica.Blocks.Interfaces.RealInput epsL(unit="1")
"Latent heat exchanger effectiveness"
annotation (Placement(transformation(extent={{-140,-60},{-100,-20}})));
Modelica.Units.SI.HeatFlowRate QLat_flow
"Latent heat exchange from medium 2 to medium 1";
Medium1.MassFraction X_w_in1
"Inlet water mass fraction of medium 1";
Medium2.MassFraction X_w_in2
"Inlet water mass fraction of medium 2";
Modelica.Units.SI.MassFlowRate mWat_flow
"Water flow rate from medium 2 to medium 1";
Modelica.Units.SI.MassFlowRate mMax_flow
"Maximum water flow rate from medium 2 to medium 1";

protected
parameter Integer i1_w(min=1, fixed=false) "Index for water substance";
parameter Integer i2_w(min=1, fixed=false) "Index for water substance";
Real gai1(min=0, max=1) "Auxiliary variable for smoothing at zero flow";
Real gai2(min=0, max=1) "Auxiliary variable for smoothing at zero flow";

initial algorithm
i1_w:= -1;
i2_w:= -1;
for i in 1:Medium1.nXi loop
if Modelica.Utilities.Strings.isEqual(string1=Medium1.substanceNames[i],
string2="Water",
caseSensitive=false) then
i1_w := i;
end if;
end for;
for i in 1:Medium2.nXi loop
if Modelica.Utilities.Strings.isEqual(string1=Medium2.substanceNames[i],
string2="Water",
caseSensitive=false) then
i2_w := i;
end if;
end for;
assert(i1_w > 0, "Substance 'water' is not present in Medium1 '"
+ Medium1.mediumName + "'.\n"
+ "Check medium model.");
assert(i2_w > 0, "Substance 'water' is not present in Medium2 '"
+ Medium2.mediumName + "'.\n"
+ "Check medium model.");
equation
// Definitions for effectiveness model
X_w_in1 = Modelica.Fluid.Utilities.regStep(m1_flow,
state_a1_inflow.X[i1_w],
state_b1_inflow.X[i1_w], m1_flow_small);
X_w_in2 = Modelica.Fluid.Utilities.regStep(m2_flow,
state_a2_inflow.X[i2_w],
state_b2_inflow.X[i2_w], m2_flow_small);

// mass exchange
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review capitalization and punctuation.

// Compute a gain that goes to zero near zero flow rate.
// This is required to smoothen the heat transfer at very small flow rates.
// Note that gaiK = 1 for abs(mK_flow) > mK_flow_small
gai1 = Modelica.Fluid.Utilities.regStep(abs(m1_flow) - 0.75*m1_flow_small,
1, 0, 0.25*m1_flow_small);
gai2 = Modelica.Fluid.Utilities.regStep(abs(m2_flow) - 0.75*m2_flow_small,
1, 0, 0.25*m2_flow_small);

mMax_flow = smooth(1, min(smooth(1, gai1 * abs(m1_flow)),
smooth(1, gai2 * abs(m2_flow)))) * (X_w_in2 - X_w_in1);
mWat_flow = epsL * mMax_flow;
// As enthalpyOfCondensingGas is dominated by the latent heat of phase change,
// we simplify and use Medium1.enthalpyOfVaporization for the
// latent heat that is exchanged among the fluid streams.
// This is simply added to QSen_flow, while mass is conserved because
// of the assignment of mWat1_flow and mWat2_flow.
QLat_flow = mWat_flow * Medium1.enthalpyOfVaporization(Medium1.T_default);

annotation (
Icon(coordinateSystem(preserveAspectRatio=false, extent={{-100,
-100},{100,100}}), graphics={
Rectangle(
extent={{-70,80},{70,-80}},
lineColor={0,0,255},
pattern=LinePattern.None,
fillColor={0,62,0},
fillPattern=FillPattern.Solid),
Text(
extent={{-62,50},{48,-10}},
textColor={255,255,255},
textString="epsS=%epsS"),
Text(
extent={{-60,4},{50,-56}},
textColor={255,255,255},
textString="epsL=%epsL")}),
preferredView="info",
defaultComponentName="hexInpEff",
Documentation(info="<html>
<p>
This block is identical to
<a href=\"modelica://Buildings.Fluid.MassExchangers.ConstantEffectiveness\">
Buildings.Fluid.MassExchangers.ConstantEffectivenesst</a>,
except that the effectiveness are inputs rather than parameters.
</p>
<p>
This model transfers heat and moisture in the amount of
</p>
<pre>
QSen = epsS * Q_max,
m = epsL * mWat_max,
</pre>
<p>
where <code>epsS</code> and <code>epsL</code> are input effectiveness
for the sensible and latent heat transfer,
<code>Q_max</code> is the maximum sensible heat that can be transferred and
<code>mWat_max</code> is the maximum moisture that can be transferred.
</p>
<p>
This model can only be used with medium models that define the integer constant
<code>Water</code> which needs to be equal to the index of the water mass fraction
in the species vector.
</p>
</html>",
revisions="<html>
<ul>
<li>
September 29, 2023, by Sen Huang:<br/>
Changing the effectiveness from parameters to inputs.
</li>
<li>
April 30, 2018, by Filip Jorissen:<br/>
Set <code>final prescribedHeatFlowRate1=true</code> and
<code>final prescribedHeatFlowRate2=true</code>.<br/>
See
<a href=\"https://github.com/ibpsa/modelica-ibpsa/issues/907\">#907</a>.
</li>
<li>
April 11, 2017, by Michael Wetter:<br/>
Corrected bug as <code>Q1_flow</code> did not include latent heat flow rate.<br/>
This is for issue
<a href=\"https://github.com/lbl-srg/modelica-buildings/issues/704\">Buildings #704</a>.
</li>
<li>
October 14, 2013 by Michael Wetter:<br/>
Replaced access to constant <code>Medium1.Water</code> by introducing
the parameter <code>i1_w</code>, and used a similar construct for
<code>Medium2</code>.
This avoids an error during model check as these constants are not known
in the partial medium model.
</li>
<li>
August 13, 2013 by Michael Wetter:<br/>
Corrected error in the documentation.
</li>
<li>
July 30, 2013 by Michael Wetter:<br/>
Updated model to use new variable <code>mWat_flow</code>
in the base class.
</li>
<li>
January 28, 2010, by Michael Wetter:<br/>
Added regularization near zero flow.
</li>
<li>
October 21, 2008, by Michael Wetter:<br/>
First implementation, based on
<a href=\"modelica://Buildings.Fluid.HeatExchangers.ConstantEffectiveness\">
Buildings.Fluid.HeatExchangers.ConstantEffectiveness</a>.
</li>
</ul>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is a new model which did not start in 2008. PLEASE review your code before it is sent for review.

</html>"));
end HeatExchagerWithInputEffectiveness;
Loading