24 params.
addParam<FunctionName>(
"function",
"The boundary pressure as a regular function");
25 params.
addParam<MooseFunctorName>(
"functor",
"The boundary pressure as an AD functor");
26 params.
addParam<PostprocessorName>(
"postprocessor",
"The boundary pressure as a postprocessor");
35 _functor(isParamValid(
"functor") ? &this->template getFunctor<
ADReal>(
"functor") : nullptr),
36 _function(isParamValid(
"function") ? &getFunction(
"function") : nullptr),
37 _pp_value(isParamValid(
"postprocessor") ? &getPostprocessorValue(
"postprocessor") : nullptr)
39 if (!dynamic_cast<INSFVPressureVariable *>(&
_var))
42 "The variable argument to INSFVOutletPressureBC must be of type INSFVPressureVariable");
47 mooseError(
"One and only one of function/functor/postprocessor may be specified for the outlet " 57 return (*_functor)(singleSidedFaceArg(&fi), state);
62 mooseAssert(state.
state == 1,
"We cannot access values beyond the previous time step.");
A class for setting the value of the pressure at an outlet of the system.
const PostprocessorValue *const _pp_value
Postprocessor that gives the uniform value of pressure on the boundary.
const Point & faceCentroid() const
MooseVariableFV< Real > & _var
DualNumber< Real, DNDerivativeType, true > ADReal
static InputParameters validParams()
InputParameters validParams()
SolutionIterationType iteration_type
ADReal boundaryValue(const FaceInfo &, const Moose::StateArg &) const override
void paramError(const std::string ¶m, Args... args) const
registerMooseObject("NavierStokesApp", INSFVOutletPressureBC)
const Moose::Functor< ADReal > *const _functor
AD Functor that gives the distribution of pressure on the boundary.
INSFVOutletPressureBCTempl(const InputParameters ¶ms)
void mooseError(Args &&... args) const
const Function *const _function
Regular function that gives the distribution of pressure on the boundary.
static InputParameters validParams()