diff --git a/ModelicaTest/Media.mo b/ModelicaTest/Media.mo index efdff8cb92..cf6d20a209 100644 --- a/ModelicaTest/Media.mo +++ b/ModelicaTest/Media.mo @@ -919,7 +919,9 @@ is given to compare the approximation. extends Modelica.Icons.Example; package Medium = Modelica.Media.Air.MoistAir "Medium model"; SI.Temperature T = 273.15 + 100; - SI.AbsolutePressure p = 2e5 - 1.5e5*time; + parameter SI.AbsolutePressure p0 = 2e5 "p at time 0"; + parameter Real pRate(unit = "Pa/s") = -1.5e5 "p's rate of change"; + SI.AbsolutePressure p = p0 + pRate*time; Medium.MassFraction X[Medium.nX] = {0.05,0.95}; Medium.ThermodynamicState state = Medium.setState_pTX(p,T,X); SI.SpecificEntropy s = Medium.specificEntropy(state); @@ -932,7 +934,9 @@ is given to compare the approximation. extends Modelica.Icons.Example; replaceable package Medium = Modelica.Media.R134a.R134a_ph "Medium model"; SI.Temperature T = 273.15 + 25; - SI.AbsolutePressure p = 10e5 + 20e5*time; + parameter SI.AbsolutePressure p0 = 10e5 "p at time 0"; + parameter Real pRate(unit = "Pa/s") = 20e5 "p's rate of change"; + SI.AbsolutePressure p = p0 + pRate*time; Medium.ThermodynamicState state = Medium.setState_pTX(p, T); SI.SpecificEnthalpy h = Medium.specificEnthalpy(state); SI.Density rho = Medium.density(state); @@ -946,7 +950,9 @@ is given to compare the approximation. extends Modelica.Icons.Example; replaceable package Medium = Modelica.Media.Water.WaterIF97_fixedregion "Medium model"; SI.Temperature T = 273.15 + 25; - SI.AbsolutePressure p = 10e5 + 20e5*time; + parameter SI.AbsolutePressure p0 = 10e5 "p at time 0"; + parameter Real pRate(unit = "Pa/s") = 20e5 "p's rate of change"; + SI.AbsolutePressure p = p0 + pRate*time; Medium.ThermodynamicState state = Medium.setState_pTX(p, T); SI.SpecificEnthalpy h_dew = Medium.dewEnthalpy(Medium.SaturationProperties(Tsat=Medium.saturationTemperature(state.p), psat=Medium.pressure(state))); annotation (experiment(StopTime=1));