www.mooseframework.org
LevelSetAdvection.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://www.mooseframework.org
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 #include "LevelSetAdvection.h"
11 
13 
16 {
18  params.addClassDescription("Implements the level set advection equation: $\\vec{v}\\cdot\\nabla "
19  "u = 0$, where the weak form is $(\\psi_i, \\vec{v}\\cdot\\nabla u) = "
20  "0$.");
21  params.addRequiredCoupledVar("velocity", "Velocity vector variable.");
22  return params;
23 }
24 
26  : ADKernelValue(parameters), _velocity(adCoupledVectorValue("velocity"))
27 {
28 }
29 
30 ADReal
32 {
33  return _velocity[_qp] * _grad_u[_qp];
34 }
registerMooseObject("LevelSetApp", LevelSetAdvection)
virtual ADReal precomputeQpResidual() override
static InputParameters validParams()
LevelSetAdvection(const InputParameters &parameters)
const ADVectorVariableValue & _velocity
Velocity vector variable.
DualReal ADReal
void addRequiredCoupledVar(const std::string &name, const std::string &doc_string)
const ADTemplateVariableGradient< T > & _grad_u
void addClassDescription(const std::string &doc_string)
static InputParameters validParams()
Advection Kernel for the levelset equation.
unsigned int _qp