Go to the documentation of this file.
18 InputParameters params = validParams<TimeKernel>();
19 params.addRequiredParam<std::vector<Real>>(
21 "Density (kg(precipitate)/m^3(precipitate)) of each secondary species in the "
22 "aqueous precipitation-dissolution reaction system");
23 params.addRequiredParam<UserObjectName>(
24 "PorousFlowDictator",
"The UserObject that holds the list of PorousFlow variable names.");
25 params.addRequiredParam<std::vector<Real>>(
"stoichiometry",
26 "A vector of stoichiometric coefficients for the "
27 "primary species that is the Variable of this Kernel: "
28 "one for each precipitation-dissolution reaction "
29 "(these are one columns of the 'reactions' matrix)");
30 params.addClassDescription(
"Precipitation-dissolution of chemical species");
35 : TimeKernel(parameters),
36 _mineral_density(getParam<std::vector<Real>>(
"mineral_density")),
38 _aq_ph(_dictator.aqueousPhaseNumber()),
39 _porosity_old(getMaterialPropertyOld<Real>(
"PorousFlow_porosity_nodal")),
40 _saturation(getMaterialProperty<std::vector<Real>>(
"PorousFlow_saturation_nodal")),
42 getMaterialProperty<std::vector<std::vector<Real>>>(
"dPorousFlow_saturation_nodal_dvar")),
44 getMaterialProperty<std::vector<Real>>(
"PorousFlow_mineral_reaction_rate_nodal")),
45 _dreaction_rate_dvar(getMaterialProperty<std::vector<std::vector<Real>>>(
46 "dPorousFlow_mineral_reaction_rate_nodal_dvar")),
47 _stoichiometry(getParam<std::vector<Real>>(
"stoichiometry"))
55 paramError(
"mineral_density",
56 "The Dictator proclaims that the number of precipitation-dissolution secondary "
57 "species in this simulation is ",
59 " whereas you have provided ",
61 ". The Dictator does not take such mistakes lightly");
64 paramError(
"stoichiometry",
65 "The Dictator proclaims that the number of precipitation-dissolution secondary "
66 "species in this simulation is ",
68 " whereas you have provided ",
70 ". The Dictator does not take such mistakes lightly");
125 return _test[_i][_qp] *
Kernel = sum (stoichiometry * density * porosity_old * saturation * reaction_rate) where the sum is o...
const MaterialProperty< std::vector< Real > > & _reaction_rate
Reaction rate of the yielding the secondary species.
unsigned int numAqueousKinetic() const
The number of aqueous kinetic secondary species.
const MaterialProperty< std::vector< std::vector< Real > > > & _dreaction_rate_dvar
d(reaction rate)/d(porflow variable)
registerMooseObject("PorousFlowApp", PorousFlowPreDis)
bool notPorousFlowVariable(unsigned int moose_var_num) const
Returns true if moose_var_num is not a porous flow variabe.
virtual Real computeQpResidual() override
unsigned int porousFlowVariableNum(unsigned int moose_var_num) const
The PorousFlow variable number.
const std::vector< Real > _stoichiometry
Stoichiometric coefficients.
InputParameters validParams< PorousFlowPreDis >()
This holds maps between the nonlinear variables used in a PorousFlow simulation and the variable numb...
virtual Real computeQpOffDiagJacobian(unsigned int jvar) override
const MaterialProperty< std::vector< Real > > & _saturation
Saturation.
const std::vector< Real > _mineral_density
Density of the mineral species.
PorousFlowPreDis(const InputParameters ¶meters)
const MaterialProperty< Real > & _porosity_old
Old value of porosity.
virtual Real computeQpJacobian() override
Real computeQpJac(unsigned int pvar)
Derivative of residual with respect to PorousFlow variable number pvar This is used by both computeQp...
const PorousFlowDictator & _dictator
PorousFlowDictator UserObject.
const unsigned int _aq_ph
Aqueous phase number.
const MaterialProperty< std::vector< std::vector< Real > > > & _dsaturation_dvar
d(saturation)/d(PorousFlow var)