21 params.addClassDescription(
"Diffusion term in the porous media incompressible Navier-Stokes " 22 "fluid energy equations : $-div(eps * k * grad(T))$");
23 params.addRequiredParam<MooseFunctorName>(
NS::porosity,
"Porosity");
24 params.addRequiredParam<MooseFunctorName>(
NS::k,
"Thermal conductivity");
25 params.addParam<
bool>(
26 "effective_diffusivity",
28 "Whether the conductivity should be multiplied by porosity, or whether the provided " 29 "conductivity is an effective conductivity taking porosity effects into account");
30 params.renameParam(
"effective_diffusivity",
"effective_conductivity",
"");
31 MooseEnum coeff_interp_method(
"average harmonic",
"harmonic");
33 "kappa_interp_method",
35 "Switch that can select face interpolation method for the thermal conductivity.");
39 params.addRelationshipManager(
40 "ElementSideNeighborLayers",
46 params.set<
unsigned short>(
"ghost_layers") = 2;
56 _porosity_factored_in(getParam<bool>(
"effective_conductivity")),
60 if (!dynamic_cast<INSFVEnergyVariable *>(&
_var))
61 mooseError(
"PINSFVEnergyDiffusion may only be used with a fluid temperature variable, " 62 "of variable type INSFVEnergyVariable.");
79 const auto face_elem =
elemArg();
83 :
_k(face_elem, state) *
_eps(face_elem, state);
85 :
_k(face_neighbor, state) *
_eps(face_neighbor, state);
90 if (value1 <= 0 || value2 <= 0)
93 "Negative or null thermal conductivity value. If this is on purpose use arithmetic mean " 94 "interpolation instead of the default harmonic interpolation.");
109 return -k_eps_face * dTdn;
virtual ADReal gradUDotNormal(const Moose::StateArg &time, const bool correct_skewness) const
Moose::ElemArg elemArg(bool correct_skewness=false) const
const Moose::FV::InterpMethod _k_interp_method
which interpolation method for the diffusivity on faces
const FaceInfo * _face_info
Moose::StateArg determineState() const
const bool _porosity_factored_in
whether the diffusivity should be multiplied by porosity
DualNumber< Real, DNDerivativeType, true > ADReal
static InputParameters validParams()
static const std::string porosity
bool onBoundary(const FaceInfo &fi) const
static InputParameters validParams()
const bool _correct_skewness
static InputParameters validParams()
const Moose::Functor< ADReal > & _eps
the porosity
A flux kernel for diffusing energy in porous media across cell faces, using a scalar isotropic diffus...
Moose::ElemArg neighborArg(bool correct_skewness=false) const
void mooseError(Args &&... args) const
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
InterpMethod selectInterpolationMethod(const std::string &interp_method)
registerMooseObject("NavierStokesApp", PINSFVEnergyDiffusion)
MooseVariableFV< Real > & _var
ADReal computeQpResidual() override
static void setRMParamsDiffusion(const InputParameters &obj_params, InputParameters &rm_params, const unsigned short conditional_extended_layers)
const Moose::Functor< ADReal > & _k
the thermal conductivity
void interpolate(InterpMethod m, T &result, const T2 &value1, const T3 &value2, const FaceInfo &fi, const bool one_is_elem)
static const std::string k
PINSFVEnergyDiffusion(const InputParameters ¶ms)