17 #include "libmesh/utility.h" 26 "Maximum of the flux (measured in kg.m^-2.s^-1). Flux out " 27 "= max*exp((-0.5*(p - centre)/sd)^2) for p<centre, and Flux " 28 "out = max for p>centre. Note, to make this a source " 29 "rather than a sink, let max<0");
31 "Standard deviation of the Gaussian (measured in Pa). Flux " 32 "out = max*exp((-0.5*(p - centre)/sd)^2) for p<centre, and " 33 "Flux out = max for p>centre.");
35 "Centre of the Gaussian (measured in Pa). Flux out = " 36 "max*exp((-0.5*(p - centre)/sd)^2) for p<centre, and " 37 "Flux out = max for p>centre.");
38 params.
addParam<FunctionName>(
"multiplying_fcn",
40 "If this function is provided, the flux " 41 "will be multiplied by this function. " 42 "This is useful for spatially or " 43 "temporally varying sinks");
45 "richardsVarNames_UO",
"The UserObject that holds the list of Richards variable names.");
51 _maximum(getParam<
Real>(
"max")),
52 _sd(getParam<
Real>(
"sd")),
53 _centre(getParam<
Real>(
"centre")),
54 _m_func(getFunction(
"multiplying_fcn")),
56 _pvar(_richards_name_UO.richards_var_num(_var.number())),
57 _pp(getMaterialProperty<
std::vector<
Real>>(
"porepressure")),
58 _dpp_dv(getMaterialProperty<
std::vector<
std::vector<
Real>>>(
"dporepressure_dv"))
const VariableTestValue & _test
Real _maximum
maximum of the Gaussian sink
const MaterialProperty< std::vector< Real > > & _pp
porepressure (or porepressure vector for multiphase problems)
Real _sd
standard deviation of the Gaussian sink
const RichardsVarNames & _richards_name_UO
holds info regarding the names of the Richards variables and methods for extracting values of these v...
static InputParameters validParams()
static InputParameters validParams()
bool not_richards_var(unsigned int moose_var_num) const
returns true if moose_var_num is not a richards var
This holds maps between pressure_var or pressure_var, sat_var used in RichardsMaterial and kernels...
const VariablePhiValue & _phi
registerMooseObject("RichardsApp", RichardsHalfGaussianSink)
const MooseArray< Point > & _q_point
virtual Real computeQpOffDiagJacobian(unsigned int jvar)
const MaterialProperty< std::vector< std::vector< Real > > > & _dpp_dv
d(porepressure_i)/dvariable_j
virtual Real computeQpJacobian()
RichardsHalfGaussianSink(const InputParameters ¶meters)
const Function & _m_func
multiplying function: all fluxes will be multiplied by this
unsigned int _pvar
the index of this variable in the list of Richards variables held by _richards_name_UO.
Applies a fluid sink to the boundary.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
unsigned int richards_var_num(unsigned int moose_var_num) const
the richards variable number
virtual Real value(Real t, const Point &p) const
virtual Real computeQpResidual()
Real _centre
centre of the Gaussian sink