22 params.
addParam<
Real>(
"scaling_factor", 1,
"To scale the velocity");
26 params.
addParam<PostprocessorName>(
"temperature_pp",
"Postprocessor with the inlet temperature");
29 params.
addParam<PostprocessorName>(
"energy_pp",
"Postprocessor with the inlet energy flow rate");
30 params.
addParam<PostprocessorName>(
"velocity_pp",
"Postprocessor with the inlet velocity norm");
32 params.
addParam<MooseFunctorName>(
NS::cp,
"specific heat capacity functor");
35 params.
addParam<PostprocessorName>(
"mdot_pp",
"Postprocessor with the inlet mass flow rate");
43 _scaling_factor(getParam<
Real>(
"scaling_factor")),
44 _temperature_pp(isParamValid(
"temperature_pp") ? &getPostprocessorValue(
"temperature_pp")
46 _energy_pp(isParamValid(
"energy_pp") ? &getPostprocessorValue(
"energy_pp") : nullptr),
47 _velocity_pp(isParamValid(
"velocity_pp") ? &getPostprocessorValue(
"velocity_pp") : nullptr),
48 _mdot_pp(isParamValid(
"mdot_pp") ? &getPostprocessorValue(
"mdot_pp") : nullptr),
49 _area_pp(isParamValid(
"area_pp") ? &getPostprocessorValue(
"area_pp") : nullptr),
53 if (!dynamic_cast<INSFVEnergyVariable *>(&
_var))
56 "The variable argument to WCNSFVInletTemperatureBC must be of type INSFVEnergyVariable");
61 "If setting the temperature directly, no need for inlet velocity, mass flow or energy");
67 mooseError(
"If not providing the temperature, the energy flow rate should be provided");
69 mooseError(
"If not providing the inlet temperature, the inlet velocity or mass flow should " 72 mooseError(
"If providing the inlet velocity, the density, the area and the specific heat " 73 "capacity should be provided as well");
75 mooseError(
"If providing the inlet mass flow rate, the inlet specific heat capacity should " 76 "be provided as well");
80 "The scaling factor is meant to adjust for a different area or " 81 "mass flow rate, it should not be set if the temperature is set directly");
WCNSFVInletTemperatureBC(const InputParameters ¶ms)
bool absoluteFuzzyEqual(const T &var1, const T2 &var2, const T3 &tol=libMesh::TOLERANCE *libMesh::TOLERANCE)
const PostprocessorValue *const _velocity_pp
Postprocessor with the inlet velocity.
const PostprocessorValue *const _mdot_pp
Postprocessor with the inlet mass flow rate.
const PostprocessorValue *const _temperature_pp
Postprocessor with the inlet temperature.
const PostprocessorValue *const _energy_pp
Postprocessor with the inlet energy flow rate.
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 temperature, set from either a temperature postprocessor or an ...
DualNumber< Real, DNDerivativeType, true > ADReal
void mooseWarning(Args &&... args) const
const Moose::Functor< ADReal > *const _rho
Fluid density functor.
const Real _scaling_factor
Scaling factor.
static const std::string cp
static InputParameters validParams()
void paramError(const std::string ¶m, Args... args) const
const Moose::Functor< ADReal > *const _cp
Fluid specific heat capacity functor.
static InputParameters validParams()
registerMooseObject("NavierStokesApp", WCNSFVInletTemperatureBC)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
void mooseError(Args &&... args) const
A parent class for INSFV flow boundary conditions.
const PostprocessorValue *const _area_pp
Postprocessor with the inlet area.
static InputParameters validParams()
ADReal boundaryValue(const FaceInfo &fi, const Moose::StateArg &state) const override