18 params.
addClassDescription(
"Lagrange multiplier kernel to constrain the sum of all switching "
19 "functions in a multiphase system. This kernel acts on a "
20 "non-conserved order parameter eta_i.");
21 params.
addParam<MaterialPropertyName>(
"h_name",
22 "Switching Function Materials that provides h(eta_i)");
25 "Vector of further variable arguments to the switching function");
31 _eta_name(_var.
name()),
32 _dh(getMaterialPropertyDerivative<Real>(
"h_name", _eta_name)),
33 _d2h(getMaterialPropertyDerivative<Real>(
"h_name", _eta_name, _eta_name)),
34 _d2ha(coupledComponents(
"coupled_variables")),
35 _d2ha_map(getParameterJvarMap(
"coupled_variables")),
36 _lambda(coupledValue(
"lambda")),
37 _lambda_var(coupled(
"lambda"))
39 for (std::size_t i = 0; i <
_d2ha.size(); ++i)
40 _d2ha[i] = &getMaterialPropertyDerivative<Real>(
41 "h_name",
_eta_name, coupledName(
"coupled_variables", i));
47 return _lambda[_qp] *
_dh[_qp] * _test[_i][_qp];
53 return _lambda[_qp] *
_d2h[_qp] * _phi[_j][_qp] * _test[_i][_qp];
60 return _phi[_j][_qp] *
_dh[_qp] * _test[_i][_qp];
64 return _lambda[_qp] * (*
_d2ha[k])[_qp] * _phi[_j][_qp] * _test[_i][_qp];
registerMooseObject("PhaseFieldApp", SwitchingFunctionConstraintEta)
static InputParameters validParams()
SwitchingFunctionConstraintEta is a constraint kernel that acts on the lambda lagrange multiplier non...
std::vector< const MaterialProperty< Real > * > _d2ha
const MaterialProperty< Real > & _d2h
static InputParameters validParams()
virtual Real computeQpResidual()
VariableName _eta_name
Switching function name.
const VariableValue & _lambda
Lagrange multiplier.
virtual Real computeQpOffDiagJacobian(unsigned int)
const MaterialProperty< Real > & _dh
Switching function drivatives.
virtual Real computeQpJacobian()
SwitchingFunctionConstraintEta(const InputParameters ¶meters)
const JvarMap & _d2ha_map