if97 | R Documentation |
Compute thermodynamic and transport properties of water and steam using the IAPWS industrial formulation 1997.
if97(what, p, t, h, state = NULL)
what |
a character vector listing the output properties. See Details for available properties. |
p |
a numeric vector giving the pressure values in MPa. |
t |
a numeric vector giving the temperature values in K. |
h |
a numeric vector giving the specific enthalpy values in kJ/kg. |
state |
|
The available properties for what
are:
"f"
: the specific free energy in kJ/kg.
"g"
: the specific Gibbs enthalpy in kJ/kg.
"u"
: the specific internal energy in kJ/kg.
"h"
: the specific enthalpy in kJ/kg.
"s"
: the specific entropy in kJ/K/kg.
"t"
: the temperature in K.
"p"
: the pressure in MPa.
"v"
: the specific volume in m^3/kg.
"rho"
: the mass density in kg/m^3.
"cv"
: the specific isochoric heat capacity in kJ/K/kg.
"cp"
: the specific isobaric heat capacity in kJ/K/kg.
"alpha"
: the expansion coefficient in 1/K
"beta"
: the pressure coefficient in MPa/K.
"kappat"
: the isothermal compressibility in 1/MPa.
"w"
: the speed of sound in m/s.
"eta"
: the dynamic viscosity in μPa.s.
"lambda"
: the thermal conductivity in mW/K/m.
A valid pair of p
, t
and h
is needed:
either (p, t)
or (p, h)
.
A numeric matrix of dimension c(n, length(what))
with n
the maximum length of either p
, t
, h
or state
.
Computing several properties in a single call may be more efficient than separately because most of the computation time is shared.
Jonathan Debove
International Association for the Properties of Water and Steam, IAPWS R7-97(2012), Revised Release on the IAPWS Industrial Formulation 1997 for the Thermodynamic Properties of Water and Steam.
International Association for the Properties of Water and Steam, IAPWS R12-08(2008), Release on the IAPWS Formulation 2008 for the Viscosity of Ordinary Water Substance.
International Association for the Properties of Water and Steam, IAPWS R15-11(2011), Release on the IAPWS Formulation 2011 for the Thermal Conductivity of Ordinary Water Substance.
what <- c("v", "h", "u", "s", "cp", "w") # Region 1 Tab. 5 tab5 <- if97(what, t = c(300, 300, 500), p = c(3, 80, 3)) format(tab5, scientific = TRUE, digits = 9) # Region 2 Tab. 15 tab15 <- if97(what, t = c(300, 700, 700), p = c(3.5e-3, 3.5e-3, 30)) format(tab15, scientific = TRUE, digits = 9) # Region 2 metastable Tab. 18 tab18 <- if97(what, t = c(450, 440, 450), p = c(1, 1, 1.5), state = "gas") format(tab18, scientific = TRUE, digits = 9) # Region 3 Tab. 33 tab33 <- if97(what, t = c(650, 650, 750), p = c(0.255837018e2, 0.222930643e2, 0.783095639e2)) format(tab33, scientific = TRUE, digits = 9) # Region 5 Tab. 42 tab42 <- if97(what, t = c(1500, 1500, 2000), p = c(0.5, 30, 30)) format(tab42, scientific = TRUE, digits = 9) # Viscosity and thermal conductivity what <- c("lambda", "eta") # Region 1 Tab. 7 tab7 <- if97(what, p = c(20, 50), t = c(620, 620)) format(tab7, scientific = TRUE, digits = 9) # Region 2 Tab. 8 tab8 <- if97(what, p = c(0.3, 50), t = c(650, 800)) format(tab8, scientific = TRUE, digits = 9) ## Region 3 Tab. 9 #tab9 <- if97_rhot(c("lambda", "rho", "cp", "cv", "eta"), # rho = c(0.3, 50), t = c(222, 322)), #format(tab9, scientific = TRUE, digits = 9)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.