https://mooseframework.inl.gov
Loading...
Searching...
No Matches
CNSFVHLLCMomentumImplicitBC.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
12// Full specialization of the validParams function for this object
14
17{
19 MooseEnum momentum_component("x=0 y=1 z=2", "x");
20 params.addParam<MooseEnum>("momentum_component",
21 momentum_component,
22 "The component of the momentum equation that this kernel applies to.");
23 params.addClassDescription("Implements an implicit advective boundary flux for the momentum "
24 "equation for an HLLC discretization");
25 return params;
26}
27
29 : CNSFVHLLCImplicitBC(parameters), _index(getParam<MooseEnum>("momentum_component"))
30{
31}
32
39
42{
43 auto vel_nonnormal = _vel_elem[_qp] - _normal_speed_elem * _normal;
44 return _normal(_index) * _SM + vel_nonnormal(_index);
45
46 // For some reason, the below expression doesn't give as good results as the
47 // above one.
48 // return _normal(_index) * (_SM - _normal_speed_elem) + _vel_elem[_qp](_index);
49}
50
DualNumber< Real, DNDerivativeType, true > ADReal
registerADMooseObject("NavierStokesApp", CNSFVHLLCMomentumImplicitBC)
ADReal _normal_speed_elem
speeds normal to the interface on the element side
const ADMaterialProperty< RealVectorValue > & _vel_elem
const ADMaterialProperty< Real > & _pressure_elem
const ADMaterialProperty< Real > & _rho_elem
HLLC implicit boundary conditions.
static InputParameters validParams()
HLLC implicit boundary conditions for the momentum conservation equation.
virtual ADReal fluxElem() override
flux functions on elem & from boundary
virtual ADReal conservedVariableElem() override
conserved variable of this equation from elem and boundary
virtual ADReal hllcElem() override
HLLC modifications to flux for elem & boundary, see Toro.
CNSFVHLLCMomentumImplicitBC(const InputParameters &parameters)
ADRealVectorValue _normal
const unsigned int _qp
void addParam(const std::string &name, const std::initializer_list< typename T::value_type > &value, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)