Common class for multiple component fluid properties using a pressure and temperature formulation. More...
#include <MultiComponentFluidProperties.h>
Public Member Functions | |
MultiComponentFluidProperties (const InputParameters ¶meters) | |
virtual | ~MultiComponentFluidProperties () |
X X virtual X std::string | fluidName () const |
Fluid name. More... | |
virtual void | rho_mu_from_p_T_X (Real pressure, Real temperature, Real xmass, Real &rho, Real &mu) const |
Density and viscosity. More... | |
virtual void | rho_mu_from_p_T_X (DualReal pressure, DualReal temperature, DualReal xmass, DualReal &rho, DualReal &mu) const |
virtual void | rho_mu_from_p_T_X (Real pressure, Real temperature, Real xmass, Real &rho, Real &drho_dp, Real &drho_dT, Real &drho_dx, Real &mu, Real &dmu_dp, Real &dmu_dT, Real &dmu_dx) const |
Density and viscosity and their derivatives wrt pressure, temperature and mass fraction. More... | |
virtual const SinglePhaseFluidProperties & | getComponent (unsigned int component) const |
Get UserObject for specified component. More... | |
virtual void | execute () final |
virtual void | initialize () final |
virtual void | finalize () final |
virtual void | threadJoin (const UserObject &) final |
virtual void | subdomainSetup () final |
Static Public Attributes | |
static const Real | _R = 8.3144598 |
Universal gas constant (J/mol/K) More... | |
Protected Attributes | |
const Real | _T_c2k |
Conversion of temperature from Celsius to Kelvin. More... | |
const bool | _allow_imperfect_jacobians |
Flag to set unimplemented Jacobian entries to zero. More... | |
p | |
T | |
X | p |
X | T |
X X | p |
X X | T |
propfunc (rho, p, T, X) propfunc(mu | |
Compute a fluid property given for the state defined by three given properties. More... | |
X | propfunc (h, p, T, X) propfunc(cp |
X X | propfunc (e, p, T, X) propfunc(k |
Common class for multiple component fluid properties using a pressure and temperature formulation.
Definition at line 69 of file MultiComponentFluidProperties.h.
MultiComponentFluidProperties::MultiComponentFluidProperties | ( | const InputParameters & | parameters | ) |
Definition at line 20 of file MultiComponentFluidProperties.C.
|
virtual |
Definition at line 25 of file MultiComponentFluidProperties.C.
|
inlinefinalvirtualinherited |
Definition at line 34 of file FluidProperties.h.
|
inlinefinalvirtualinherited |
Definition at line 36 of file FluidProperties.h.
|
virtual |
Fluid name.
Reimplemented in BrineFluidProperties.
Definition at line 28 of file MultiComponentFluidProperties.C.
|
virtual |
Get UserObject for specified component.
component | fluid component |
Reimplemented in BrineFluidProperties.
Definition at line 67 of file MultiComponentFluidProperties.C.
|
inlinefinalvirtualinherited |
Definition at line 35 of file FluidProperties.h.
Compute a fluid property given for the state defined by three given properties.
For all functions, the first three arguments are the given properties that define the fluid state. For the three-argument variants, the desired property is the return value. The seven-argument variants also provide partial derivatives x/da, dx/db and dx/dc where x is the desired property being computed, a is the first given property, b is the second given property etc. The desired property, dx/da, dx/db and dx/dc are stored into the 4rd, 5th, 6th and 7th arguments respectively.
Properties/parameters used in these function are listed below with their units:
@begincode p pressure [Pa] T temperature [K] X solute mass fraction [-] e specific internal energy [J/kg] rho density [kg/m^3] h specific enthalpy [J/kg] mu viscosity [Pa*s] k thermal conductivity [W/(m*K)] c speed of sound [m/s] cp constant-pressure specific heat [J/K] cv constant-volume specific heat [J/K]
As an example:
@begincode // calculate desnity given pressure, temperature and solute mass fraction: auto density = your_fluid_properties_object.rho_from_p_T_X(p, T, X);
// or use the derivative variant: Real rho = 0; // density will be stored into here Real drho_dp = 0; // derivative will be stored into here Real drho_dT = 0; // derivative will be stored into here Real drho_dX = 0; // derivative will be stored into here your_fluid_properties_object.rho_from_p_T_X(p, T, X, rho, drho_dp, drho_dT, drho_dX);
Automatic differentiation (AD) support is provided through prop_from_p_T_X(DualReal p, DualReal T, DualReal X) versions of the functions where p, T and X must be ADReal/DualNumber's calculated using all AD-supporting values.
|
virtual |
Definition at line 42 of file MultiComponentFluidProperties.C.
|
virtual |
Density and viscosity and their derivatives wrt pressure, temperature and mass fraction.
pressure | fluid pressure (Pa) | |
temperature | fluid temperature (K) | |
xmass | mass fraction (-) | |
[out] | rho | density (kg/m^3) |
[out] | drho_dp | derivative of density wrt pressure |
[out] | drho_dT | derivative of density wrt temperature |
[out] | drho_dx | derivative of density wrt mass fraction |
[out] | mu | viscosity (Pa.s) |
[out] | dmu_dp | derivative of viscosity wrt pressure |
[out] | dmu_dT | derivative of viscosity wrt temperature |
[out] | dmu_dx | derivative of viscosity wrt mass fraction |
Definition at line 50 of file MultiComponentFluidProperties.C.
|
virtual |
Density and viscosity.
pressure | fluid pressure (Pa) | |
temperature | fluid temperature (K) | |
xmass | mass fraction (-) | |
[out] | rho | density (kg/m^3) |
Definition at line 34 of file MultiComponentFluidProperties.C.
|
inlinefinalvirtualinherited |
Definition at line 39 of file FluidProperties.h.
|
inlinefinalvirtualinherited |
Definition at line 38 of file FluidProperties.h.
|
protectedinherited |
Flag to set unimplemented Jacobian entries to zero.
Definition at line 48 of file FluidProperties.h.
Referenced by SinglePhaseFluidProperties::fluidPropError().
|
staticinherited |
Universal gas constant (J/mol/K)
Definition at line 42 of file FluidProperties.h.
Referenced by HelmholtzFluidProperties::c_from_p_T(), IdealGasFluidProperties::c_from_p_T(), HelmholtzFluidProperties::cp_from_p_T(), HelmholtzFluidProperties::cv_from_p_T(), HelmholtzFluidProperties::e_from_p_T(), HelmholtzFluidProperties::h_from_p_T(), HelmholtzFluidProperties::p_from_rho_T(), HelmholtzFluidProperties::rho_from_p_T(), IdealGasFluidProperties::rho_from_p_T(), and HelmholtzFluidProperties::s_from_p_T().
|
protectedinherited |
Conversion of temperature from Celsius to Kelvin.
Definition at line 46 of file FluidProperties.h.
Referenced by NaClFluidProperties::cp_from_p_T(), BrineFluidProperties::cp_from_p_T_X(), NaClFluidProperties::h_from_p_T(), BrineFluidProperties::h_from_p_T_X(), BrineFluidProperties::haliteSolubility(), NaClFluidProperties::k_from_p_T(), BrineFluidProperties::k_from_p_T_X(), BrineFluidProperties::mu_from_p_T_X(), CO2FluidProperties::partialDensity(), NaClFluidProperties::rho_from_p_T(), and BrineFluidProperties::rho_from_p_T_X().
MultiComponentFluidProperties::p |
Definition at line 123 of file MultiComponentFluidProperties.h.
Referenced by BrineFluidProperties::e_from_p_T_X(), BrineFluidProperties::h_from_p_T_X(), and BrineFluidProperties::rho_from_p_T_X().
X MultiComponentFluidProperties::p |
Definition at line 125 of file MultiComponentFluidProperties.h.
X X MultiComponentFluidProperties::p |
Definition at line 127 of file MultiComponentFluidProperties.h.
MultiComponentFluidProperties::T |
Definition at line 123 of file MultiComponentFluidProperties.h.
Referenced by BrineFluidProperties::e_from_p_T_X(), BrineFluidProperties::h_from_p_T_X(), and BrineFluidProperties::rho_from_p_T_X().
X MultiComponentFluidProperties::T |
Definition at line 125 of file MultiComponentFluidProperties.h.
X X MultiComponentFluidProperties::T |
Definition at line 127 of file MultiComponentFluidProperties.h.