22 params.
addParam<
Real>(
"scaling_factor", 1,
"To scale the velocity");
26 params.
addParam<PostprocessorName>(
"velocity_pp",
"Postprocessor with the inlet velocity");
29 params.
addParam<PostprocessorName>(
"mdot_pp",
"Postprocessor with the inlet mass flow rate");
31 params.
addParam<PostprocessorName>(
"area_pp",
"Inlet area as a postprocessor");
39 _scaling_factor(getParam<
Real>(
"scaling_factor")),
40 _velocity_pp(isParamValid(
"velocity_pp") ? &getPostprocessorValue(
"velocity_pp") : nullptr),
41 _mdot_pp(isParamValid(
"mdot_pp") ? &getPostprocessorValue(
"mdot_pp") : nullptr),
42 _area_pp(isParamValid(
"area_pp") ? &getPostprocessorValue(
"area_pp") : nullptr),
45 if (!dynamic_cast<INSFVVelocityVariable *>(&
_var))
48 "The variable argument to WCNSFVInletVelocityBC must be of type INSFVVelocityVariable");
52 mooseWarning(
"If setting the velocity directly, no need for inlet mass flow rate or area");
56 mooseError(
"Mass flow rate, area and density should be provided if velocity is not");
bool absoluteFuzzyEqual(const T &var1, const T2 &var2, const T3 &tol=libMesh::TOLERANCE *libMesh::TOLERANCE)
const Moose::Functor< ADReal > *const _rho
Fluid density functor.
static const std::string density
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
MooseVariableFV< Real > & _var
Dirichlet boundary conditions for the velocity, set from either a velocity postprocessor or a mass fl...
DualNumber< Real, DNDerivativeType, true > ADReal
void mooseWarning(Args &&... args) const
ADReal boundaryValue(const FaceInfo &fi, const Moose::StateArg &state) const override
static InputParameters validParams()
const Real _scaling_factor
Scaling factor.
const PostprocessorValue *const _mdot_pp
Postprocessor with the inlet mass flow rate.
void paramError(const std::string ¶m, Args... args) const
const PostprocessorValue *const _area_pp
Postprocessor with the inlet area.
WCNSFVInletVelocityBC(const InputParameters ¶ms)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
registerMooseObject("NavierStokesApp", WCNSFVInletVelocityBC)
const PostprocessorValue *const _velocity_pp
Postprocessor with the inlet velocity.
void mooseError(Args &&... args) const
static InputParameters validParams()
A parent class for INSFV flow boundary conditions.
static InputParameters validParams()