Velocity inlet boundary condition creating a velocity field with optionally specified profile normal to the patch adjusted to match the specified mass flow rate, volumetric flow rate or mean velocity. More...
Public Member Functions | |
TypeName ("flowRateInletVelocity") | |
Runtime type information. More... | |
flowRateInletVelocityFvPatchVectorField (const fvPatch &, const DimensionedField< vector, volMesh > &, const dictionary &) | |
Construct from patch, internal field and dictionary. More... | |
flowRateInletVelocityFvPatchVectorField (const flowRateInletVelocityFvPatchVectorField &, const fvPatch &, const DimensionedField< vector, volMesh > &, const fieldMapper &) | |
Construct by mapping given. More... | |
flowRateInletVelocityFvPatchVectorField (const flowRateInletVelocityFvPatchVectorField &)=delete | |
Disallow copy without setting internal field reference. More... | |
flowRateInletVelocityFvPatchVectorField (const flowRateInletVelocityFvPatchVectorField &, const DimensionedField< vector, volMesh > &) | |
Copy constructor setting internal field reference. More... | |
virtual tmp< fvPatchVectorField > | clone (const DimensionedField< vector, volMesh > &iF) const |
Construct and return a clone setting internal field reference. More... | |
virtual void | map (const fvPatchVectorField &, const fieldMapper &) |
Map the given fvPatchField onto this fvPatchField. More... | |
virtual void | reset (const fvPatchVectorField &) |
Reset the fvPatchField to the given fvPatchField. More... | |
virtual void | updateCoeffs () |
Update the coefficients associated with the patch field. More... | |
virtual void | write (Ostream &) const |
Write. More... | |
Velocity inlet boundary condition creating a velocity field with optionally specified profile normal to the patch adjusted to match the specified mass flow rate, volumetric flow rate or mean velocity.
For a mass-based flux:
rho
is "none" the flow rate is in m3/srho
should correspond to the name of the density fieldrhoInlet
entryFor a volumetric-based flux:
Property | Description | Required | Default value |
---|---|---|---|
massFlowRate | Mass flow rate [kg/s] | no | |
volumetricFlowRate | Volumetric flow rate [m^3/s] | no | |
meanVelocity | Mean velocity [m/s] | no | |
profile | Velocity profile | no | |
rho | Density field name | no | rho |
rhoInlet | Inlet density | no | |
alpha | Volume fraction field name | no |
Example of the boundary condition specification for a volumetric flow rate:
<patchName> { type flowRateInletVelocity; volumetricFlowRate 0.2; profile laminarBL; }
Example of the boundary condition specification for a mass flow rate:
<patchName> { type flowRateInletVelocity; massFlowRate 0.2; profile turbulentBL; rho rho; rhoInlet 1.0; }
Example of the boundary condition specification for a volumetric flow rate:
<patchName> { type flowRateInletVelocity; meanVelocity 5; profile turbulentBL; }
The volumetricFlowRate
, massFlowRate
or meanVelocity
entries are Function1
of time, see Foam::Function1s.
The profile
entry is a Function1
of the normalised distance to the wall. Any suitable Foam::Function1s can be used including Foam::Function1s::codedFunction1 but Foam::Function1s::laminarBL and Foam::Function1s::turbulentBL have been created specifically for this purpose and are likely to be appropriate for most cases.
Note:
rhoInlet
is required for the case of a mass flow rate, where the density field is not available at start-upDefinition at line 168 of file flowRateInletVelocityFvPatchVectorField.H.
flowRateInletVelocityFvPatchVectorField | ( | const fvPatch & | p, |
const DimensionedField< vector, volMesh > & | iF, | ||
const dictionary & | dict | ||
) |
Construct from patch, internal field and dictionary.
Definition at line 137 of file flowRateInletVelocityFvPatchVectorField.C.
References UPstream::blocking, dict, DimensionedField< Type, GeoMesh >::dimensions(), Foam::dimless, Foam::dimMassFlux, Foam::dimVelocity, Foam::dimVolumetricFlux, Foam::evaluate(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, Function1< Type >::New(), and p.
Referenced by flowRateInletVelocityFvPatchVectorField::clone().
flowRateInletVelocityFvPatchVectorField | ( | const flowRateInletVelocityFvPatchVectorField & | ptf, |
const fvPatch & | p, | ||
const DimensionedField< vector, volMesh > & | iF, | ||
const fieldMapper & | mapper | ||
) |
Construct by mapping given.
flowRateInletVelocityFvPatchVectorField onto a new patch
Definition at line 227 of file flowRateInletVelocityFvPatchVectorField.C.
|
delete |
Disallow copy without setting internal field reference.
flowRateInletVelocityFvPatchVectorField | ( | const flowRateInletVelocityFvPatchVectorField & | ptf, |
const DimensionedField< vector, volMesh > & | iF | ||
) |
Copy constructor setting internal field reference.
Definition at line 254 of file flowRateInletVelocityFvPatchVectorField.C.
TypeName | ( | "flowRateInletVelocity" | ) |
Runtime type information.
|
inlinevirtual |
Construct and return a clone setting internal field reference.
Definition at line 272 of file flowRateInletVelocityFvPatchVectorField.H.
References flowRateInletVelocityFvPatchVectorField::flowRateInletVelocityFvPatchVectorField().
|
virtual |
Map the given fvPatchField onto this fvPatchField.
Definition at line 276 of file flowRateInletVelocityFvPatchVectorField.C.
|
virtual |
Reset the fvPatchField to the given fvPatchField.
Used for mesh to mesh mapping
Definition at line 294 of file flowRateInletVelocityFvPatchVectorField.C.
|
virtual |
Update the coefficients associated with the patch field.
Definition at line 311 of file flowRateInletVelocityFvPatchVectorField.C.
References Foam::exit(), Foam::FatalError, FatalErrorInFunction, and word::null.
|
virtual |
Write.
Definition at line 341 of file flowRateInletVelocityFvPatchVectorField.C.
References word::null, Foam::unitAny, fvPatchField< Type >::write(), and Foam::writeEntry().