21 params.
addRequiredParam<UserObjectName>(
"water_fp",
"The name of the user object for water");
29 _Mh2o(_water_fp.molarMass()),
30 _p_triple(_water_fp.triplePointPressure()),
31 _p_critical(_water_fp.criticalPressure()),
32 _T_triple(_water_fp.triplePointTemperature()),
33 _T_critical(_water_fp.criticalTemperature())
37 paramError(
"water_fp",
"A valid water FluidProperties UserObject must be provided in water_fp");
47 "This value is larger than the possible number of phases ",
53 "This value is larger than the possible number of fluid components",
69 std::vector<FluidStateProperties> & fsp)
const 84 std::vector<FluidStateProperties> & fsp)
const 96 std::vector<FluidStateProperties> & fsp)
const 115 if (enthalpy.value() < hl.value())
118 else if (enthalpy.value() >= hl.value() && enthalpy.value() <= hv.value())
179 const ADReal hvl = hv - hl;
182 const ADReal X = (enthalpy - hl) / hvl;
194 const ADReal satv = X * rhol / (rhov + X * (rhol - rhov));
const unsigned int _pidx
Index of derivative wrt pressure.
const unsigned int _aqueous_phase_number
Phase number of the aqueous phase.
unsigned int _num_phases
Number of phases.
const unsigned int _hidx
Index of derivative wrt enthalpy.
static InputParameters validParams()
unsigned int _gas_phase_number
Phase number of the gas phase.
unsigned int _num_components
Number of components.
const Real _p_critical
Critical pressure of water (Pa)
const Real _T_critical
Critical temperature of water (K)
virtual Real vaporTemperature(Real p) const
Vapor temperature.
virtual Real capillaryPressure(Real saturation, unsigned qp=0) const
Capillary pressure is calculated as a function of true saturation.
AD data structure to pass calculated thermophysical properties.
Common class for single phase fluid properties.
FluidStatePhaseEnum
Phase state enum.
void paramError(const std::string ¶m, Args... args) const
static InputParameters validParams()
const Real _p_triple
Triple point pressure of water (Pa)
PorousFlowWaterVapor(const InputParameters ¶meters)
const SinglePhaseFluidProperties & _water_fp
Fluid properties UserObject for water.
const PorousFlowCapillaryPressure & _pc
Capillary pressure UserObject.
const Real _dT
Perturbation applied to saturation temperature to move to gas/liquid phase.
static const std::string pressure
virtual std::string fluidStateName() const override
Name of FluidState.
registerMooseObject("PorousFlowApp", PorousFlowWaterVapor)
e e e e s T T T T T rho v v T e p T T virtual T std::string fluidName() const
Fluid name.
void derivInsert(SemiDynamicSparseNumberArray< Real, libMesh::dof_id_type, NWrapper< N >> &derivs, libMesh::dof_id_type index, Real value)
FluidStateProperties _empty_fsp
Empty FluidStateProperties object.
void thermophysicalProperties(Real pressure, Real enthalpy, unsigned int qp, std::vector< FluidStateProperties > &fsp) const override
Determines the complete thermophysical state of the system for a given set of primary variables...
const unsigned int _fluid_component
Fluid component number (only one fluid component in all phases)
Specialized class for water and vapor mixture using pressure and enthalpy.
std::vector< ADReal > mass_fraction
Base class for miscible multiphase flow classes with a single fluid component using a pressure and en...