packageR1234yf_ph

XRG_Media: medium model for R1234yf and p,h as states

Extends from myMedia.Interfaces.PartialTwoPhaseMedium (Base class for two phase medium of one substance).

Information

Calculation of fluid properties for Tetrafluoroprop-1-ene (R1234yf) in the fluid region of 0.315 bar (Triple pressure) to 300 bar and 220 Kelvin to 410 Kelvin.

Restriction

The functions provided by this package shall be used inside of the restricted limits according to the referenced literature.

  • 0.315 bar ≤ p ≤ 300 bar
  • 220 Kelvin ≤ T ≤ 410 Kelvin
  • explicit for pressure and specific enthalpy

References

Richter, M.; McLinden, M. and E. Lemmon:
Thermodynamic Properties 2,3,3,3-Tetrafluoroprop-1-ene (R1234yf): Vapor Pressure and p-rho-T Measurements and Equation of State. Journal of Chemical and Engineering Data 2011, 56, 3254-3264.
Akasaka, R.:
Viscosity Correlation for 2,3,3,3-Tetrafluoropropene (HFO-1234yf) based on the Extended Corresponding States Model. Journal of Thermal Science and Technology, Vol. 5, No. 2, 2010.
Perkins A., Huber M.:
Measurement and Correlation of Thermal Conductivity of 2,3,3,3-Tetrafluoroprop-1-ene (R1234yf) and trans-1,3,3,3-Tetrafluoropropene (R1234ze(E)). Journal of Chemical and Engineering Data 2011, 56, 4868-4874.

Parameters

TypeNameDefaultDescription
ThermofluidStream.Media.myMedia.Interfaces.Choices.IndependentVariablesThermoStates (from PartialMedium)Enumeration type for independent variables
StringmediumName (from PartialMedium)"unusablePartialMedium"Name of the medium
String[:]substanceNames (from PartialMedium){mediumName}Names of the mixture substances. Set substanceNames={mediumName} if only one substance.
String[:]extraPropertiesNames (from PartialMedium)fill("", 0)Names of the additional (extra) transported properties. Set extraPropertiesNames=fill("",0) if unused
BooleansingleState (from PartialMedium)= true, if u and d are not a function of pressure
BooleanreducedX (from PartialMedium)true= true, if medium contains the equation sum(X) = 1.0; set reducedX=true if only one substance (see docu for details)
BooleanfixedX (from PartialMedium)false= true, if medium contains the equation X = reference_X
AbsolutePressurereference_p (from PartialMedium)101325Reference pressure of Medium: default 1 atmosphere
Temperaturereference_T (from PartialMedium)298.15Reference temperature of Medium: default 25 deg Celsius
MassFraction[nX]reference_X (from PartialMedium)fill(1/nX, nX)Default mass fractions of medium
AbsolutePressurep_default (from PartialMedium)101325Default value for pressure of medium (for initialization)
TemperatureT_default (from PartialMedium)Modelica.Units.Conversions.from_degC(20)Default value for temperature of medium (for initialization)
SpecificEnthalpyh_default (from PartialMedium)specificEnthalpy_pTX(p_default, T_default, X_default)Default value for specific enthalpy of medium (for initialization)
MassFraction[nX]X_default (from PartialMedium)reference_XDefault value for mass fractions of medium (for initialization)
ExtraProperty[nC]C_default (from PartialMedium)fill(0, nC)Default value for trace substances of medium (for initialization)
IntegernS (from PartialMedium)size(substanceNames, 1)Number of substances
IntegernX (from PartialMedium)nSNumber of mass fractions
IntegernXi (from PartialMedium)if fixedX then 0 else if reducedX then nS - 1 else nSNumber of structurally independent mass fractions (see docu for details)
IntegernC (from PartialMedium)size(extraPropertiesNames, 1)Number of extra (outside of standard mass-balance) transported properties
Real[nC]C_nominal (from PartialMedium)1.0e-6*ones(nC)Default for the nominal values for the extra properties
BooleansmoothModel (from PartialTwoPhaseMedium)falseTrue if the (derived) model should not generate state events
BooleanonePhase (from PartialTwoPhaseMedium)falseTrue if the (derived) model should never be called with two-phase inputs
FluidConstantsfluidConstants (from PartialTwoPhaseMedium)Constant data for the fluid
Booleanph_explicittrue
BooleandT_explicitfalse
FluidLimitsr1234yfLimits
FluidConstantsr1234yfConstants

Contents

NameDescription
SaturationProperties
ThermodynamicStateThermodynamic state
BasePropertiesBase properties of R1234yf
setState_phXSet state for pressure and specific enthalpy (X not used since single substance)
setState_dTXSet state for density and temperature (X not used since single substance)
setState_psXSet state for pressure and specific entropy (X not used since single substance)
setState_pTXSet state for pressure and temperature (X not used since single substance)
setBubbleStateReturn the thermodynamic state on the bubble line
setDewStateReturn the thermodynamic state on the dew line
density_phDensity as function of pressure and specific enthalpy
densityDensity as function of pressure and specific enthalpy | use setState_phX function for input
temperature_phTemperature as function of pressure and specific enthalpy
temperatureTemperature as function of pressure and specific enthalpy | use setState_phX function for input
pressurePressure w.r.t. thermodynamic state
specificInternalEnergySpecific internal energy w.r.t. thermodynamic state
specificEnthalpySpecific enthalpy w.r.t. thermodynamic state | use setState_phX function for input
specificEntropySpecific entropy w.r.t. thermodynamic state | use setState_phX function for input if necessary
saturationTemperatureSaturation temperature in two-phase region
saturationTemperature_derpDerivative of saturation temperature in two-phase region
saturationTemperature_der_pTime derivative of saturation temperature in two-phase region
bubbleDensityDensity of liquid phase w.r.t saturation pressure | use setSat_p function for input
dBubbleDensity_dPressureDerivative of liquid density in two-phase region w.r.t pressure
dBubbleDensity_dPressure_der_satTime derivative of liquid density in two-phase region w.r.t pressure
dewDensityDensity of vapor phase w.r.t saturation pressure
dDewDensity_dPressureDerivative of vapor density in two-phase region w.r.t pressure
dDewDensity_dPressure_der_satTime derivative of vapor density in two-phase region w.r.t pressure
bubbleEnthalpySpecific enthalpy of liquid phase w.r.t saturation pressure
dBubbleEnthalpy_dPressureDerivative of liquid specific enthalpy in two-phase region w.r.t pressure
dBubbleEnthalpy_dPressure_der_satTime derivative of liquid specific enthalpy in two-phase region w.r.t pressure
dewEnthalpySpecific enthalpy of vapor phase w.r.t saturation pressure | use setSat_p function for input
dDewEnthalpy_dPressureDerivative of vapor specific enthalpy in two-phase region w.r.t pressure
dDewEnthalpy_dPressure_der_satTime derivative of vapor specific enthalpy in two-phase region w.r.t pressure
dewEntropySpecific entropy of vapor phase w.r.t saturation pressure | use setSat_p function for input
dDewEntropy_dPressureDerivative of vapor specific entropy in two-phase region w.r.t pressure | use setState_phX function for input
dDewEntropy_dPressure_der_satTime derivative of vapor specific entropy in two-phase region w.r.t pressure | use setState_phX function for input
bubbleEntropySpecific entropy of liquid phase w.r.t saturation pressure | use setSat_p function for input
dBubbleEntropy_dPressureTime derivative of liquid specific entropy in two-phase region w.r.t pressure | use setState_phX function for input
dBubbleEntropy_dPressure_der_satTime derivative of liquid specific entropy in two-phase region w.r.t pressure | use setState_phX function for input
saturationPressureSaturation pressure w.r.t. temperature
specificHeatCapacityCpSpecific heat capacity at constant pressure | turns inifity in two-phase region! | use setState_phX function for input
specificHeatCapacityCvSpecific heat capacity at constant volume | use setState_phX function for input
dynamicViscosityDynamic viscosity w.r.t. temperature and density | use setState_phX function for input
thermalConductivityThermal conductivity w.r.t. thermodynamic state | use setState_phX function for input
surfaceTensionSurface tension as a function of temperature (below critical point)
velocityOfSoundVelocity of sound w.r.t. thermodynamic state (only valid for one-phase)
isothermalCompressibilityIsothermal compressibility w.r.t. thermodynamic state (only valid for one-phase)
isobaricExpansionCoefficientIsobaric expansion coefficient w.r.t. thermodynamic state (only valid for one-phase)
isentropicExponentIsentropic exponent gamma w.r.t. thermodynamic state | not defined in two-phase region | use setState_phX function for input
specificGibbsEnergySpecific gibbs energy w.r.t. thermodynamic state
specificHelmholtzEnergyHelmholtz energy w.r.t. thermodynamic state
density_derh_pDensity derivative by specific enthalpy | use setState_phX function for input
density_derp_hDensity derivative by pressure | use setState_phX function for input
isentropicEnthalpyIsentropic enthalpy of downstream pressure and upstream thermodynamic state (specific entropy)
derivsOf_phDerivatives required for inversion of temperature and density functions
dt_phDensity and temperature w.r.t. pressure and specific enthalpy
dtofphOnePhaseDensity and temperature w.r.t. pressure and specific enthalpy in one-phase region
dtofpsOnePhaseInverse iteration in one phase region (d,T) = f(p,s)
f_R1234yfCalculation of helmholtz derivatives by density and temperature
fid_R1234yfHelmholtz coefficients of ideal part
fres_R1234yfCalculation of helmholtz derivatives
getPhase_phNumber of phases by pressure and specific enthalpy
getPhase_psNumber of phases by pressure and entropy
hofpsTwoPhaseIsentropic specific enthalpy in two phase region h(p,s)
R1234yf_liqofdTProperties on liquid boundary phase
R1234yf_vapofdTProperties on vapor boundary phase
rho_ph_derTime derivative function of rho_ph
rho_props_phDensity as function of pressure and specific enthalpy
T_ph_derTime derivative function of T_ph
T_props_phTemperature as function of pressure and specific enthalpy
setSmoothStateSmooth transition function between state_a and state_b
dofpTCompute d for given p and T
hofpTCompute h for given p and T
phaseBoundaryAssertAssert function for checking threshold to phase boundary

Revisions

Copyright (C) 2007-2021, XRG Simulation GmbH