Collection of models that validate the psychrometrics blocks of the CDL
Information
This package contains models that validate the blocks in
Buildings.Controls.OBC.CDL.Psychrometrics.
The examples plot various outputs, which have been verified against
analytical solutions. These model outputs are stored as reference data to
allow continuous validation whenever models in the library change.
Package Content
Name |
Description |
DewPoint_TDryBulPhi
|
Model to test the dew point temperature computation |
SpecificEnthalpy_TDryBulPhi
|
Model to test the specific enthalpy computation |
WetBulb_TDryBulPhi
|
Model to test the wet bulb temperature computation |
Model to test the dew point temperature computation
Information
This examples is a unit test for the dew point temperature computation
Buildings.Controls.OBC.CDL.Psychrometrics.DewPoint_TDryBulPhi.
Modelica definition
model DewPoint_TDryBulPhi
Buildings.Controls.OBC.CDL.Psychrometrics.DewPoint_TDryBulPhi dewBulPhi
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp phi(
duration=1,
height=1,
offset=0.001)
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Constant TDryBul(
k=273.15+29.4)
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp TDryBul2(
duration=1,
height=35,
offset=273.15+2.0)
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Constant phi2(
k=0.4)
;
Buildings.Utilities.Psychrometrics.TDewPoi_pW TDewPoi
;
Buildings.Utilities.Psychrometrics.X_pTphi X_pTphi(
use_p_in=false)
;
Buildings.Utilities.Psychrometrics.pW_X humRat(
use_p_in=false)
;
Buildings.Controls.OBC.CDL.Continuous.Subtract sub
;
Buildings.Controls.OBC.CDL.Psychrometrics.DewPoint_TDryBulPhi dewBulPhi1
;
Buildings.Utilities.Psychrometrics.TDewPoi_pW TDewPoi1
;
Buildings.Utilities.Psychrometrics.pW_X humRat1(
use_p_in=false)
;
Buildings.Utilities.Psychrometrics.X_pTphi X_pTphi1(
use_p_in=false)
;
Buildings.Controls.OBC.CDL.Continuous.Subtract sub1
;
equation
connect(humRat.p_w,TDewPoi.p_w);
connect(X_pTphi.X[1],humRat.X_w);
connect(TDryBul.y,dewBulPhi.TDryBul);
connect(phi.y,dewBulPhi.phi);
connect(TDryBul.y,X_pTphi.T);
connect(phi.y,X_pTphi.phi);
connect(TDewPoi.T,sub.u2);
connect(dewBulPhi.TDewPoi,sub.u1);
connect(TDryBul2.y,dewBulPhi1.TDryBul);
connect(TDryBul2.y,X_pTphi1.T);
connect(phi2.y,dewBulPhi1.phi);
connect(phi2.y,X_pTphi1.phi);
connect(X_pTphi1.X[1],humRat1.X_w);
connect(humRat1.p_w,TDewPoi1.p_w);
connect(dewBulPhi1.TDewPoi,sub1.u1);
connect(TDewPoi1.T,sub1.u2);
end DewPoint_TDryBulPhi;
Model to test the specific enthalpy computation
Information
This examples is a unit test for the specific enthalpy computation
Buildings.Controls.OBC.CDL.Psychrometrics.SpecificEnthalpy_TDryBulPhi.
Modelica definition
Model to test the wet bulb temperature computation
Information
This examples is a unit test for the dew point temperature computation
Buildings.Controls.OBC.CDL.Psychrometrics.WetBulb_TDryBulPhi.
Modelica definition
model WetBulb_TDryBulPhi
package Medium=
Buildings.Media.Air
;
Buildings.Controls.OBC.CDL.Psychrometrics.WetBulb_TDryBulPhi wetBulPhi
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Constant p(
k=101325)
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Ramp phi(
duration=1,
height=0.95,
offset=0.05)
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Constant TDryBul(
k=273.15+29.4)
;
Buildings.Utilities.Psychrometrics.TWetBul_TDryBulPhi wetBulPhi_BuiLib(
redeclare package Medium=Medium,
approximateWetBulb=true)
;
Buildings.Utilities.Psychrometrics.TWetBul_TDryBulXi wetBulXi(
redeclare package Medium=Medium,
approximateWetBulb=true)
;
Buildings.Utilities.Psychrometrics.X_pTphi x_pTphi
;
Buildings.Controls.OBC.CDL.Continuous.Subtract sub
;
Buildings.Controls.OBC.CDL.Continuous.Subtract sub1
;
equation
connect(x_pTphi.X[1],wetBulXi.Xi[1]);
connect(TDryBul.y,wetBulPhi.TDryBul);
connect(TDryBul.y,wetBulPhi_BuiLib.TDryBul);
connect(TDryBul.y,wetBulXi.TDryBul);
connect(p.y,x_pTphi.p_in);
connect(phi.y,x_pTphi.phi);
connect(p.y,wetBulXi.p);
connect(phi.y,wetBulPhi_BuiLib.phi);
connect(phi.y,wetBulPhi.phi);
connect(p.y,wetBulPhi_BuiLib.p);
connect(TDryBul.y,x_pTphi.T);
connect(wetBulPhi.TWetBul,sub.u1);
connect(wetBulPhi_BuiLib.TWetBul,sub.u2);
connect(sub1.u1,sub.u1);
connect(wetBulXi.TWetBul,sub1.u2);
end WetBulb_TDryBulPhi;