18#include "libmesh/quadrature.h"
27 "Lagrange multiplier approach.");
34 :
Kernel(parameters), _lambda_var(coupledScalar(
"lambda")), _lambda(coupledScalarValue(
"lambda"))
registerMooseObject("MooseApp", ScalarLagrangeMultiplier)
const MooseArray< Real > & _coord
The scaling factor to convert from cartesian to another coordinate system (e.g rz,...
unsigned int _qp
The current quadrature point index.
const MooseArray< Real > & _JxW
The current quadrature point weight value.
unsigned int _j
current index for the shape function
unsigned int _i
current index for the test function
const QBase *const & _qrule
active quadrature rule
MooseVariable & _var
This is a regular kernel so we cast to a regular MooseVariable.
const VariableTestValue & _test
the current test function
static InputParameters validParams()
libMesh::Order order() const
Get the order of this variable Note: Order enum can be implicitly converted to unsigned int.
unsigned int number() const
Get variable number coming from libMesh.
Class for scalar variables (they are different).
THREAD_ID _tid
The thread ID for this kernel.
Assembly & _assembly
Reference to this Kernel's assembly object.
SystemBase & _sys
Reference to the EquationSystem object.
This Kernel implements part of the equation that enforces the constraint of.
static InputParameters validParams()
unsigned int _lambda_var
Lagrange multiplier variable ID.
const VariableValue & _lambda
Lagrange multiplier variable value.
ScalarLagrangeMultiplier(const InputParameters ¶meters)
virtual void computeOffDiagJacobianScalar(unsigned int jvar) override
Computes jacobian block with respect to a scalar variable.
virtual Real computeQpResidual() override
Compute this Kernel's contribution to the residual at the current quadrature point.
virtual ~ScalarLagrangeMultiplier()
virtual Real computeQpOffDiagJacobianScalar(unsigned int jvar) override
For coupling scalar variables.
virtual MooseVariableScalar & getScalarVariable(THREAD_ID tid, const std::string &var_name) const
Gets a reference to a scalar variable with specified number.
DenseMatrix< Number > _local_ke
Holds local Jacobian entries as they are accumulated by this Kernel.
void accumulateTaggedLocalMatrix()
Local Jacobian blocks will be appended by adding the current local kernel Jacobian.
void prepareMatrixTag(Assembly &assembly, unsigned int ivar, unsigned int jvar)
Prepare data for computing element jacobian according to the active tags.