Inflow, outflow and entrainment pressure boundary condition based on a constant total pressure assumption. More...
Public Member Functions | |
TypeName ("totalPressure") | |
Runtime type information. More... | |
totalPressureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &) | |
Construct from patch and internal field. More... | |
totalPressureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &, const dictionary &) | |
Construct from patch, internal field and dictionary. More... | |
totalPressureFvPatchScalarField (const totalPressureFvPatchScalarField &, const fvPatch &, const DimensionedField< scalar, volMesh > &, const fvPatchFieldMapper &) | |
Construct by mapping given totalPressureFvPatchScalarField. More... | |
totalPressureFvPatchScalarField (const totalPressureFvPatchScalarField &)=delete | |
Disallow copy without setting internal field reference. More... | |
totalPressureFvPatchScalarField (const totalPressureFvPatchScalarField &, const DimensionedField< scalar, volMesh > &) | |
Copy constructor setting internal field reference. More... | |
virtual tmp< fvPatchScalarField > | clone (const DimensionedField< scalar, 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... | |
Public Member Functions inherited from dynamicPressureFvPatchScalarField | |
TypeName ("dynamicPressure") | |
Runtime type information. More... | |
dynamicPressureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &) | |
Construct from patch and internal field. More... | |
dynamicPressureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &, const dictionary &) | |
Construct from patch, internal field and dictionary. More... | |
dynamicPressureFvPatchScalarField (const dynamicPressureFvPatchScalarField &, const fvPatch &, const DimensionedField< scalar, volMesh > &, const fvPatchFieldMapper &) | |
Construct by mapping given dynamicPressureFvPatchScalarField. More... | |
dynamicPressureFvPatchScalarField (const dynamicPressureFvPatchScalarField &)=delete | |
Disallow copy without setting internal field reference. More... | |
dynamicPressureFvPatchScalarField (const dynamicPressureFvPatchScalarField &, const DimensionedField< scalar, volMesh > &) | |
Copy constructor setting internal field reference. More... | |
virtual void | autoMap (const fvPatchFieldMapper &) |
Map (and resize as needed) from self given a mapping object. More... | |
virtual void | rmap (const fvPatchScalarField &, const labelList &) |
Reverse map the given fvPatchField onto this fvPatchField. More... | |
virtual void | reset (const fvPatchScalarField &) |
Reset the fvPatchField to the given fvPatchField. More... | |
Protected Attributes | |
const word | UName_ |
Name of the velocity field. More... | |
const word | phiName_ |
Name of the flux field. More... | |
Protected Attributes inherited from dynamicPressureFvPatchScalarField | |
const word | rhoName_ |
Name of the density field used to normalise the mass flux. More... | |
const word | psiName_ |
Name of the compressibility field used to calculate the wave speed. More... | |
const scalar | gamma_ |
Heat capacity ratio. More... | |
scalarField | p0_ |
Reference pressure. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from dynamicPressureFvPatchScalarField | |
void | updateCoeffs (const scalarField &p0p, const scalarField &K0mKp) |
Update the coefficients associated with the patch field. More... | |
Inflow, outflow and entrainment pressure boundary condition based on a constant total pressure assumption.
For outflow the patch pressure is set to the external static pressure.
For inflow the patch pressure is evaluated from the patch velocity and the external total pressure obtained from the external static pressure p_0
and external velocity U_0
which is looked-up from the the optional tangentialVelocity
entry in the pressureInletOutletVelocity
velocity boundary condition for the patch if that boundary condition is used, otherwise U_0
is assumed zero and the external total pressure is equal to the external static pressure.
The patch pressure is evaluated from the external conditions using one of the following expressions depending on the flow conditions and specification of compressibility:
1. incompressible subsonic:
where
= | pressure at patch [m^2/s^2] | |
= | external static pressure [m^2/s^2] | |
= | velocity [m/s] | |
= | external velocity [m/s] |
2. compressible subsonic:
where
= | pressure at patch [Pa] | |
= | external static pressure [Pa] | |
= | density [kg/m^3] | |
= | velocity [m/s] | |
= | external velocity [m/s] |
3. compressible transonic ( ):
where
= | pressure at patch [Pa] | |
= | external static pressure [Pa] | |
= | compressibility [m^2/s^2] | |
= | density [kg/m^3] | |
= | velocity [m/s] | |
= | external velocity [m/s] |
4. compressible supersonic ( ):
where
= | pressure at patch [Pa] | |
= | external static pressure [Pa] | |
= | compressibility [m^2/s^2] | |
= | density [kg/m^3] | |
= | coefficient given by [] | |
= | ratio of specific heats (Cp/Cv) [] | |
= | velocity [m/s] | |
= | external velocity [m/s] |
The modes of operation are set by the dimensions of the pressure field to which this boundary condition is applied, the psi
entry and the value of gamma:
Mode | dimensions | psi | gamma |
---|---|---|---|
incompressible subsonic | p/rho | ||
compressible subsonic | p | none | |
compressible transonic | p | psi | 1 |
compressible supersonic | p | psi | > 1 |
Property | Description | Required | Default value |
---|---|---|---|
U | Velocity field name | no | U |
phi | Flux field name | no | phi |
rho | Density field name | no | rho |
psi | Compressibility field name | no | none |
gamma | (Cp/Cv) | no | 1 |
p0 | External pressure | yes |
Example of the boundary condition specification:
<patchName> { type totalPressure; p0 uniform 1e5; }
Definition at line 307 of file totalPressureFvPatchScalarField.H.
totalPressureFvPatchScalarField | ( | const fvPatch & | p, |
const DimensionedField< scalar, volMesh > & | iF | ||
) |
Construct from patch and internal field.
Definition at line 36 of file totalPressureFvPatchScalarField.C.
Referenced by totalPressureFvPatchScalarField::clone(), and totalPressureFvPatchScalarField::totalPressureFvPatchScalarField().
totalPressureFvPatchScalarField | ( | const fvPatch & | p, |
const DimensionedField< scalar, volMesh > & | iF, | ||
const dictionary & | dict | ||
) |
Construct from patch, internal field and dictionary.
Definition at line 48 of file totalPressureFvPatchScalarField.C.
References totalPressureFvPatchScalarField::totalPressureFvPatchScalarField().
totalPressureFvPatchScalarField | ( | const totalPressureFvPatchScalarField & | ptf, |
const fvPatch & | p, | ||
const DimensionedField< scalar, volMesh > & | iF, | ||
const fvPatchFieldMapper & | mapper | ||
) |
Construct by mapping given totalPressureFvPatchScalarField.
onto a new patch
Definition at line 61 of file totalPressureFvPatchScalarField.C.
References totalPressureFvPatchScalarField::totalPressureFvPatchScalarField().
|
delete |
Disallow copy without setting internal field reference.
totalPressureFvPatchScalarField | ( | const totalPressureFvPatchScalarField & | tppsf, |
const DimensionedField< scalar, volMesh > & | iF | ||
) |
Copy constructor setting internal field reference.
Definition at line 75 of file totalPressureFvPatchScalarField.C.
TypeName | ( | "totalPressure" | ) |
Runtime type information.
|
inlinevirtual |
Construct and return a clone setting internal field reference.
Reimplemented in fanPressureFvPatchScalarField, and rotatingTotalPressureFvPatchScalarField.
Definition at line 370 of file totalPressureFvPatchScalarField.H.
References totalPressureFvPatchScalarField::totalPressureFvPatchScalarField(), totalPressureFvPatchScalarField::updateCoeffs(), and totalPressureFvPatchScalarField::write().
|
virtual |
Update the coefficients associated with the patch field.
Reimplemented in fanPressureFvPatchScalarField, and rotatingTotalPressureFvPatchScalarField.
Definition at line 88 of file totalPressureFvPatchScalarField.C.
References Foam::magSqr(), Foam::neg(), dynamicPressureFvPatchScalarField::p0_, totalPressureFvPatchScalarField::phiName_, pressureInletOutletVelocityFvPatchVectorField::tangentialVelocity(), totalPressureFvPatchScalarField::UName_, and dynamicPressureFvPatchScalarField::updateCoeffs().
Referenced by totalPressureFvPatchScalarField::clone().
|
virtual |
Write.
Reimplemented from dynamicPressureFvPatchScalarField.
Reimplemented in fanPressureFvPatchScalarField, and rotatingTotalPressureFvPatchScalarField.
Definition at line 124 of file totalPressureFvPatchScalarField.C.
References Foam::makePatchTypeField(), totalPressureFvPatchScalarField::phiName_, totalPressureFvPatchScalarField::UName_, and dynamicPressureFvPatchScalarField::write().
Referenced by totalPressureFvPatchScalarField::clone(), rotatingTotalPressureFvPatchScalarField::write(), and fanPressureFvPatchScalarField::write().
|
protected |
Name of the velocity field.
Definition at line 316 of file totalPressureFvPatchScalarField.H.
Referenced by rotatingTotalPressureFvPatchScalarField::updateCoeffs(), totalPressureFvPatchScalarField::updateCoeffs(), and totalPressureFvPatchScalarField::write().
|
protected |
Name of the flux field.
Definition at line 319 of file totalPressureFvPatchScalarField.H.
Referenced by rotatingTotalPressureFvPatchScalarField::updateCoeffs(), totalPressureFvPatchScalarField::updateCoeffs(), and totalPressureFvPatchScalarField::write().