19 params.
addClassDescription(
"Computes residual for diffusion operator for finite volume method.");
21 MooseEnum coeff_interp_method(
"average harmonic",
"harmonic");
23 "coeff_interp_method",
25 "Switch that can select face interpolation method for diffusion coefficients.");
28 params.
set<
unsigned short>(
"ghost_layers") = 2;
33 "ElementSideNeighborLayers",
45 _coeff(getFunctor<
ADReal>(
"coeff")),
47 Moose::FV::selectInterpolationMethod(getParam<
MooseEnum>(
"coeff_interp_method")))
67 if (!coeff_elem.value() && !coeff_neighbor.value())
77 coeff =
_coeff(face, state);
80 return -1 * coeff * dudn;
DualNumber< Real, DNDerivativeType, true > ADReal
registerMooseObject("MooseApp", FVDiffusion)
Interface function that holds the member variables and functions related to the interpolation schemes...
const bool _correct_skewness
Just a convenience member for using skewness correction.
static InputParameters validParams()
FVDiffusion implements a standard diffusion term:
static InputParameters validParams()
const Moose::FV::InterpMethod _coeff_interp_method
Decides if a geometric arithmetic or harmonic average is used for the face interpolation of the diffu...
virtual ADReal computeQpResidual() override
This is the primary function that must be implemented for flux kernel terms.
FVDiffusion(const InputParameters ¶ms)
const Moose::Functor< ADReal > & _coeff
FVFluxKernel is used for calculating residual contributions from numerical fluxes from surface integr...
Moose::ElemArg neighborArg(bool correct_skewness=false) const
Moose::ElemArg elemArg(bool correct_skewness=false) const
static InputParameters validParams()
MooseVariableFV< Real > & _var
Moose::FaceArg singleSidedFaceArg(const FaceInfo *fi=nullptr, Moose::FV::LimiterType limiter_type=Moose::FV::LimiterType::CentralDifference, bool correct_skewness=false, const Moose::StateArg *state_limiter=nullptr) const
Determine the single sided face argument when evaluating a functor on a face.
virtual ADReal gradUDotNormal(const Moose::StateArg &time, const bool correct_skewness) const
Calculates and returns "grad_u dot normal" on the face to be used for diffusive terms.
const FaceInfo * _face_info
This is holds meta-data for geometric information relevant to the current face including elem+neighbo...
static void setRMParamsDiffusion(const InputParameters &obj_params, InputParameters &rm_params, const unsigned short conditional_extended_layers)
Helper function to set the relationship manager parameters for diffusion-related kernels.
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
bool isInternalFace(const FaceInfo &) const
Returns true if the face is an internal face.
Moose::StateArg determineState() const
Create a functor state argument that corresponds to the implicit state of this object.
MOOSE now contains C++17 code, so give a reasonable error message stating what the user can do to add...