21 "PenaltyEqualValueConstraint enforces solution continuity between secondary and " 22 "primary sides of a mortar interface using a penalty approach (no Lagrange multipliers " 27 "Penalty value used to impose a generalized force capturing the mortar constraint equation");
35 _penalty_value(this->template getParam<
Real>(
"penalty_value"))
48 -(_u_primary[_qp] - _u_secondary[_qp]) * _penalty_value * _test_secondary[_i][_qp];
56 (_u_primary[_qp] - _u_secondary[_qp]) * _penalty_value * _test_primary[_i][_qp];
71 mooseError(
"ADPenaltyEqualValueConstraint does not implement manual Jacobian calculation.");
81 switch (jacobian_type)
84 if (jvar == _secondary_var.number())
85 return (*_phi)[_j][_qp] * _penalty_value * _test_secondary[_i][_qp];
89 if (jvar == _primary_var.number())
90 return -(*_phi)[_j][_qp] * _penalty_value * _test_secondary[_i][_qp];
94 if (jvar == _secondary_var.number())
95 return -(*_phi)[_j][_qp] * _penalty_value * _test_primary[_i][_qp];
99 if (jvar == _primary_var.number())
100 return (*_phi)[_j][_qp] * _penalty_value * _test_primary[_i][_qp];
Moose::GenericType< Real, is_ad > GenericReal
PenaltyEqualValueConstraintTempl(const InputParameters ¶meters)
GenericReal< is_ad > computeQpResidual(Moose::MortarType mortar_type) final
void mooseError(Args &&... args)
Emit an error message with the given stringified, concatenated args and terminate the application...
DualNumber< Real, DNDerivativeType, true > ADReal
InputParameters validParams()
registerMooseObject("MooseApp", PenaltyEqualValueConstraint)
Constrain the value of a variable to be the same on both sides of an interface using a generalized fo...
typename std::conditional< is_ad, ADMortarConstraint, MortarConstraint >::type MortarConstraintTempl
GenericReal< is_ad > computeQpJacobian(Moose::ConstraintJacobianType jacobian_type, unsigned int jvar)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static InputParameters validParams()