www.mooseframework.org
LevelSetAdvectionSUPG.C
Go to the documentation of this file.
1 /****************************************************************/
2 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
3 /* */
4 /* All contents are licensed under LGPL V2.1 */
5 /* See LICENSE for full restrictions */
6 /****************************************************************/
7 
9 
10 template <>
11 InputParameters
13 {
14  InputParameters params = validParams<Kernel>();
15  params.addClassDescription(
16  "SUPG stablization term for the advection portion of the level set equation.");
17  params += validParams<LevelSetVelocityInterface<>>();
18  return params;
19 }
20 
21 LevelSetAdvectionSUPG::LevelSetAdvectionSUPG(const InputParameters & parameters)
22  : LevelSetVelocityInterface<Kernel>(parameters)
23 {
24 }
25 
26 Real
28 {
30  Real tau = _current_elem->hmin() / (2 * _velocity.norm());
31  return (tau * _velocity * _grad_test[_i][_qp]) * (_velocity * _grad_u[_qp]);
32 }
33 
34 Real
36 {
38  Real tau = _current_elem->hmin() / (2 * _velocity.norm());
39  return (tau * _velocity * _grad_test[_i][_qp]) * (_velocity * _grad_phi[_j][_qp]);
40 }
RealVectorValue _velocity
Storage for velocity vector.
InputParameters validParams< LevelSetAdvectionSUPG >()
Real computeQpJacobian() override
A helper class for defining the velocity as coupled variables for the levelset equation.
Real computeQpResidual() override
void computeQpVelocity()
This method should be called when the velocity vector needs to be updated, this is not done automatic...
LevelSetAdvectionSUPG(const InputParameters &parameters)