Go to the documentation of this file.
19 params.addRequiredRangeCheckedParam<Real>(
20 "rho_s",
"rho_s >= 0",
"The density of the solid matrix");
21 params.addClassDescription(
22 "This Material calculates the porous medium density from the porosity, solid density "
23 "(assumed constant) and fluid density, for the fully-saturated single fluid phase case, "
24 "using a linear weighted average. "
25 "density = phi * rho_f + (1 - phi) * rho_s, where phi is porosity and rho_f, rho_s are "
26 "the densities of the fluid and solid phases.");
32 const InputParameters & parameters)
34 _rho_s(getParam<Real>(
"rho_s")),
35 _rho_f_qp(getMaterialProperty<std::vector<Real>>(
"PorousFlow_fluid_phase_density_qp")),
36 _porosity_qp(getMaterialProperty<Real>(
"PorousFlow_porosity_qp")),
37 _drho_f_qp_dvar(getMaterialProperty<std::vector<std::vector<Real>>>(
38 "dPorousFlow_fluid_phase_density_qp_dvar")),
39 _dporosity_qp_dvar(getMaterialProperty<std::vector<Real>>(
"dPorousFlow_porosity_qp_dvar"))
42 mooseError(
"The Dictator proclaims that the number of phases is ",
43 _dictator.numPhases(),
44 " whereas PorousFlowThermalConductivityFromPorosity can only be used for 1-phase "
45 "simulations. Be aware that the Dictator has noted your mistake.");
47 if (_nodal_material ==
true)
48 mooseError(
"PorousFlowTotalGravitationalDensityFullySaturatedFromPorosity is only defined for "
55 const unsigned ph = 0;
62 const unsigned ph = 0;
66 for (
unsigned int v = 0; v <
_num_var; ++v)
MaterialProperty< std::vector< Real > > & _dgravdensity_dvar
d(density)/d(PorousFlow variable)
PorousFlowTotalGravitationalDensityFullySaturatedFromPorosity(const InputParameters ¶meters)
const MaterialProperty< std::vector< Real > > & _dporosity_qp_dvar
d(porosity)/d(PorousFlow variable)
InputParameters validParams< PorousFlowTotalGravitationalDensityBase >()
InputParameters validParams< PorousFlowTotalGravitationalDensityFullySaturatedFromPorosity >()
const Real _rho_s
Solid density.
Material designed to provide the density of the porous medium for the fully-saturated case.
void initQpStatefulProperties() override
Base class Material designed to provide the density of the porous medium.
const MaterialProperty< std::vector< std::vector< Real > > > & _drho_f_qp_dvar
d(rho_f)/d(PorousFlow variable)
MaterialProperty< Real > & _gravdensity
Computed density at quadpoints.
const unsigned int _num_var
Number of PorousFlow variables.
const unsigned int _num_phases
Number of phases.
const MaterialProperty< std::vector< Real > > & _rho_f_qp
Fluid density at qps.
void computeQpProperties() override
registerMooseObject("PorousFlowApp", PorousFlowTotalGravitationalDensityFullySaturatedFromPorosity)
const MaterialProperty< Real > & _porosity_qp
Porosity at qps.