https://mooseframework.inl.gov
ADPhaseFieldTwoPhaseSurfaceTension.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://mooseframework.inl.gov
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 
11 
13 
16 {
18  params.addClassDescription("Phase field surface tension force for the Navier-Stokes equations.");
19  params.addRequiredCoupledVar("auxpf", "Auxillary variable in phase field formulation");
20  params.addRequiredCoupledVar("pf", "phase field variable");
21  params.addRequiredParam<Real>("coeff", "prefactor relating chemical potential and psi");
22  return params;
23 }
24 
26  const InputParameters & parameters)
27  : ADVectorKernelValue(parameters),
28  _auxpf(adCoupledValue("auxpf")),
29  _grad_pf(adCoupledGradient("pf")),
30  _coeff(getParam<Real>("coeff"))
31 {
32 }
33 
36 {
37  return -_coeff * _auxpf[_qp] * _grad_pf[_qp];
38 }
static InputParameters validParams()
virtual ADRealVectorValue precomputeQpResidual() override
void addRequiredParam(const std::string &name, const std::string &doc_string)
registerMooseObject("PhaseFieldApp", ADPhaseFieldTwoPhaseSurfaceTension)
void addRequiredCoupledVar(const std::string &name, const std::string &doc_string)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
void addClassDescription(const std::string &doc_string)
ADPhaseFieldTwoPhaseSurfaceTension(const InputParameters &parameters)
unsigned int _qp