21 params.addClassDescription(
"This class computes the mass equation residual and Jacobian "
22 "contributions for the incompressible Navier-Stokes momentum "
24 params.addParam<
bool>(
25 "pspg",
false,
"Whether to perform PSPG stabilization of the mass equation");
26 params.addParam<FunctionName>(
"x_vel_forcing_func", 0,
"The x-velocity mms forcing function.");
27 params.addParam<FunctionName>(
"y_vel_forcing_func", 0,
"The y-velocity mms forcing function.");
28 params.addParam<FunctionName>(
"z_vel_forcing_func", 0,
"The z-velocity mms forcing function.");
34 _pspg(getParam<bool>(
"pspg")),
35 _x_ffn(getFunction(
"x_vel_forcing_func")),
36 _y_ffn(getFunction(
"y_vel_forcing_func")),
37 _z_ffn(getFunction(
"z_vel_forcing_func"))
59 RealVectorValue viscous_term =
61 RealVectorValue transient_term =
64 Real r = -1. /
_rho[_qp] *
tau() * _grad_test[_i][_qp] *
66 RealVectorValue(
_x_ffn.value(_t, _q_point[_qp]),
67 _y_ffn.value(_t, _q_point[_qp]),
68 _z_ffn.value(_t, _q_point[_qp])));
97 Real jac = -_grad_phi[_j][_qp](0) * _test[_i][_qp];
105 Real jac = -_grad_phi[_j][_qp](1) * _test[_i][_qp];
113 Real jac = -_grad_phi[_j][_qp](2) * _test[_i][_qp];
127 RealVectorValue d_convective_term_d_u_comp =
129 RealVectorValue viscous_term =
131 RealVectorValue d_viscous_term_d_u_comp =
133 RealVectorValue transient_term =
135 RealVectorValue d_transient_term_d_u_comp =
138 return -1. /
_rho[_qp] *
tau() * _grad_test[_i][_qp] *
139 (d_convective_term_d_u_comp + d_viscous_term_d_u_comp + d_transient_term_d_u_comp) -
143 _y_ffn.value(_t, _q_point[_qp]),
144 _z_ffn.value(_t, _q_point[_qp])));