freeSurfacePressureFvPatchScalarField Class Reference

This boundary condition provides static pressure condition for p_rgh, calculated as: More...

Inheritance diagram for freeSurfacePressureFvPatchScalarField:
[legend]
Collaboration diagram for freeSurfacePressureFvPatchScalarField:
[legend]

Public Member Functions

 TypeName ("freeSurfacePressure")
 Runtime type information. More...
 
 freeSurfacePressureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &)
 Construct from patch and internal field. More...
 
 freeSurfacePressureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &, const dictionary &)
 Construct from patch, internal field and dictionary. More...
 
 freeSurfacePressureFvPatchScalarField (const freeSurfacePressureFvPatchScalarField &, const fvPatch &, const DimensionedField< scalar, volMesh > &, const fvPatchFieldMapper &)
 Construct by mapping given. More...
 
 freeSurfacePressureFvPatchScalarField (const freeSurfacePressureFvPatchScalarField &)
 Construct as copy. More...
 
virtual tmp< fvPatchScalarField > clone () const
 Construct and return a clone. More...
 
 freeSurfacePressureFvPatchScalarField (const freeSurfacePressureFvPatchScalarField &, const DimensionedField< scalar, volMesh > &)
 Construct as copy 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...
 
const scalarField & pa () const
 Return the ambient pressure. More...
 
scalarField & pa ()
 Return reference to the ambient pressure to allow adjustment. 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 updateCoeffs ()
 Update the coefficients associated with the patch field. More...
 
virtual void write (Ostream &) const
 Write. More...
 

Protected Attributes

scalarField pa_
 Ambient pressure. More...
 

Detailed Description

This boundary condition provides static pressure condition for p_rgh, calculated as:

\[ p = pa - \vec{g} \cdot \vec{r} \]

where

\( p \) = Free surface modified pressure
\( pa \) = Free surface ambient pressure
\( g \) = acceleration due to gravity [m/s^2]
Usage
Property Description Required Default value
pa static ambient pressure yes 0

Example of the boundary condition specification:

    <patchName>
    {
        type            freeSurfacePressure;
        pa              uniform 0;
        value           uniform 0; // optional initial value
    }
See also
Foam::fixedValueFvPatchScalarField
Source files

Definition at line 106 of file freeSurfacePressureFvPatchScalarField.H.

Constructor & Destructor Documentation

◆ freeSurfacePressureFvPatchScalarField() [1/5]

freeSurfacePressureFvPatchScalarField ( const fvPatch &  p,
const DimensionedField< scalar, volMesh > &  iF 
)

Construct from patch and internal field.

Definition at line 41 of file freeSurfacePressureFvPatchScalarField.C.

Referenced by freeSurfacePressureFvPatchScalarField::clone().

Here is the caller graph for this function:

◆ freeSurfacePressureFvPatchScalarField() [2/5]

freeSurfacePressureFvPatchScalarField ( const fvPatch &  p,
const DimensionedField< scalar, volMesh > &  iF,
const dictionary &  dict 
)

Construct from patch, internal field and dictionary.

Definition at line 53 of file freeSurfacePressureFvPatchScalarField.C.

References dict, dictionary::found(), and p.

Here is the call graph for this function:

◆ freeSurfacePressureFvPatchScalarField() [3/5]

freeSurfacePressureFvPatchScalarField ( const freeSurfacePressureFvPatchScalarField &  ptf,
const fvPatch &  p,
const DimensionedField< scalar, volMesh > &  iF,
const fvPatchFieldMapper &  mapper 
)

Construct by mapping given.

freeSurfacePressureFvPatchScalarField onto a new patch

Definition at line 78 of file freeSurfacePressureFvPatchScalarField.C.

◆ freeSurfacePressureFvPatchScalarField() [4/5]

◆ freeSurfacePressureFvPatchScalarField() [5/5]

Construct as copy setting internal field reference.

Definition at line 103 of file freeSurfacePressureFvPatchScalarField.C.

Member Function Documentation

◆ TypeName()

TypeName ( "freeSurfacePressure"  )

Runtime type information.

◆ clone() [1/2]

virtual tmp<fvPatchScalarField> clone ( ) const
inlinevirtual

Construct and return a clone.

Definition at line 157 of file freeSurfacePressureFvPatchScalarField.H.

References freeSurfacePressureFvPatchScalarField::freeSurfacePressureFvPatchScalarField().

Here is the call graph for this function:

◆ clone() [2/2]

virtual tmp<fvPatchScalarField> clone ( const DimensionedField< scalar, volMesh > &  iF) const
inlinevirtual

Construct and return a clone setting internal field reference.

Definition at line 174 of file freeSurfacePressureFvPatchScalarField.H.

References freeSurfacePressureFvPatchScalarField::freeSurfacePressureFvPatchScalarField().

Here is the call graph for this function:

◆ pa() [1/2]

const scalarField& pa ( ) const
inline

Return the ambient pressure.

Definition at line 190 of file freeSurfacePressureFvPatchScalarField.H.

References freeSurfacePressureFvPatchScalarField::pa_.

◆ pa() [2/2]

scalarField& pa ( )
inline

Return reference to the ambient pressure to allow adjustment.

Definition at line 196 of file freeSurfacePressureFvPatchScalarField.H.

References freeSurfacePressureFvPatchScalarField::pa_.

◆ autoMap()

void autoMap ( const fvPatchFieldMapper &  m)
virtual

Map (and resize as needed) from self given a mapping object.

Definition at line 116 of file freeSurfacePressureFvPatchScalarField.C.

◆ rmap()

void rmap ( const fvPatchScalarField &  ptf,
const labelList &  addr 
)
virtual

Reverse map the given fvPatchField onto this fvPatchField.

Definition at line 126 of file freeSurfacePressureFvPatchScalarField.C.

References freeSurfacePressureFvPatchScalarField::pa_.

◆ updateCoeffs()

void updateCoeffs ( )
virtual

Update the coefficients associated with the patch field.

Definition at line 140 of file freeSurfacePressureFvPatchScalarField.C.

References interfaceTrackingFvMesh::freeSurfacePressureJump(), objectRegistry::lookupObject(), mesh, freeSurfacePressureFvPatchScalarField::pa_, and Foam::foamVersion::patch.

Here is the call graph for this function:

◆ write()

void write ( Ostream &  os) const
virtual

Write.

Definition at line 167 of file freeSurfacePressureFvPatchScalarField.C.

References fvPatchField< scalar >::write().

Here is the call graph for this function:

Member Data Documentation

◆ pa_


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