Skip to content

Commit

Permalink
Merge pull request #3909 from SenHuang19/issue3538_Air2Air_recovery
Browse files Browse the repository at this point in the history
Issue3538 thermal wheel
  • Loading branch information
JayHuLBL authored Nov 22, 2024
2 parents 40b5d7c + 1e96958 commit ba6c61e
Show file tree
Hide file tree
Showing 65 changed files with 2,018 additions and 702 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
within Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Characteristics;
record heatExchangerEffectivenessParameters
"Parameters for defining heat exchanger effectiveness at different wheel speed ratios"
extends Modelica.Icons.Record;
parameter Real uSpe[:](each final min=0)
"Wheel speed ratio";
parameter Real epsCor[:](each final max=1)
"Correction of the heat exchange effectiveness at a given speed ratio";
annotation (Documentation(info="<html>
<p>
Data record that describes wheel speed ratio <code>uSpe</code> versus
heat exchange effectiveness corrections <code>epsCor</code>, i.e., the ratio of the heat exchange effectiveness
to that when the <code>uSpe</code> is <i>1</i>.
The elements of the vector <code>uSpe</code> should be in ascending order,
i.e.,<code>uSpe[i] &lt; uSpe[i+1]</code>.
Both vectors, <code>uSpe</code> and <code>epsCor</code>
must have the same size.
</p>
</html>", revisions="<html>
<ul>
<li>
May 28, 2024, by Sen Huang:<br/>
First implementation.
</li>
</ul>
</html>"));
end heatExchangerEffectivenessParameters;
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
within Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Characteristics;
record motorEfficiencyParameters
"Parameters for defining motor efficiency at different wheel speed ratios"
extends Modelica.Icons.Record;
parameter Real uSpe[:](each final min=0)
"Wheel speed ratio";
parameter Modelica.Units.SI.Efficiency eta[size(uSpe, 1)](each final max=1)
"Wheel motor efficiency at a given speed ratio";
annotation (Documentation(info="<html>
<p>
This model describes wheel speed ratio <code>uSpe</code> versus
the motor percent full-load efficiency (see
<a href=\"modelica://Buildings.Fluid.Movers.BaseClasses.Characteristics.motorEfficiencyCurve\">
Buildings.Fluid.Movers.BaseClasses.Characteristics.motorEfficiencyCurve</a>).
It is based on
<a href=\"modelica://Buildings.Fluid.Movers.BaseClasses.Characteristics.efficiencyParameters_yMot\">
Buildings.Fluid.Movers.BaseClasses.Characteristics.efficiencyParameters_yMot</a>.
</p>
</html>",
revisions="<html>
<ul>
<li>
June 11, 2024, by Sen Huang:<br/>
First implementation based on <a href=\"modelica://Buildings.Fluid.Movers.BaseClasses.Characteristics.efficiencyParameters_yMot\">
Buildings.Fluid.Movers.BaseClasses.Characteristics.efficiencyParameters_yMot</a>.
</li>
</ul>
</html>"));
end motorEfficiencyParameters;
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
within Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses;
package Characteristics "Functions for wheel characteristics"

annotation (Documentation(info="<html>
<p>
This package implements performance curves for wheels.
</p>
</html>"));
end Characteristics;
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
heatExchangerEffectivenessParameters
motorEfficiencyParameters
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
within Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Data;
record ASHRAE =
Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Data.Generic
(senHeatExchangeEffectiveness(uSpe={0,0.1,0.2,0.3,0.4,0.5,0.6,0.7,0.8,0.9,1},
epsCor={0,0.40,0.71,0.83,0.90,0.93,0.96,0.97,0.98,0.99,1}),
latHeatExchangeEffectiveness(uSpe={0,0.15,0.3,0.4,0.5,0.6,0.7,0.8,0.9,1},
epsCor={0,0.26,0.37,0.58,0.72,0.81,0.86,0.90,0.96,1}))
"ASHRAE data record for variable-speed thermal wheels"
annotation (Icon(coordinateSystem(preserveAspectRatio=false)), Diagram(
coordinateSystem(preserveAspectRatio=false)),
Documentation(revisions="<html>
<ul>
<li>
May 28, 2024, by Sen Huang:<br/>
First implementation.
</li>
</ul>
</html>", info="<html>
<p>
ASHRAE performance dataset for the variable-speed wheel model.
</p>
<p>
It is developed based on Figure 7 in ASHRAE (2024).
However, the original data set was extrapolated to cover lower values
of speed ratio, i.e. <code> &lt;= 0.2</code>, by setting the heat exchange effectiveness
corrections to 0 when the speed ratio is 0.
</p>
<h4>References</h4>
<p>
ASHRAE (2024).
<i>Chapter 26, Air-to-Air Energy Recovery Equipment, ASHRAE Handbook—HVAC Systems and Equipment.</i>
</p>
</html>"));
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
within Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Data;
record Generic "Generic data record for variable-speed wheels"
extends Modelica.Icons.Record;
import cha = Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Characteristics;
parameter Real P_nominal(final unit="W")=100
"Power consumption at the design condition";
parameter cha.heatExchangerEffectivenessParameters
senHeatExchangeEffectiveness(uSpe={0}, epsCor={0.7})
"Sensible heat exchange effectiveness vs. wheel speed ratio"
annotation (Dialog(group="Heat exchange effectiveness computation"));
parameter cha.heatExchangerEffectivenessParameters
latHeatExchangeEffectiveness(uSpe={0}, epsCor={0.7})
"Latent heat exchange effectiveness vs. wheel speed ratio" annotation (
Dialog(group="Heat exchange effectiveness computation", enable=
haveLatentHeatExchange));
parameter
cha.motorEfficiencyParameters
motorEfficiency(uSpe={0}, eta={0.7})
"Motor efficiency vs. wheel speed ratio"
annotation (Dialog(group="Power computation", enable=useDefaultMotorEfficiencyCurve ==
false));
final parameter
Buildings.Fluid.Movers.BaseClasses.Characteristics.efficiencyParameters_yMot
motorEfficiency_default=
Buildings.Fluid.Movers.BaseClasses.Characteristics.motorEfficiencyCurve(
P_nominal=P_nominal,
eta_max=1)
"Motor efficiency vs. default wheel speed ratio"
annotation (Dialog(group="Power computation", enable=useDefaultMotorEfficiencyCurve ==
true));
parameter Boolean haveLatentHeatExchange = true
"= true, if latent heat exchange occurs";
parameter Boolean useDefaultMotorEfficiencyCurve = true
"= true, if default motor efficiency curve is adopted";

annotation (Documentation(revisions="<html>
<ul>
<li>
May 28, 2024, by Sen Huang:<br/>
First implementation.
</li>
</ul>
</html>", info="<html>
<p>
Record containing power and heat exchange parameters for variable-speed thermal wheels.
</p>
<p>
It is used as a template of performance data
for the variable-speed wheel models in
<a href=\"modelica://Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels\">
Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels</a>.
</p>
<p>
The record contains four datasets:
</p>
<ul>
<li>
the motor efficiency versus wheel speed ratio,
</li>
<li>
the default motor percent full-load
efficiency (see <a href=
\"modelica://Buildings.Fluid.Movers.BaseClasses.Characteristics.motorEfficiencyCurve\">
Buildings.Fluid.Movers.BaseClasses.Characteristics.motorEfficiencyCurve</a>)
versus wheel speed ratio,
</li>
<li>
the sensible heat exchange effectiveness
corrections versus wheel speed ratio,
</li>
<li>
the latent heat exchange effectiveness
corrections versus wheel speed ratio .
</li>
</ul>
<p>
Note that
</p>
<ul>
<li>
When <code>haveLatentHeatExchange</code> is false,
the dataset of the latent heat exchange effectiveness
corrections versus wheel speed ratio is disabled,
</li>
<li>
When <code>useDefaultMotorEfficiencyCurve</code> is true,
the motor efficiency versus wheel speed ratio is disabled
while the default motor percent full-load
efficiency versus wheel speed ratio is enabled.
</li>
</ul>
</html>"));
end Generic;
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
within Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses;
package Data "Performance data for variable-speed wheels"
extends Modelica.Icons.MaterialPropertiesPackage;

annotation (Documentation(info="<html>
<p>
This package contains performance data sets for variable-speed thermal wheels.
</p>
</html>"));
end Data;
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ASHRAE
Generic
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
within Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels;
package BaseClasses "Package with base classes for the variable-speed thermal wheel model"
extends Modelica.Icons.BasesPackage;

annotation (Documentation(revisions="",
info="<html>
<p>
This package contains base classes that are used to construct the models in
<a href=\"modelica://Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels\">Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels</a>.
</p>
</html>"));
end BaseClasses;
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Characteristics
Data
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
within Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels;
model Latent "Enthalpy wheels"
extends Sensible;
Buildings.Controls.OBC.CDL.Interfaces.RealOutput epsLatCor(
final unit="1")
"Latent heat exchanger effectiveness correction" annotation (Placement(
transformation(extent={{100,-100},{140,-60}}), iconTransformation(
extent={{100,-100},{140,-60}})));
equation
epsLatCor = Buildings.Utilities.Math.Functions.smoothInterpolation(
x=uSpe,
xSup=per.latHeatExchangeEffectiveness.uSpe,
ySup=per.latHeatExchangeEffectiveness.epsCor)
"Calculate the latent heat exchanger effectiveness correction";

annotation (
defaultComponentName="latWhe",
Documentation(info="<html>
<p>
This model calculates the power consumption, the sensible
heat exchange effectiveness correction, and the latent
heat exchange effectiveness correction of an enthalpy wheel.
</p>
<p>
The calculation of the power consumption and the sensible
heat exchange effectiveness correction is elaborated in
<a href=\"modelica://Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.Sensible\">
Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.Sensible</a>.
</p>
<p>
The latent heat exchange effectiveness correction is calculated based
on the cubic hermite spline interpolation of the latent heat exchange
effectiveness dataset (see
<a href=\"modelica://Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Characteristics.heatExchangerEffectivenessParameters\">
Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Characteristics.heatExchangerEffectivenessParameters</a>).
</p>
</html>", revisions="<html>
<ul>
<li>
May 28, 2024, by Sen Huang:<br/>
First implementation.
</li>
</ul>
</html>"));
end Latent;
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
within Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels;
model Sensible "Sensible heat wheels"
extends Modelica.Blocks.Icons.Block;
import whe = Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels;
final parameter Real xSpe[:] = if per.useDefaultMotorEfficiencyCurve
then per.motorEfficiency_default.y else per.motorEfficiency.uSpe
"x-axis support points of the power efficiency curve"
annotation (Dialog(group="Efficiency"));
final parameter Real[size(xSpe,1)] yeta = if per.useDefaultMotorEfficiencyCurve
then per.motorEfficiency_default.eta else per.motorEfficiency.eta
"y-axis support points of the power efficiency curve"
annotation (Dialog(group="Efficiency"));
parameter whe.BaseClasses.Data.Generic per
"Record with performance data"
annotation (Placement(transformation(extent={{60,60},{80,80}})));
Buildings.Controls.OBC.CDL.Interfaces.RealInput uSpe(
final unit="1",
final max=1)
"Wheel speed ratio"
annotation (Placement(transformation(extent={{-140,-20},{-100,20}}),
iconTransformation(extent={{-140,-20},{-100,20}})));
Buildings.Controls.OBC.CDL.Interfaces.RealOutput P(final unit="W")
"Electric power consumption"
annotation (Placement(transformation(extent={{100,60},{140,100}}),
iconTransformation(extent={{100,60},{140,100}})));
Buildings.Controls.OBC.CDL.Interfaces.RealOutput epsSenCor(final unit="1")
"Sensible heat exchanger effectiveness correction"
annotation (Placement(transformation(extent={{100,-20},{140,20}}),
iconTransformation(extent={{100,-20},{140,20}})));

initial equation
for i in 1:size(yeta,1)-1 loop
assert(xSpe[i]/yeta[i] < 1 + 1E-4,
"In " + getInstanceName() + ": the motor efficiency curve is wrong.
The ratio of the speed ratio to the motor percent
full-load efficiency should be less than 1",
level=AssertionLevel.error)
"Check if the motor efficiency curve is correct";
end for;
assert(abs(yeta[size(yeta,1)]-1) < 1E-4,
"In " + getInstanceName() + ": the motor efficiency curve is wrong.
The motor percent full-load efficiency at the full seepd should be 1",
level=AssertionLevel.error)
"Check if the motor efficiency curve is consistent with the nominal condition";
equation
P = per.P_nominal*uSpe/Buildings.Utilities.Math.Functions.smoothInterpolation(
x=uSpe,
xSup=xSpe,
ySup=yeta)
"Calculate the wheel power consumption";
epsSenCor = Buildings.Utilities.Math.Functions.smoothInterpolation(
x=uSpe,
xSup=per.senHeatExchangeEffectiveness.uSpe,
ySup=per.senHeatExchangeEffectiveness.epsCor)
"Calculate the sensible heat exchanger effectiveness correction";
annotation (
defaultComponentName="senWhe",
Icon(coordinateSystem(preserveAspectRatio=false)), Diagram(
coordinateSystem(preserveAspectRatio=false)),
Documentation(info="<html>
<p>
This model calculates the power consumption and the sensible heat exchanger
effectiveness correction of a sensible heat wheel.
Specifically, this calculation is configured as follows.
</p>
<ul>
<li>
The power consumption of this wheel is calculated by
<p align=\"center\" style=\"font-style:italic;\">
P = P_nominal * uSpe / eta,
</p>
<p>
where <code>P_nominal</code> is the nominal wheel power consumption,
<code>uSpe</code> is the wheel speed ratio,
and <code>eta</code> is the motor percent full-load efficiency,
which is calculated by
<p align=\"center\" style=\"font-style:italic;\">
eta = eff(uSpe=x) / eff(uSpe=1),
</p>
<p>
where <code>eff(uSpe=x)</code> is the motor efficiency when the speed ratio is <code>x</code>.
The <code>eta</code> is obtained based on the cubic hermite spline interpolation of
the motor percent full-load efficiency dataset (see
<a href=\"modelica://Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Characteristics.motorEfficiencyParameters\">
Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Characteristics.motorEfficiencyParameters</a>).
Please note that <code>uSpe/eta</code> must be less or equal to 1.
</p>
</li>
<li>
The sensible heat exchanger effectiveness correction is calculated based
on the cubic hermite spline interpolation of the sensible heat exchanger effectiveness
dataset (see <a href=\"modelica://Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Characteristics.heatExchangerEffectivenessParameters\">
Buildings.Fluid.HeatExchangers.BaseClasses.VariableSpeedThermalWheels.BaseClasses.Characteristics.heatExchangerEffectivenessParameters</a>).
</li>
</ul>
</html>", revisions="<html>
<ul>
<li>
May 28, 2024, by Sen Huang:<br/>
First implementation.
</li>
</ul>
</html>"));
end Sensible;
Loading

0 comments on commit ba6c61e

Please sign in to comment.