swirlFlowRateInletVelocityFvPatchVectorField Class Reference

Velocity inlet boundary condition creating a normal velocity field to match the specified mass or volumetric flow rate, and radial and tangential velocity fields specified by functions of time and radius or by a given angular speed. More...

Inheritance diagram for swirlFlowRateInletVelocityFvPatchVectorField:
Collaboration diagram for swirlFlowRateInletVelocityFvPatchVectorField:

Public Member Functions

 TypeName ("swirlFlowRateInletVelocity")
 Runtime type information. More...
 
 swirlFlowRateInletVelocityFvPatchVectorField (const fvPatch &, const DimensionedField< vector, volMesh > &, const dictionary &)
 Construct from patch, internal field and dictionary. More...
 
 swirlFlowRateInletVelocityFvPatchVectorField (const swirlFlowRateInletVelocityFvPatchVectorField &, const fvPatch &, const DimensionedField< vector, volMesh > &, const fieldMapper &)
 Construct by mapping given. More...
 
 swirlFlowRateInletVelocityFvPatchVectorField (const swirlFlowRateInletVelocityFvPatchVectorField &)=delete
 Disallow copy without setting internal field reference. More...
 
 swirlFlowRateInletVelocityFvPatchVectorField (const swirlFlowRateInletVelocityFvPatchVectorField &, const DimensionedField< vector, volMesh > &)
 Copy constructor setting internal field reference. More...
 
virtual tmp< fvPatchVectorFieldclone (const DimensionedField< vector, volMesh > &iF) const
 Construct and return a clone setting internal field reference. More...
 
virtual void updateCoeffs ()
 Update the coefficients associated with the patch field. More...
 
virtual void write (Ostream &) const
 Write. More...
 

Detailed Description

Velocity inlet boundary condition creating a normal velocity field to match the specified mass or volumetric flow rate, and radial and tangential velocity fields specified by functions of time and radius or by a given angular speed.

For a mass-based flux:

  • the flow rate should be provided in kg/s
  • if rho is "none" the flow rate is in m3/s
  • otherwise rho should correspond to the name of the density field
  • if the density field cannot be found in the database, the user must specify the inlet density using the rhoInlet entry

For a volumetric-based flux:

  • the flow rate is in m3/s
Usage
Property Description Required Default value
origin Origin of rotation no patch centre
axis Axis of rotation no patch normal
massFlowRate Mass flow rate [kg/s] no
volumetricFlowRate Volumetric flow rate [m^3/s] no
rho Density field name no rho
rhoInlet Inlet density no
radialVelocity Radial velocity [m/s] yes
omega Angular velocity of the frame no
tangentialVelocity Tangential velocity [m/s] no

Example of the boundary condition specification:

    <patchName>
    {
        type            swirlFlowRateInletVelocity;
        origin          (0 0 0);
        axis            (0 0 1);
        volumetricFlowRate constant 0.2;
        radialVelocity  constant 10;
        omega           constant 100 [rpm];
    }

The volumetricFlowRate or massFlowRate and the omega entries are Function1 of time, see Foam::Function1s. The radialVelocity and tangentialVelocity entries are Function2 of time and radius, see Foam::Function2s.

Note:

  • rhoInlet is required for the case of a mass flow rate, where the density field is not available at start-up
  • The value is positive into the domain (as an inlet)
  • May not work correctly for transonic inlets
  • Strange behaviour with potentialFoam since the U equation is not solved
See also
Foam::fixedValueFvPatchField Foam::Function1s Foam::Function2s
Source files

Definition at line 156 of file swirlFlowRateInletVelocityFvPatchVectorField.H.

Constructor & Destructor Documentation

◆ swirlFlowRateInletVelocityFvPatchVectorField() [1/4]

◆ swirlFlowRateInletVelocityFvPatchVectorField() [2/4]

Construct by mapping given.

flowRateInletVelocityFvPatchVectorField onto a new patch

Definition at line 191 of file swirlFlowRateInletVelocityFvPatchVectorField.C.

◆ swirlFlowRateInletVelocityFvPatchVectorField() [3/4]

Disallow copy without setting internal field reference.

◆ swirlFlowRateInletVelocityFvPatchVectorField() [4/4]

Copy constructor setting internal field reference.

Definition at line 213 of file swirlFlowRateInletVelocityFvPatchVectorField.C.

Member Function Documentation

◆ TypeName()

TypeName ( "swirlFlowRateInletVelocity"  )

Runtime type information.

◆ clone()

virtual tmp<fvPatchVectorField> clone ( const DimensionedField< vector, volMesh > &  iF) const
inlinevirtual

Construct and return a clone setting internal field reference.

Definition at line 238 of file swirlFlowRateInletVelocityFvPatchVectorField.H.

References swirlFlowRateInletVelocityFvPatchVectorField::swirlFlowRateInletVelocityFvPatchVectorField().

Here is the call graph for this function:

◆ updateCoeffs()

void updateCoeffs ( )
virtual

Update the coefficients associated with the patch field.

Definition at line 235 of file swirlFlowRateInletVelocityFvPatchVectorField.C.

References Foam::exit(), Foam::FatalError, FatalErrorInFunction, and fvPatchField< Type >::updateCoeffs().

Here is the call graph for this function:

◆ write()

void write ( Ostream os) const
virtual

Write.

Definition at line 275 of file swirlFlowRateInletVelocityFvPatchVectorField.C.

References Foam::dimLength, Foam::dimVelocity, Foam::unitAny, fvPatchField< Type >::write(), and Foam::writeEntry().

Here is the call graph for this function:

The documentation for this class was generated from the following files: