iapws._utils module
Miscelaneous internal utilities. This module include:
getphase()
: Get phase string of state
_fase
: Base class to define a phase state
deriv_H()
: Calculate generic partial derivative with a fundamental Helmholtz free energy equation of state
deriv_G()
: Calculate generic partial derivative with a fundamental Gibbs free energy equation of state
- class iapws._utils._fase[source]
Class to implement a null phase
- Attributes:
- Gruneisen
- IntP
- Ks
- Kt
- Prandt
- Z
- Z_rho
- a
- alfa
- alfap
- alfav
- betap
- betas
- cp
- cp_cv
- cv
- dhdP_T
- dhdP_rho
- dhdT_P
- dhdT_rho
- dhdrho_P
- dhdrho_T
- dpdT_rho
- dpdrho_T
- drhodP_T
- drhodT_P
- epsilon
- f
- fi
- g
- gamma
- h
- hInput
- joule
- k
- kappa
- ks
- kt
- mu
- n
- nu
- rho
- s
- u
- v
- w
- iapws._utils.deriv_H(state, z, x, y, fase)[source]
Calculate generic partial derivative \(\left.\frac{\partial z}{\partial x}\right|_{y}\) from a fundamental helmholtz free energy equation of state
- Parameters:
state (any python object) – Only need to define P and T properties, non phase specific properties
z (str) – Name of variables in numerator term of derivatives
x (str) – Name of variables in denominator term of derivatives
y (str) – Name of constant variable in partial derivaritive
fase (any python object) – Define phase specific properties (v, cv, alfap, s, betap)
Notes
x, y and z can be the following values:
P: Pressure
T: Temperature
v: Specific volume
rho: Density
u: Internal Energy
h: Enthalpy
s: Entropy
g: Gibbs free energy
a: Helmholtz free energy
- Returns:
deriv – ∂z/∂x|y
- Return type:
References
IAPWS, Revised Advisory Note No. 3: Thermodynamic Derivatives from IAPWS Formulations, http://www.iapws.org/relguide/Advise3.pdf
- iapws._utils.deriv_G(state, z, x, y, fase)[source]
Calculate generic partial derivative \(\left.\frac{\partial z}{\partial x}\right|_{y}\) from a fundamental Gibbs free energy equation of state
- Parameters:
state (any python object) – Only need to define P and T properties, non phase specific properties
z (str) – Name of variables in numerator term of derivatives
x (str) – Name of variables in denominator term of derivatives
y (str) – Name of constant variable in partial derivaritive
fase (any python object) – Define phase specific properties (v, cp, alfav, s, xkappa)
Notes
x, y and z can be the following values:
P: Pressure
T: Temperature
v: Specific volume
rho: Density
u: Internal Energy
h: Enthalpy
s: Entropy
g: Gibbs free energy
a: Helmholtz free energy
- Returns:
deriv – ∂z/∂x|y
- Return type:
References
IAPWS, Revised Advisory Note No. 3: Thermodynamic Derivatives from IAPWS Formulations, http://www.iapws.org/relguide/Advise3.pdf