13 #include "libmesh/quadrature.h" 21 params.
addClassDescription(
"Compute an elemental field variable (single value per element) equal " 22 "to the Lp-norm of a coupled Variable.");
29 :
AuxKernel(parameters), _p(getParam<
Real>(
"p")), _coupled_var(coupledValue(
"coupled_variable"))
32 paramError(
"variable",
"Must be of type CONSTANT MONOMIAL");
42 Real summed_value = 0;
Compute an elemental field variable (single value per element) equal to the Lp-norm of a coupled Vari...
const MooseArray< Real > & _coord
const VariableValue & _coupled_var
A reference to the variable to compute the norm of.
static InputParameters validParams()
virtual void setDofValue(const OutputData &value, unsigned int index)=0
Degree of freedom value setters.
const MooseArray< Real > & _JxW
Transformed Jacobian weights.
ADRealEigenVector< T, D, asd > abs(const ADRealEigenVector< T, D, asd > &)
virtual void precalculateValue()
This callback is used for AuxKernelTempls that need to perform a per-element calculation.
virtual void compute() override
Override the base class functionality to compute the element integral withou scaling by element volum...
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 ...
MooseVariableField< Real > & _var
This is a regular kernel so we cast to a regular MooseVariable.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
registerMooseObject("MooseApp", ElementLpNormAux)
const QBase *const & _qrule
Quadrature rule being used.
MooseVariableBase * mooseVariableBase() const
Get the variable that this object is using.
unsigned int _qp
Quadrature point index.
static InputParameters validParams()
Base class for creating new auxiliary kernels and auxiliary boundary conditions.
MooseUnits pow(const MooseUnits &, int)
ElementLpNormAux(const InputParameters ¶meters)
Class constructor.
virtual Real computeValue() override
Called by compute() to get the value of the integrand at the current qp.