25 "The variable must be a scalar linear finite-volume variable.");
28 ? linear_variable->requestCellGradients(
29 aux.
getParam<GradientMethodName>(
"gradient_method"))
30 : linear_variable->requestCellGradients();
39 "variable, computed with a selected gradient method, into a vector "
40 "auxiliary variable.");
42 "Linear finite-volume variable whose gradient is copied.");
45 "Gradient method whose result is copied. Defaults to the gradient method of the variable.");
51 _gradient(requestGradient(*this, getFieldVar(
"linear_fv_variable", 0)))
54 paramError(
"variable",
"This AuxKernel only supports elemental fields.");
60 mooseAssert(
_qp == 0,
"Only one quadrature point per element is expected.");
registerMooseObject("MooseApp", LinearFVGradientAux)
MooseMesh & _mesh
Mesh this kernel is active on.
bool isNodal() const
Nodal or elemental kernel?
const Elem *const & _current_elem
Current element (valid only for elemental kernels)
unsigned int _qp
Quadrature point index.
static InputParameters validParams()
Copies the cell-centered gradient of a linear finite-volume variable, computed with a selected gradie...
static InputParameters validParams()
const LinearFVGradientReader & _gradient
Reader for the gradient of the selected variable and gradient method.
LinearFVGradientAux(const InputParameters ¶meters)
virtual RealVectorValue computeValue() override
Compute and return the value of the aux variable.
Read-only view of one variable's cell-centered linear finite-volume gradient values.
RealVectorValue gradient(const ElemInfo &elem_info) const
Read the full gradient at an element.
void paramError(const std::string ¶m, Args... args) const
Emits an error prefixed with the file and line number of the given param (from the input file) along ...
const T & getParam(const std::string &name) const
Retrieve a parameter for the object.
bool isParamValid(const std::string &name) const
Test if the supplied parameter is valid.
const ElemInfo & elemInfo(const dof_id_type id) const
Accessor for the elemInfo object for a given element ID.
This class provides an interface for common operations on field variables of both FE and FV types wit...