Modelica.Media.Air.MoistAir

Air: Moist air model (190 ... 647 K)

Information

Thermodynamic Model

This package provides a full thermodynamic model of moist air including the fog region and temperatures below zero degC. The governing assumptions in this model are:

All extensive properties are expressed in terms of the total mass in order to comply with other media in this library. However, for moist air it is rather common to express the absolute humidity in terms of mass of dry air only, which has advantages when working with charts. In addition, care must be taken, when working with mass fractions with respect to total mass, that all properties refer to the same water content when being used in mathematical operations (which is always the case if based on dry air only). Therefore two absolute humidities are computed in the BaseProperties model: X denotes the absolute humidity in terms of the total mass while x denotes the absolute humidity per unit mass of dry air. In addition, the relative humidity phi is also computed.

At the triple point temperature of water of 0.01 °C or 273.16 K and a relative humidity greater than 1 fog may be present as liquid and as ice resulting in a specific enthalpy somewhere between those of the two isotherms for solid and liquid fog, respectively. For numerical reasons a coexisting mixture of 50% solid and 50% liquid fog is assumed in the fog region at the triple point in this model.

Range of validity

From the assumptions mentioned above it follows that the pressure should be in the region around atmospheric conditions or below (a few bars may still be fine though). Additionally a very high water content at low temperatures would yield incorrect densities, because the volume of the liquid or solid phase would not be negligible anymore. The model does not provide information on limits for water drop size in the fog region or transport information for the actual condensation or evaporation process in combination with surfaces. All excess water which is not in its vapour state is assumed to be still present in the air regarding its energy but not in terms of its spatial extent.

The thermodynamic model may be used for temperatures ranging from 190 ... 647 K. This holds for all functions unless otherwise stated in their description. However, although the model works at temperatures above the saturation temperature it is questionable to use the term "relative humidity" in this region. Please note, that although several functions compute pure water properties, they are designed to be used within the moist air medium model where properties are dominated by air and steam in their vapor states, and not for pure liquid water applications.

Transport Properties

Several additional functions that are not needed to describe the thermodynamic system, but are required to model transport processes, like heat and mass transfer, may be called. They usually neglect the moisture influence unless otherwise stated.

Application

The model's main area of application is all processes that involve moist air cooling under near atmospheric pressure with possible moisture condensation. This is the case in all domestic and industrial air conditioning applications. Another large domain of moist air applications covers all processes that deal with dehydration of bulk material using air as a transport medium. Engineering tasks involving moist air are often performed (or at least visualized) by using charts that contain all relevant thermodynamic data for a moist air system. These so called psychrometric charts can be generated from the medium properties in this package. The model PsychrometricData may be used for this purpose in order to obtain data for figures like those below (the plotting itself is not part of the model though).


Legend: blue - constant specific enthalpy, red - constant temperature, black - constant relative humidity

Extends from Interfaces.PartialCondensingGases (Base class for mixtures of condensing and non-condensing gases).

Package Content

Name Description
Water=1 Index of water (in substanceNames, massFractions X, etc.)
Air=2 Index of air (in substanceNames, massFractions X, etc.)
k_mair=steam.MM/dryair.MM Ratio of molar weights
dryair=IdealGases.Common.SingleGasesData.Air  
steam=IdealGases.Common.SingleGasesData.H2O  
MMX={steam.MM,dryair.MM} Molar masses of components
Modelica.Media.Air.MoistAir.ThermodynamicState ThermodynamicState ThermodynamicState record for moist air
Modelica.Media.Air.MoistAir.BaseProperties BaseProperties Moist air base properties record
Modelica.Media.Air.MoistAir.setState_pTX setState_pTX Return thermodynamic state as function of pressure p, temperature T and composition X
Modelica.Media.Air.MoistAir.setState_phX setState_phX Return thermodynamic state as function of pressure p, specific enthalpy h and composition X
Modelica.Media.Air.MoistAir.setState_dTX setState_dTX Return thermodynamic state as function of density d, temperature T and composition X
Modelica.Media.Air.MoistAir.setSmoothState setSmoothState Return thermodynamic state so that it smoothly approximates: if x > 0 then state_a else state_b
Modelica.Media.Air.MoistAir.Xsaturation Xsaturation Return absolute humidity per unit mass of moist air at saturation as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.xsaturation xsaturation Return absolute humidity per unit mass of dry air at saturation as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.xsaturation_pT xsaturation_pT Return absolute humidity per unit mass of dry air at saturation as a function of pressure p and temperature T
Modelica.Media.Air.MoistAir.massFraction_pTphi massFraction_pTphi Return steam mass fraction as a function of relative humidity phi and temperature T
Modelica.Media.Air.MoistAir.relativeHumidity_pTX relativeHumidity_pTX Return relative humidity as a function of pressure p, temperature T and composition X
Modelica.Media.Air.MoistAir.relativeHumidity relativeHumidity Return relative humidity as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.gasConstant gasConstant Return ideal gas constant as a function from thermodynamic state, only valid for phi<1
Modelica.Media.Air.MoistAir.gasConstant_X gasConstant_X Return ideal gas constant as a function from composition X
Modelica.Media.Air.MoistAir.saturationPressureLiquid saturationPressureLiquid Return saturation pressure of water as a function of temperature T in the range of 273.16 to 647.096 K
Modelica.Media.Air.MoistAir.saturationPressureLiquid_der saturationPressureLiquid_der Derivative function for 'saturationPressureLiquid'
Modelica.Media.Air.MoistAir.sublimationPressureIce sublimationPressureIce Return sublimation pressure of water as a function of temperature T between 190 and 273.16 K
Modelica.Media.Air.MoistAir.sublimationPressureIce_der sublimationPressureIce_der Derivative function for 'sublimationPressureIce'
Modelica.Media.Air.MoistAir.saturationPressure saturationPressure Return saturation pressure of water as a function of temperature T between 190 and 647.096 K
Modelica.Media.Air.MoistAir.saturationPressure_der saturationPressure_der Derivative function for 'saturationPressure'
Modelica.Media.Air.MoistAir.saturationTemperature saturationTemperature Return saturation temperature of water as a function of (partial) pressure p
Modelica.Media.Air.MoistAir.enthalpyOfVaporization enthalpyOfVaporization Return enthalpy of vaporization of water as a function of temperature T, 273.16 to 647.096 K
Modelica.Media.Air.MoistAir.HeatCapacityOfWater HeatCapacityOfWater Return specific heat capacity of water (liquid only) as a function of temperature T
Modelica.Media.Air.MoistAir.enthalpyOfLiquid enthalpyOfLiquid Return enthalpy of liquid water as a function of temperature T(use enthalpyOfWater instead)
Modelica.Media.Air.MoistAir.enthalpyOfGas enthalpyOfGas Return specific enthalpy of gas (air and steam) as a function of temperature T and composition X
Modelica.Media.Air.MoistAir.enthalpyOfCondensingGas enthalpyOfCondensingGas Return specific enthalpy of steam as a function of temperature T
Modelica.Media.Air.MoistAir.enthalpyOfNonCondensingGas enthalpyOfNonCondensingGas Return specific enthalpy of dry air as a function of temperature T
Modelica.Media.Air.MoistAir.enthalpyOfWater enthalpyOfWater Computes specific enthalpy of water (solid/liquid) near atmospheric pressure from temperature T
Modelica.Media.Air.MoistAir.enthalpyOfWater_der enthalpyOfWater_der Derivative function of enthalpyOfWater
Modelica.Media.Air.MoistAir.pressure pressure Returns pressure of ideal gas as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.temperature temperature Return temperature of ideal gas as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.T_phX T_phX Return temperature as a function of pressure p, specific enthalpy h and composition X
Modelica.Media.Air.MoistAir.density density Returns density of ideal gas as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.specificEnthalpy specificEnthalpy Return specific enthalpy of moist air as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.h_pTX h_pTX Return specific enthalpy of moist air as a function of pressure p, temperature T and composition X
Modelica.Media.Air.MoistAir.h_pTX_der h_pTX_der Derivative function of h_pTX
Modelica.Media.Air.MoistAir.isentropicExponent isentropicExponent Return isentropic exponent (only for gas fraction!)
Modelica.Media.Air.MoistAir.isentropicEnthalpyApproximation isentropicEnthalpyApproximation Approximate calculation of h_is from upstream properties, downstream pressure, gas part only
Modelica.Media.Air.MoistAir.specificInternalEnergy specificInternalEnergy Return specific internal energy of moist air as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.specificInternalEnergy_pTX specificInternalEnergy_pTX Return specific internal energy of moist air as a function of pressure p, temperature T and composition X
Modelica.Media.Air.MoistAir.specificInternalEnergy_pTX_der specificInternalEnergy_pTX_der Derivative function for specificInternalEnergy_pTX
Modelica.Media.Air.MoistAir.specificEntropy specificEntropy Return specific entropy from thermodynamic state record, only valid for phi<1
Modelica.Media.Air.MoistAir.specificGibbsEnergy specificGibbsEnergy Return specific Gibbs energy as a function of the thermodynamic state record, only valid for phi<1
Modelica.Media.Air.MoistAir.specificHelmholtzEnergy specificHelmholtzEnergy Return specific Helmholtz energy as a function of the thermodynamic state record, only valid for phi<1
Modelica.Media.Air.MoistAir.specificHeatCapacityCp specificHeatCapacityCp Return specific heat capacity at constant pressure as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.specificHeatCapacityCv specificHeatCapacityCv Return specific heat capacity at constant volume as a function of the thermodynamic state record
Modelica.Media.Air.MoistAir.dynamicViscosity dynamicViscosity Return dynamic viscosity as a function of the thermodynamic state record, valid from 123.15 K to 1273.15 K
Modelica.Media.Air.MoistAir.thermalConductivity thermalConductivity Return thermal conductivity as a function of the thermodynamic state record, valid from 123.15 K to 1273.15 K
Modelica.Media.Air.MoistAir.velocityOfSound velocityOfSound  
Modelica.Media.Air.MoistAir.isobaricExpansionCoefficient isobaricExpansionCoefficient  
Modelica.Media.Air.MoistAir.isothermalCompressibility isothermalCompressibility  
Modelica.Media.Air.MoistAir.density_derp_h density_derp_h  
Modelica.Media.Air.MoistAir.density_derh_p density_derh_p  
Modelica.Media.Air.MoistAir.density_derp_T density_derp_T  
Modelica.Media.Air.MoistAir.density_derT_p density_derT_p  
Modelica.Media.Air.MoistAir.density_derX density_derX  
Modelica.Media.Air.MoistAir.molarMass molarMass  
Modelica.Media.Air.MoistAir.T_psX T_psX Return temperature as a function of pressure p, specific entropy s and composition X
Modelica.Media.Air.MoistAir.setState_psX setState_psX  
Modelica.Media.Air.MoistAir.s_pTX s_pTX Return specific entropy of moist air as a function of pressure p, temperature T and composition X (only valid for phi<1)
Modelica.Media.Air.MoistAir.s_pTX_der s_pTX_der Return specific entropy of moist air as a function of pressure p, temperature T and composition X (only valid for phi<1)
Modelica.Media.Air.MoistAir.isentropicEnthalpy isentropicEnthalpy Isentropic enthalpy (only valid for phi<1)
Modelica.Media.Air.MoistAir.Utilities Utilities Utility functions
Inherited
fluidConstants Constant data for the fluid
Modelica.Media.Interfaces.PartialMixtureMedium.moleToMassFractions moleToMassFractions Return mass fractions X from mole fractions
Modelica.Media.Interfaces.PartialMixtureMedium.massToMoleFractions massToMoleFractions Return mole fractions from mass fractions X
ThermoStates Enumeration type for independent variables
mediumName="unusablePartialMedium" Name of the medium
substanceNames={mediumName} Names of the mixture substances. Set substanceNames={mediumName} if only one substance.
extraPropertiesNames=fill("", 0) Names of the additional (extra) transported properties. Set extraPropertiesNames=fill("",0) if unused
singleState = true, if u and d are not a function of pressure
reducedX=true = true if medium contains the equation sum(X) = 1.0; set reducedX=true if only one substance (see docu for details)
fixedX=false = true if medium contains the equation X = reference_X
reference_p=101325 Reference pressure of Medium: default 1 atmosphere
reference_T=298.15 Reference temperature of Medium: default 25 deg Celsius
reference_X=fill(1/nX, nX) Default mass fractions of medium
p_default=101325 Default value for pressure of medium (for initialization)
T_default=Modelica.SIunits.Conversions.from_degC(20) Default value for temperature of medium (for initialization)
h_default=specificEnthalpy_pTX(p_default, T_default, X_default) Default value for specific enthalpy of medium (for initialization)
X_default=reference_X Default value for mass fractions of medium (for initialization)
nS=size(substanceNames, 1) Number of substances
nX=nS Number of mass fractions
nXi=if fixedX then 0 else if reducedX then nS - 1 else nS Number of structurally independent mass fractions (see docu for details)
nC=size(extraPropertiesNames, 1) Number of extra (outside of standard mass-balance) transported properties
C_nominal=1.0e-6*ones(nC) Default for the nominal values for the extra properties
Modelica.Media.Interfaces.PartialMedium.FluidConstants FluidConstants Critical, triple, molecular and other standard data of fluid
Modelica.Media.Interfaces.PartialMedium.prandtlNumber prandtlNumber Return the Prandtl number
Modelica.Media.Interfaces.PartialMedium.heatCapacity_cp heatCapacity_cp Alias for deprecated name
Modelica.Media.Interfaces.PartialMedium.heatCapacity_cv heatCapacity_cv Alias for deprecated name
Modelica.Media.Interfaces.PartialMedium.beta beta Alias for isobaricExpansionCoefficient for user convenience
Modelica.Media.Interfaces.PartialMedium.kappa kappa Alias of isothermalCompressibility for user convenience
Modelica.Media.Interfaces.PartialMedium.specificEnthalpy_pTX specificEnthalpy_pTX Return specific enthalpy from p, T, and X or Xi
Modelica.Media.Interfaces.PartialMedium.specificEntropy_pTX specificEntropy_pTX Return specific enthalpy from p, T, and X or Xi
Modelica.Media.Interfaces.PartialMedium.density_pTX density_pTX Return density from p, T, and X or Xi
Modelica.Media.Interfaces.PartialMedium.temperature_phX temperature_phX Return temperature from p, h, and X or Xi
Modelica.Media.Interfaces.PartialMedium.density_phX density_phX Return density from p, h, and X or Xi
Modelica.Media.Interfaces.PartialMedium.temperature_psX temperature_psX Return temperature from p,s, and X or Xi
Modelica.Media.Interfaces.PartialMedium.density_psX density_psX Return density from p, s, and X or Xi
Modelica.Media.Interfaces.PartialMedium.specificEnthalpy_psX specificEnthalpy_psX Return specific enthalpy from p, s, and X or Xi
MassFlowRate Type for mass flow rate with medium specific attributes
AbsolutePressure Type for absolute pressure with medium specific attributes
Density Type for density with medium specific attributes
DynamicViscosity Type for dynamic viscosity with medium specific attributes
EnthalpyFlowRate Type for enthalpy flow rate with medium specific attributes
MassFraction Type for mass fraction with medium specific attributes
MoleFraction Type for mole fraction with medium specific attributes
MolarMass Type for molar mass with medium specific attributes
MolarVolume Type for molar volume with medium specific attributes
IsentropicExponent Type for isentropic exponent with medium specific attributes
SpecificEnergy Type for specific energy with medium specific attributes
SpecificInternalEnergy Type for specific internal energy with medium specific attributes
SpecificEnthalpy Type for specific enthalpy with medium specific attributes
SpecificEntropy Type for specific entropy with medium specific attributes
SpecificHeatCapacity Type for specific heat capacity with medium specific attributes
SurfaceTension Type for surface tension with medium specific attributes
Temperature Type for temperature with medium specific attributes
ThermalConductivity Type for thermal conductivity with medium specific attributes
PrandtlNumber Type for Prandtl number with medium specific attributes
VelocityOfSound Type for velocity of sound with medium specific attributes
ExtraProperty Type for unspecified, mass-specific property transported by flow
CumulativeExtraProperty Type for conserved integral of unspecified, mass specific property
ExtraPropertyFlowRate Type for flow rate of unspecified, mass-specific property
IsobaricExpansionCoefficient Type for isobaric expansion coefficient with medium specific attributes
DipoleMoment Type for dipole moment with medium specific attributes
DerDensityByPressure Type for partial derivative of density with respect to pressure with medium specific attributes
DerDensityByEnthalpy Type for partial derivative of density with respect to enthalpy with medium specific attributes
DerEnthalpyByPressure Type for partial derivative of enthalpy with respect to pressure with medium specific attributes
DerDensityByTemperature Type for partial derivative of density with respect to temperature with medium specific attributes
DerTemperatureByPressure Type for partial derivative of temperature with respect to pressure with medium specific attributes
Modelica.Media.Interfaces.Types.SaturationProperties SaturationProperties Saturation properties of two phase medium
Modelica.Media.Interfaces.Types.FluidLimits FluidLimits Validity limits for fluid model
FixedPhase Phase of the fluid: 1 for 1-phase, 2 for two-phase, 0 for not known, e.g., interactive use
Modelica.Media.Interfaces.Types.Basic Basic The most basic version of a record used in several degrees of detail
Modelica.Media.Interfaces.Types.IdealGas IdealGas The ideal gas version of a record used in several degrees of detail
Modelica.Media.Interfaces.Types.TwoPhase TwoPhase The two phase fluid version of a record used in several degrees of detail

Modelica.Media.Air.MoistAir.ThermodynamicState Modelica.Media.Air.MoistAir.ThermodynamicState

ThermodynamicState record for moist air

Information

Extends from (Thermodynamic state variables).

Modelica.Media.Air.MoistAir.BaseProperties Modelica.Media.Air.MoistAir.BaseProperties

Moist air base properties record

Information

This model computes thermodynamic properties of moist air from three independent (thermodynamic or/and numerical) state variables. Preferred numerical states are temperature T, pressure p and the reduced composition vector Xi, which contains the water mass fraction only. As an EOS the ideal gas law is used and associated restrictions apply. The model can also be used in the fog region, when moisture is present in its liquid state. However, it is assumed that the liquid water volume is negligible compared to that of the gas phase. Computation of thermal properties is based on property data of dry air and water (source: VDI-Wärmeatlas), respectively. Besides the standard thermodynamic variables absolute and relative humidity, x_water and phi, respectively, are given by the model. Upper case X denotes absolute humidity with respect to mass of moist air while absolute humidity with respect to mass of dry air only is denoted by a lower case x throughout the model. See package description for further information.

Extends from (Base properties (p, d, T, h, u, R, MM and, if applicable, X and Xi) of a medium).

Parameters

NameDescription
standardOrderComponentsIf true, and reducedX = true, the last element of X will be computed from the other ones
Advanced
preferredMediumStates= true if StateSelect.prefer shall be used for the independent property variables of the medium

Modelica.Media.Air.MoistAir.setState_pTX Modelica.Media.Air.MoistAir.setState_pTX

Return thermodynamic state as function of pressure p, temperature T and composition X

Information

The thermodynamic state record is computed from pressure p, temperature T and composition X.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]
X[:]Mass fractions [kg/kg]

Outputs

NameDescription
stateThermodynamic state

Modelica.Media.Air.MoistAir.setState_phX Modelica.Media.Air.MoistAir.setState_phX

Return thermodynamic state as function of pressure p, specific enthalpy h and composition X

Information

The thermodynamic state record is computed from pressure p, specific enthalpy h and composition X.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
hSpecific enthalpy [J/kg]
X[:]Mass fractions [kg/kg]

Outputs

NameDescription
stateThermodynamic state

Modelica.Media.Air.MoistAir.setState_dTX Modelica.Media.Air.MoistAir.setState_dTX

Return thermodynamic state as function of density d, temperature T and composition X

Information

The thermodynamic state record is computed from density d, temperature T and composition X.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
dDensity [kg/m3]
TTemperature [K]
X[:]Mass fractions [kg/kg]

Outputs

NameDescription
stateThermodynamic state

Modelica.Media.Air.MoistAir.setSmoothState Modelica.Media.Air.MoistAir.setSmoothState

Return thermodynamic state so that it smoothly approximates: if x > 0 then state_a else state_b

Information

Extends from (Return thermodynamic state so that it smoothly approximates: if x > 0 then state_a else state_b).

Inputs

NameDescription
xm_flow or dp
state_aThermodynamic state if x > 0
state_bThermodynamic state if x < 0
x_smallSmooth transition in the region -x_small < x < x_small

Outputs

NameDescription
stateSmooth thermodynamic state for all x (continuous and differentiable)

Modelica.Media.Air.MoistAir.Xsaturation Modelica.Media.Air.MoistAir.Xsaturation

Return absolute humidity per unit mass of moist air at saturation as a function of the thermodynamic state record

Information

Absolute humidity per unit mass of moist air at saturation is computed from pressure and temperature in the state record. Note, that unlike X_sat in the BaseProperties model this mass fraction refers to mass of moist air at saturation.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
X_satSteam mass fraction of sat. boundary [kg/kg]

Modelica.Media.Air.MoistAir.xsaturation Modelica.Media.Air.MoistAir.xsaturation

Return absolute humidity per unit mass of dry air at saturation as a function of the thermodynamic state record

Information

Absolute humidity per unit mass of dry air at saturation is computed from pressure and temperature in the thermodynamic state record.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
x_satAbsolute humidity per unit mass of dry air [kg/kg]

Modelica.Media.Air.MoistAir.xsaturation_pT Modelica.Media.Air.MoistAir.xsaturation_pT

Return absolute humidity per unit mass of dry air at saturation as a function of pressure p and temperature T

Information

Absolute humidity per unit mass of dry air at saturation is computed from pressure and temperature.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]

Outputs

NameDescription
x_satAbsolute humidity per unit mass of dry air [kg/kg]

Modelica.Media.Air.MoistAir.massFraction_pTphi Modelica.Media.Air.MoistAir.massFraction_pTphi

Return steam mass fraction as a function of relative humidity phi and temperature T

Information

Absolute humidity per unit mass of moist air is computed from temperature, pressure and relative humidity.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]
phiRelative humidity (0 ... 1.0)

Outputs

NameDescription
X_steamAbsolute humidity, steam mass fraction [kg/kg]

Modelica.Media.Air.MoistAir.relativeHumidity_pTX Modelica.Media.Air.MoistAir.relativeHumidity_pTX

Return relative humidity as a function of pressure p, temperature T and composition X

Information

Relative humidity is computed from pressure, temperature and composition with 1.0 as the upper limit at saturation. Water mass fraction is the first entry in the composition vector.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]
X[:]Composition [1]

Outputs

NameDescription
phiRelative humidity

Modelica.Media.Air.MoistAir.relativeHumidity Modelica.Media.Air.MoistAir.relativeHumidity

Return relative humidity as a function of the thermodynamic state record

Information

Relative humidity is computed from the thermodynamic state record with 1.0 as the upper limit at saturation.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
stateThermodynamic state

Outputs

NameDescription
phiRelative humidity

Modelica.Media.Air.MoistAir.gasConstant Modelica.Media.Air.MoistAir.gasConstant

Return ideal gas constant as a function from thermodynamic state, only valid for phi<1

Information

The ideal gas constant for moist air is computed from thermodynamic state assuming that all water is in the gas phase.

Extends from (Return the gas constant of the mixture (also for liquids)).

Inputs

NameDescription
stateThermodynamic state

Outputs

NameDescription
RMixture gas constant [J/(kg.K)]

Modelica.Media.Air.MoistAir.gasConstant_X Modelica.Media.Air.MoistAir.gasConstant_X

Return ideal gas constant as a function from composition X

Information

The ideal gas constant for moist air is computed from the gas phase composition. The first entry in composition vector X is the steam mass fraction of the gas phase.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
X[:]Gas phase composition [1]

Outputs

NameDescription
RIdeal gas constant [J/(kg.K)]

Modelica.Media.Air.MoistAir.saturationPressureLiquid Modelica.Media.Air.MoistAir.saturationPressureLiquid

Return saturation pressure of water as a function of temperature T in the range of 273.16 to 647.096 K

Information

Saturation pressure of water above the triple point temperature is computed from temperature.

Source: A Saul, W Wagner: "International equations for the saturation properties of ordinary water substance", equation 2.1

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
TsatSaturation temperature [K]

Outputs

NameDescription
psatSaturation pressure [Pa]

Modelica.Media.Air.MoistAir.saturationPressureLiquid_der Modelica.Media.Air.MoistAir.saturationPressureLiquid_der

Derivative function for 'saturationPressureLiquid'

Information

Saturation pressure of water above the triple point temperature is computed from temperature.

Source: A Saul, W Wagner: "International equations for the saturation properties of ordinary water substance", equation 2.1

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
TsatSaturation temperature [K]
dTsatSaturation temperature derivative [K/s]

Outputs

NameDescription
psat_derSaturation pressure derivative [Pa/s]

Modelica.Media.Air.MoistAir.sublimationPressureIce Modelica.Media.Air.MoistAir.sublimationPressureIce

Return sublimation pressure of water as a function of temperature T between 190 and 273.16 K

Information

Sublimation pressure of water below the triple point temperature is computed from temperature.

Source: W Wagner, A Saul, A Pruss: "International equations for the pressure along the melting and along the sublimation curve of ordinary water substance", equation 3.5

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
TsatSublimation temperature [K]

Outputs

NameDescription
psatSublimation pressure [Pa]

Modelica.Media.Air.MoistAir.sublimationPressureIce_der Modelica.Media.Air.MoistAir.sublimationPressureIce_der

Derivative function for 'sublimationPressureIce'

Information

Sublimation pressure of water below the triple point temperature is computed from temperature.

Source: W Wagner, A Saul, A Pruss: "International equations for the pressure along the melting and along the sublimation curve of ordinary water substance", equation 3.5

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
TsatSublimation temperature [K]
dTsatSublimation temperature derivative [K/s]

Outputs

NameDescription
psat_derSublimation pressure derivative [Pa/s]

Modelica.Media.Air.MoistAir.saturationPressure Modelica.Media.Air.MoistAir.saturationPressure

Return saturation pressure of water as a function of temperature T between 190 and 647.096 K

Information

Saturation pressure of water in the liquid and the solid region is computed using correlations. Functions for the solid and the liquid region, respectively, are combined using the first derivative continuous spliceFunction. This functions range of validity is from 190 to 647.096 K. For more information on the type of correlation used, see the documentation of the linked functions.

Extends from (Return saturation pressure of condensing fluid).

Inputs

NameDescription
TsatSaturation temperature [K]

Outputs

NameDescription
psatSaturation pressure [Pa]

Modelica.Media.Air.MoistAir.saturationPressure_der Modelica.Media.Air.MoistAir.saturationPressure_der

Derivative function for 'saturationPressure'

Information

Derivative function of saturationPressure

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
TsatSaturation temperature [K]
dTsatTime derivative of saturation temperature [K/s]

Outputs

NameDescription
psat_derSaturation pressure [Pa/s]

Modelica.Media.Air.MoistAir.saturationTemperature Modelica.Media.Air.MoistAir.saturationTemperature

Return saturation temperature of water as a function of (partial) pressure p

Information

Computes saturation temperature from (partial) pressure via numerical inversion of the function saturationPressure. Therefore additional inputs are required (or the defaults are used) for upper and lower temperature bounds.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
T_minLower boundary of solution [K]
T_maxUpper boundary of solution [K]

Outputs

NameDescription
TSaturation temperature [K]

Modelica.Media.Air.MoistAir.enthalpyOfVaporization Modelica.Media.Air.MoistAir.enthalpyOfVaporization

Return enthalpy of vaporization of water as a function of temperature T, 273.16 to 647.096 K

Information

Enthalpy of vaporization of water is computed from temperature in the region of 273.16 to 647.096 K.

Source: W Wagner, A Pruss: "International equations for the saturation properties of ordinary water substance. Revised according to the international temperature scale of 1990" (1993).

Extends from (Return vaporization enthalpy of condensing fluid).

Inputs

NameDescription
TTemperature [K]

Outputs

NameDescription
r0Vaporization enthalpy [J/kg]

Modelica.Media.Air.MoistAir.HeatCapacityOfWater Modelica.Media.Air.MoistAir.HeatCapacityOfWater

Return specific heat capacity of water (liquid only) as a function of temperature T

Information

The specific heat capacity of water (liquid and solid) is calculated using a polynomial approach and data from VDI-Waermeatlas 8. Edition (Db1)

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
TTemperature [K]

Outputs

NameDescription
cp_flSpecific heat capacity of liquid [J/(kg.K)]

Modelica.Media.Air.MoistAir.enthalpyOfLiquid Modelica.Media.Air.MoistAir.enthalpyOfLiquid

Return enthalpy of liquid water as a function of temperature T(use enthalpyOfWater instead)

Information

Specific enthalpy of liquid water is computed from temperature using a polynomial approach. Kept for compatibility reasons, better use enthalpyOfWater instead.

Extends from (Return liquid enthalpy of condensing fluid).

Inputs

NameDescription
TTemperature [K]

Outputs

NameDescription
hLiquid enthalpy [J/kg]

Modelica.Media.Air.MoistAir.enthalpyOfGas Modelica.Media.Air.MoistAir.enthalpyOfGas

Return specific enthalpy of gas (air and steam) as a function of temperature T and composition X

Information

Specific enthalpy of moist air is computed from temperature, provided all water is in the gaseous state. The first entry in the composition vector X must be the mass fraction of steam. For a function that also covers the fog region please refer to h_pTX.

Extends from (Return enthalpy of non-condensing gas mixture).

Inputs

NameDescription
TTemperature [K]
X[:]Vector of mass fractions [kg/kg]

Outputs

NameDescription
hSpecific enthalpy [J/kg]

Modelica.Media.Air.MoistAir.enthalpyOfCondensingGas Modelica.Media.Air.MoistAir.enthalpyOfCondensingGas

Return specific enthalpy of steam as a function of temperature T

Information

Specific enthalpy of steam is computed from temperature.

Extends from (Return enthalpy of condensing gas (most often steam)).

Inputs

NameDescription
TTemperature [K]

Outputs

NameDescription
hSpecific enthalpy [J/kg]

Modelica.Media.Air.MoistAir.enthalpyOfNonCondensingGas Modelica.Media.Air.MoistAir.enthalpyOfNonCondensingGas

Return specific enthalpy of dry air as a function of temperature T

Information

Specific enthalpy of dry air is computed from temperature.

Extends from (Return enthalpy of the non-condensing species).

Inputs

NameDescription
TTemperature [K]

Outputs

NameDescription
hSpecific enthalpy [J/kg]

Modelica.Media.Air.MoistAir.enthalpyOfWater Modelica.Media.Air.MoistAir.enthalpyOfWater

Computes specific enthalpy of water (solid/liquid) near atmospheric pressure from temperature T

Information

Specific enthalpy of water (liquid and solid) is computed from temperature using constant properties as follows:
Pressure is assumed to be around 1 bar. This function is usually used to determine the specific enthalpy of the liquid or solid fraction of moist air.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
TTemperature [K]

Outputs

NameDescription
hSpecific enthalpy of water [J/kg]

Modelica.Media.Air.MoistAir.enthalpyOfWater_der Modelica.Media.Air.MoistAir.enthalpyOfWater_der

Derivative function of enthalpyOfWater

Information

Derivative function for enthalpyOfWater.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
TTemperature [K]
dTTime derivative of temperature [K/s]

Outputs

NameDescription
dhTime derivative of specific enthalpy [J/(kg.s)]

Modelica.Media.Air.MoistAir.pressure Modelica.Media.Air.MoistAir.pressure

Returns pressure of ideal gas as a function of the thermodynamic state record

Information

Pressure is returned from the thermodynamic state record input as a simple assignment.

Extends from (Return pressure).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
pPressure [Pa]

Modelica.Media.Air.MoistAir.temperature Modelica.Media.Air.MoistAir.temperature

Return temperature of ideal gas as a function of the thermodynamic state record

Information

Temperature is returned from the thermodynamic state record input as a simple assignment.

Extends from (Return temperature).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
TTemperature [K]

Modelica.Media.Air.MoistAir.T_phX Modelica.Media.Air.MoistAir.T_phX

Return temperature as a function of pressure p, specific enthalpy h and composition X

Information

Temperature is computed from pressure, specific enthalpy and composition via numerical inversion of function h_pTX.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
hSpecific enthalpy [J/kg]
X[:]Mass fractions of composition [kg/kg]

Outputs

NameDescription
TTemperature [K]

Modelica.Media.Air.MoistAir.density Modelica.Media.Air.MoistAir.density

Returns density of ideal gas as a function of the thermodynamic state record

Information

Density is computed from pressure, temperature and composition in the thermodynamic state record applying the ideal gas law.

Extends from (Return density).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
dDensity [kg/m3]

Modelica.Media.Air.MoistAir.specificEnthalpy Modelica.Media.Air.MoistAir.specificEnthalpy

Return specific enthalpy of moist air as a function of the thermodynamic state record

Information

Specific enthalpy of moist air is computed from the thermodynamic state record. The fog region is included for both, ice and liquid fog.

Extends from (Return specific enthalpy).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
hSpecific enthalpy [J/kg]

Modelica.Media.Air.MoistAir.h_pTX Modelica.Media.Air.MoistAir.h_pTX

Return specific enthalpy of moist air as a function of pressure p, temperature T and composition X

Information

Specific enthalpy of moist air is computed from pressure, temperature and composition with X[1] as the total water mass fraction. The fog region is included for both, ice and liquid fog.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]
X[:]Mass fractions of moist air [1]

Outputs

NameDescription
hSpecific enthalpy at p, T, X [J/kg]

Modelica.Media.Air.MoistAir.h_pTX_der Modelica.Media.Air.MoistAir.h_pTX_der

Derivative function of h_pTX

Information

Derivative function for h_pTX.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]
X[:]Mass fractions of moist air [1]
dpPressure derivative [Pa/s]
dTTemperature derivative [K/s]
dX[:]Composition derivative [1/s]

Outputs

NameDescription
h_derTime derivative of specific enthalpy [J/(kg.s)]

Modelica.Media.Air.MoistAir.isentropicExponent Modelica.Media.Air.MoistAir.isentropicExponent

Return isentropic exponent (only for gas fraction!)

Information

Extends from (Return isentropic exponent).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
gammaIsentropic exponent [1]

Modelica.Media.Air.MoistAir.isentropicEnthalpyApproximation Modelica.Media.Air.MoistAir.isentropicEnthalpyApproximation

Approximate calculation of h_is from upstream properties, downstream pressure, gas part only

Information

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
p2Downstream pressure [Pa]
stateThermodynamic state at upstream location

Outputs

NameDescription
h_isIsentropic enthalpy [J/kg]

Modelica.Media.Air.MoistAir.specificInternalEnergy Modelica.Media.Air.MoistAir.specificInternalEnergy

Return specific internal energy of moist air as a function of the thermodynamic state record

Information

Specific internal energy is determined from the thermodynamic state record, assuming that the liquid or solid water volume is negligible.

Extends from Modelica.Icons.Function (Icon for functions), (Return specific internal energy).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
uSpecific internal energy [J/kg]

Modelica.Media.Air.MoistAir.specificInternalEnergy_pTX Modelica.Media.Air.MoistAir.specificInternalEnergy_pTX

Return specific internal energy of moist air as a function of pressure p, temperature T and composition X

Information

Specific internal energy is determined from pressure p, temperature T and composition X, assuming that the liquid or solid water volume is negligible.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]
X[:]Mass fractions of moist air [1]

Outputs

NameDescription
uSpecific internal energy [J/kg]

Modelica.Media.Air.MoistAir.specificInternalEnergy_pTX_der Modelica.Media.Air.MoistAir.specificInternalEnergy_pTX_der

Derivative function for specificInternalEnergy_pTX

Information

Derivative function for specificInternalEnergy_pTX.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]
X[:]Mass fractions of moist air [1]
dpPressure derivative [Pa/s]
dTTemperature derivative [K/s]
dX[:]Mass fraction derivatives [1/s]

Outputs

NameDescription
u_derSpecific internal energy derivative [J/(kg.s)]

Modelica.Media.Air.MoistAir.specificEntropy Modelica.Media.Air.MoistAir.specificEntropy

Return specific entropy from thermodynamic state record, only valid for phi<1

Information

Specific entropy is calculated from the thermodynamic state record, assuming ideal gas behavior and including entropy of mixing. Liquid or solid water is not taken into account, the entire water content X[1] is assumed to be in the vapor state (relative humidity below 1.0).

Extends from (Return specific entropy).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
sSpecific entropy [J/(kg.K)]

Modelica.Media.Air.MoistAir.specificGibbsEnergy Modelica.Media.Air.MoistAir.specificGibbsEnergy

Return specific Gibbs energy as a function of the thermodynamic state record, only valid for phi<1

Information

The Gibbs Energy is computed from the thermodynamic state record for moist air with a water content below saturation.

Extends from Modelica.Icons.Function (Icon for functions), (Return specific Gibbs energy).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
gSpecific Gibbs energy [J/kg]

Modelica.Media.Air.MoistAir.specificHelmholtzEnergy Modelica.Media.Air.MoistAir.specificHelmholtzEnergy

Return specific Helmholtz energy as a function of the thermodynamic state record, only valid for phi<1

Information

The Specific Helmholtz Energy is computed from the thermodynamic state record for moist air with a water content below saturation.

Extends from Modelica.Icons.Function (Icon for functions), (Return specific Helmholtz energy).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
fSpecific Helmholtz energy [J/kg]

Modelica.Media.Air.MoistAir.specificHeatCapacityCp Modelica.Media.Air.MoistAir.specificHeatCapacityCp

Return specific heat capacity at constant pressure as a function of the thermodynamic state record

Information

The specific heat capacity at constant pressure cp is computed from temperature and composition for a mixture of steam (X[1]) and dry air. All water is assumed to be in the vapor state.

Extends from (Return specific heat capacity at constant pressure).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
cpSpecific heat capacity at constant pressure [J/(kg.K)]

Modelica.Media.Air.MoistAir.specificHeatCapacityCv Modelica.Media.Air.MoistAir.specificHeatCapacityCv

Return specific heat capacity at constant volume as a function of the thermodynamic state record

Information

The specific heat capacity at constant density cv is computed from temperature and composition for a mixture of steam (X[1]) and dry air. All water is assumed to be in the vapor state.

Extends from (Return specific heat capacity at constant volume).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
cvSpecific heat capacity at constant volume [J/(kg.K)]

Modelica.Media.Air.MoistAir.dynamicViscosity Modelica.Media.Air.MoistAir.dynamicViscosity

Return dynamic viscosity as a function of the thermodynamic state record, valid from 123.15 K to 1273.15 K

Information

Dynamic viscosity is computed from temperature using a simple polynomial for dry air. Range of validity is from 123.15 K to 1273.15 K. The influence of pressure and moisture is neglected.

Source: VDI Waermeatlas, 8th edition.

Extends from (Return dynamic viscosity).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
etaDynamic viscosity [Pa.s]

Modelica.Media.Air.MoistAir.thermalConductivity Modelica.Media.Air.MoistAir.thermalConductivity

Return thermal conductivity as a function of the thermodynamic state record, valid from 123.15 K to 1273.15 K

Information

Thermal conductivity is computed from temperature using a simple polynomial for dry air. Range of validity is from 123.15 K to 1273.15 K. The influence of pressure and moisture is neglected.

Source: VDI Waermeatlas, 8th edition.

Extends from (Return thermal conductivity).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
lambdaThermal conductivity [W/(m.K)]

Modelica.Media.Air.MoistAir.velocityOfSound Modelica.Media.Air.MoistAir.velocityOfSound

Information

Extends from (Return velocity of sound).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
aVelocity of sound [m/s]

Modelica.Media.Air.MoistAir.isobaricExpansionCoefficient Modelica.Media.Air.MoistAir.isobaricExpansionCoefficient

Information

Extends from (Return overall the isobaric expansion coefficient beta).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
betaIsobaric expansion coefficient [1/K]

Modelica.Media.Air.MoistAir.isothermalCompressibility Modelica.Media.Air.MoistAir.isothermalCompressibility

Information

Extends from (Return overall the isothermal compressibility factor).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
kappaIsothermal compressibility [1/Pa]

Modelica.Media.Air.MoistAir.density_derp_h Modelica.Media.Air.MoistAir.density_derp_h

Information

Extends from (Return density derivative w.r.t. pressure at const specific enthalpy).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
ddphDensity derivative w.r.t. pressure [s2/m2]

Modelica.Media.Air.MoistAir.density_derh_p Modelica.Media.Air.MoistAir.density_derh_p

Information

Extends from (Return density derivative w.r.t. specific enthalpy at constant pressure).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
ddhpDensity derivative w.r.t. specific enthalpy [kg.s2/m5]

Modelica.Media.Air.MoistAir.density_derp_T Modelica.Media.Air.MoistAir.density_derp_T

Information

Extends from (Return density derivative w.r.t. pressure at const temperature).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
ddpTDensity derivative w.r.t. pressure [s2/m2]

Modelica.Media.Air.MoistAir.density_derT_p Modelica.Media.Air.MoistAir.density_derT_p

Information

Extends from (Return density derivative w.r.t. temperature at constant pressure).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
ddTpDensity derivative w.r.t. temperature [kg/(m3.K)]

Modelica.Media.Air.MoistAir.density_derX Modelica.Media.Air.MoistAir.density_derX

Information

Extends from (Return density derivative w.r.t. mass fraction).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
dddX[nX]Derivative of density w.r.t. mass fraction [kg/m3]

Modelica.Media.Air.MoistAir.molarMass Modelica.Media.Air.MoistAir.molarMass

Information

Extends from (Return the molar mass of the medium).

Inputs

NameDescription
stateThermodynamic state record

Outputs

NameDescription
MMMixture molar mass [kg/mol]

Modelica.Media.Air.MoistAir.T_psX Modelica.Media.Air.MoistAir.T_psX

Return temperature as a function of pressure p, specific entropy s and composition X

Information

Temperature is computed from pressure, specific entropy and composition via numerical inversion of function specificEntropy.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
sSpecific entropy [J/(kg.K)]
X[:]Mass fractions of composition [kg/kg]

Outputs

NameDescription
TTemperature [K]

Modelica.Media.Air.MoistAir.setState_psX Modelica.Media.Air.MoistAir.setState_psX

Information

The thermodynamic state record is computed from pressure p, specific enthalpy h and composition X.

Extends from (Return thermodynamic state as function of p, s and composition X or Xi).

Inputs

NameDescription
pPressure [Pa]
sSpecific entropy [J/(kg.K)]
X[:]Mass fractions [kg/kg]

Outputs

NameDescription
stateThermodynamic state record

Modelica.Media.Air.MoistAir.s_pTX Modelica.Media.Air.MoistAir.s_pTX

Return specific entropy of moist air as a function of pressure p, temperature T and composition X (only valid for phi<1)

Information

Specific entropy of moist air is computed from pressure, temperature and composition with X[1] as the total water mass fraction.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]
X[:]Mass fractions of moist air [1]

Outputs

NameDescription
sSpecific entropy at p, T, X [J/(kg.K)]

Modelica.Media.Air.MoistAir.s_pTX_der Modelica.Media.Air.MoistAir.s_pTX_der

Return specific entropy of moist air as a function of pressure p, temperature T and composition X (only valid for phi<1)

Information

Specific entropy of moist air is computed from pressure, temperature and composition with X[1] as the total water mass fraction.

Extends from Modelica.Icons.Function (Icon for functions).

Inputs

NameDescription
pPressure [Pa]
TTemperature [K]
X[:]Mass fractions of moist air [1]
dpDerivative of pressure [Pa/s]
dTDerivative of temperature [K/s]
dX[nX]Derivative of mass fractions [1/s]

Outputs

NameDescription
dsSpecific entropy at p, T, X [J/(kg.K.s)]

Modelica.Media.Air.MoistAir.isentropicEnthalpy Modelica.Media.Air.MoistAir.isentropicEnthalpy

Isentropic enthalpy (only valid for phi<1)

Information

Extends from Modelica.Icons.Function (Icon for functions), (Return isentropic enthalpy).

Inputs

NameDescription
p_downstreamDownstream pressure [Pa]
refStateReference state for entropy

Outputs

NameDescription
h_isIsentropic enthalpy [J/kg]
Automatically generated Tue Apr 05 09:36:57 2016.