13 #include "MooseVariable.h"
24 InputParameters params = validParams<TimeKernel>();
25 params.addRequiredParam<UserObjectName>(
26 "richardsVarNames_UO",
"The UserObject that holds the list of Richards variables.");
27 params.addRequiredParam<std::vector<UserObjectName>>(
29 "List of names of user objects that define the fluid density (or densities for "
30 "multiphase). In the multiphase case, for ease of use, the density, Seff and "
31 "Sat UserObjects are the same format as for RichardsMaterial, but only the one "
32 "relevant for the specific phase is actually used.");
33 params.addRequiredParam<std::vector<UserObjectName>>(
35 "List of name of user objects that define effective saturation as a function of "
37 params.addRequiredParam<std::vector<UserObjectName>>(
39 "List of names of user objects that define saturation as a function of effective saturation");
44 : TimeKernel(parameters),
46 _num_p(_richards_name_UO.num_v()),
47 _pvar(_richards_name_UO.richards_var_num(_var.number())),
49 _porosity(getMaterialProperty<Real>(
"porosity")),
50 _porosity_old(getMaterialProperty<Real>(
"porosity_old")),
56 getParam<std::vector<UserObjectName>>(
"seff_UO")[_pvar])),
58 &getUserObjectByName<
RichardsSat>(getParam<std::vector<UserObjectName>>(
"sat_UO")[_pvar])),
60 getParam<std::vector<UserObjectName>>(
"density_UO")[_pvar]))
65 for (
unsigned int pnum = 0; pnum <
_num_p; ++pnum)
80 const Real sat = (*_sat_UO).sat(seff);
86 const Real sat_old = (*_sat_UO).sat(seff_old);
87 const Real mass_old =
_porosity_old[_qp] * density_old * sat_old;
89 return _test[_i][_qp] * (mass - mass_old) / _dt;
104 const Real sat = (*_sat_UO).sat(seff);
105 const Real dsat = (*_sat_UO).dsat(seff);
109 return _test[_i][_qp] * mass_prime / _dt;
126 const Real dsat = (*_sat_UO).dsat(seff);
130 return _test[_i][_qp] * mass_prime / _dt;