30 if (!dynamic_cast<INSFVVelocityVariable *>(&
_var))
33 "The variable argument to WCNSFVMomentumFluxBC must be of type INSFVVelocityVariable");
37 mooseError(
"The inlet area should be provided along with the mass flow rate");
39 mooseError(
"Velocity should be provided if the mass flow rate is not");
54 const Point incoming_vector =
58 a = 1.0 / std::abs(incoming_vector *
_normal);
const PostprocessorValue *const _velocity_pp
Postprocessor with the inlet velocity.
const PostprocessorValue *const _mdot_pp
Postprocessor with the inlet mass flow rate.
const bool _direction_specified_by_user
Flag to store if the flow direction is specified by the user.
const FaceInfo * _face_info
const Moose::Functor< ADReal > & _rho
Fluid density functor.
ADRealVectorValue varVelocity(const Moose::StateArg &state) const
returns the velocity vector (vel_x, vel_y, vel_z)
WCNSFVMomentumFluxBC(const InputParameters ¶ms)
Moose::StateArg determineState() const
const Point _direction
The direction in which the flow is entering/leaving the domain.
const unsigned int _index
index x|y|z
ADReal inflowMassFlux(const Moose::StateArg &state) const
computes the inflow massflux
Base class for weakly compressible flux boundary conditions.
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
DualNumber< Real, DNDerivativeType, true > ADReal
registerMooseObject("NavierStokesApp", WCNSFVMomentumFluxBC)
ADReal inflowSpeed(const Moose::StateArg &state) const
computes the inflow speed
static InputParameters validParams()
static InputParameters validParams()
const PostprocessorValue *const _area_pp
Postprocessor with the inlet area.
ADRealVectorValue _normal
const Point & normal() const
void paramError(const std::string ¶m, Args... args) const
All objects that contribute to pressure-based (e.g.
Flux boundary conditions for the weakly compressible momentum equation.
virtual bool isInflow() const
true if a boundary is an inflow boundary, false if outflow
const Real _scaling_factor
Scaling factor.
void mooseError(Args &&... args) const
static InputParameters validParams()
ADReal computeQpResidual() override