Exported Types

Exported Types

Index

Documentation

abstract type AbstractFluidConstants

Abstract type of all FluidConstants structures.

source
abstract type AbstractMedium

Abstract type of all media.

source
fluidConstants = BasicFluidConstants(;iupacName="", casRegistryNumber="", 
                     chemicalFormula="", structureFormula="", molarMass=NaN)

Generate a BasicFluidConstants <: AbstractFluidConstants object containing the minimal information about the standard data of the medium.

source
abstract type CondensingGases <: AbstractMedium

Abstract type of all media consisting of condensing media.

source
infos = FluidInfos(; <keyword arguments, see below>)

Generate a new FluidInfos object, containing generic properties of a medium.

Keyword arguments

Name and typeDescription
mediumName::AbstractStringName of the medium
substanceNames::Vector{AbstractString}Names of the mixture substances. Set substanceNames=[mediumName] if only one substance.
extraPropertiesNames::Vector{AbstractString}Names of the additional (extra) transported properties. Set extraPropertiesNames=fill("",0) if unused
ThermoStates::IndependentVariablesEnumeration type for independent variables
singleState::Bool= true, if u and d are not a function of pressure
reducedX::Bool= true if medium contains the equation sum(X) = 1.0; set reducedX=true if only one substance
fixedX::Bool= true if medium contains the equation X = reference_X
reference_pReference pressure of Medium: default 1 atmosphere
reference_TReference temperature of Medium: default 25 deg Celsius
reference_XReference mass fractions of medium
p_defaultDefault value for pressure of medium (for initialization)
T_defaultDefault value for temperature of medium (for initialization)
h_defaultDefault value for specific enthalpy of medium (for initialization)
X_defaultDefault value for specific enthalpy of medium (for initialization)
nSNumber of substances
nXNumber of mass fractions
nXiNumber of structurally independent mass fractions
nCNumber of extra (outside of standard mass-balance) transported properties
C_nominalDefault for the nominal values for the extra properties

Example

import ModiaMedia

infos = ModiaMedia.FluidInfos(mediumName           = "simpleMedium",
                              substanceNames       = [mediumName],
                              extraPropertiesNames = fill("",0),
                              ThermoStates         = IndependentVariables_T)
source
fluidLimits = FluidLimits(; TMIN=NaN, TMAX=NaN, DMIN=NaN, DMAX=NaN, PMIN=NaN, PMAX=NaN, 
                            HMIN=NaN, HMAX=NaN, SMIN=NaN, SMAX=NaN)

Generate a new FluidLimits object, containing the validity limits of the medium.

source
fluidConstants = IdealGasFluidConstants(; iupacName="", casRegistryNumber="", 
      chemicalFormula="", structureFormula="", molarMass=NaN,
      criticalTemperature=NaN, criticalPressure=NaN, criticalMolarVolume=NaN, 
      acentricFactor=NaN, meltingPoint=NaN, normalBoilingPoint=NaN, dipoleMoment=NaN,
      hasIdealGasHeatCapacity=false, hasCriticalData=false, hasDipoleMoment=false,
      hasFundamentalEquation=false, hasLiquidHeatCapacity=false, hasSolidHeatCapacity=false,
      hasAccurateViscosityData=false, hasAccurateConductivityData=false,
      hasVapourPressureCurve=false, hasAcentricFactor=false,
      HCRIT0=0.0, SCRIT0=0.0, deltah=0.0, deltas=0.0)

Generate a IdealGasFluidConstants <: AbstractFluidConstants object containing the minimal information about the standard data of ideal gas media (critical, triple, molecular and other standard data).

source
@enum IndependentVariables

Enumeration defining the independent variables of a medium. Possible values:

ValueIndependent variables
IndependentVariables_TTemperature
IndependentVariables_pTPressure, temperature
IndependentVariables_phPressure, specific enthalpy
IndependentVariables_phXPressure, specific enthalpy, mass fractions
IndependentVariables_pTXPressure, temperature, mass fractions
IndependentVariables_dTXDensity, temperature, mass fractions
source
abstract type MixtureMedium <: AbstractMedium

Abstract type of all media consisting of a mixture of media.

source
abstract type MixtureThermodynamicState <: ThermodynamicState

Abstract type of the states of all media consisting of a mixture of media.

source
state = MoistAirState(Medium, p, T, X)

Generate a MoistAirState <: MixtureThermodynamicState object containing pressure p [Pa], temperature T [K], and a vector of mass fractions as states, where X[1] is the mass fraction of Steam and X[2] is the mass fraction of dry air. If argument X has only one element, X[2] is computed from X[1] and stored in the state.

source
abstract type PureSubstance <: AbstractMedium

Abstract type of all media consisting of a pure substance.

source
@enum ReferenceEnthalpy

Enumeration defining the reference enthalpy of a medium. Possible values:

  • ReferenceEnthalpy_ZeroAt0K: The enthalpy is 0 at 0 K (default), if the enthalpy of formation is excluded
  • ReferenceEnthalpy_ZeroAt25C: The enthalpy is 0 at 25 degC, if the enthalpy of formation is excluded
  • ReferenceEnthalpy_UserDefined: The user-defined reference enthalpy is used at 293.15 K (25 degC)
source
@enum ReferenceEntropy

Enumeration defining the reference entropy of a medium. Possible values:

  • ReferenceEntropy_ZeroAt0K: The entropy is 0 at 0 K (default)
  • ReferenceEntropy_ZeroAt0C: The entropy is 0 at 0 degC
  • ReferenceEntropy_UserDefined: The user-defined reference entropy is used at 293.15 K (25 degC)
source
state = SimpleIdealGasMediumState(Medium, p, T)

Generate a SimpleIdealGasMediumState <: ThermodynamicState object containing pressure p [Pa] and temperature T [K] as thermodynamic states.

source
state = SimpleMediumState(Medium, p, T)

Generate a SimpleMediumState <: ThermodynamicState object containing pressure p [Pa] and temperature T [K] as thermodynamic states.

source
state = SingleGasNasaState(Medium, p, T)

Generate a SingleGasNasaState <: ThermodynamicState object containing pressure p [Pa] and temperature T [K] as thermodynamic states.

source

abstract type ThermodynamicState

Abstract type of all media states.

source