21 "The index corresponding to the fluid component that this Postprocessor acts on");
23 "PorousFlowDictator",
"The UserObject that holds the list of PorousFlow variable names.");
24 params.
addParam<std::vector<unsigned int>>(
"phase",
26 "The index of the fluid phase that this " 27 "Postprocessor is restricted to. Multiple " 28 "indices can be entered");
31 "saturation_threshold >= 0 & saturation_threshold <= 1",
32 "The saturation threshold below which the mass is calculated " 33 "for a specific phase. Default is 1.0. Note: only one " 34 "phase_index can be entered");
37 "For non-mechanically-coupled systems with no TensorMechanics strain calculators, base_name " 38 "need not be set. For mechanically-coupled systems, base_name should be the same base_name " 39 "as given to the TensorMechanics object that computes strain, so that this Postprocessor can " 40 "correctly account for changes in mesh volume. For non-mechanically-coupled systems, " 41 "base_name should not be the base_name of any TensorMechanics strain calculators.");
42 params.
set<
bool>(
"use_displaced_mesh") =
false;
51 _fluid_component(getParam<unsigned
int>(
"fluid_component")),
52 _phase_index(getParam<
std::vector<unsigned
int>>(
"phase")),
53 _base_name(isParamValid(
"base_name") ? getParam<
std::string>(
"base_name") +
"_" :
""),
54 _has_total_strain(hasMaterialProperty<
RankTwoTensor>(_base_name +
"total_strain")),
55 _total_strain(_has_total_strain
56 ? &getMaterialProperty<
RankTwoTensor>(_base_name +
"total_strain")
58 _porosity(getADMaterialProperty<
Real>(
"PorousFlow_porosity_qp")),
59 _fluid_density(getADMaterialProperty<
std::vector<
Real>>(
"PorousFlow_fluid_phase_density_qp")),
60 _fluid_saturation(getADMaterialProperty<
std::vector<
Real>>(
"PorousFlow_saturation_qp")),
62 getADMaterialProperty<
std::vector<
std::vector<
Real>>>(
"PorousFlow_mass_frac_qp")),
63 _saturation_threshold(getParam<
Real>(
"saturation_threshold"))
72 "The Dictator proclaims that the number of components in this simulation is ",
74 " whereas you have used a component index of ",
76 ". Remember that indexing starts at 0. The Dictator does not take such mistakes lightly.");
81 "The Dictator decrees that the number of phases in this simulation is ",
83 " but you have entered ",
93 if (max_phase_num > num_phases - 1)
95 "The Dictator proclaims that the phase index ",
97 " is greater than the largest phase index possible, which is ",
104 "A single phase_index must be entered when prescribing a saturation_threshold");
108 for (
unsigned int i = 0; i < num_phases; ++i)
const std::string _base_name
base name used in the Tensor Mechanics strain calculator
FVPorousFlowFluidMass(const InputParameters ¶meters)
unsigned int numComponents() const
The number of fluid components.
const ADMaterialProperty< std::vector< Real > > & _fluid_density
Phase density (kg/m^3)
std::vector< unsigned int > _phase_index
The phase indices that this Postprocessor is restricted to.
const ADMaterialProperty< std::vector< std::vector< Real > > > & _mass_fraction
Mass fraction of each fluid component in each phase.
Postprocessor that calculates the mass of a given fluid component in the given phase(s) in a given bl...
static InputParameters validParams()
const ADMaterialProperty< Real > & _porosity
Porosity.
const Real _saturation_threshold
Saturation threshold - only fluid mass at saturations below this are calculated.
const ADMaterialProperty< std::vector< Real > > & _fluid_saturation
Phase saturation (-)
void paramError(const std::string ¶m, Args... args) const
unsigned int numPhases() const
The number of fluid phases.
const unsigned int _fluid_component
The fluid component index that this Postprocessor applies to.
virtual Real computeQpIntegral() override
const bool _has_total_strain
Whether there is a Material called _base_name_total_strain.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
This holds maps between the nonlinear variables used in a PorousFlow simulation and the variable numb...
registerMooseObject("PorousFlowApp", FVPorousFlowFluidMass)
const InputParameters & parameters() const
const PorousFlowDictator & _dictator
PorousFlowDictator UserObject.
static InputParameters validParams()
void ErrorVector unsigned int