Loading...
Searching...
No Matches
waveSurfacePressureFvPatchScalarField Class Reference

This is a pressure boundary condition, whose value is calculated as the hydrostatic pressure based on a given displacement: More...

#include <waveSurfacePressureFvPatchScalarField.H>

Inheritance diagram for waveSurfacePressureFvPatchScalarField:
Collaboration diagram for waveSurfacePressureFvPatchScalarField:

Public Types

enum  ddtSchemeType { tsEuler , tsCrankNicolson , tsBackward }
 Enumeration defining the available ddt schemes. More...

Public Member Functions

 TypeName ("waveSurfacePressure")
 Runtime type information.
 waveSurfacePressureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &)
 Construct from patch and internal field.
 waveSurfacePressureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &, const dictionary &)
 Construct from patch, internal field and dictionary.
 waveSurfacePressureFvPatchScalarField (const waveSurfacePressureFvPatchScalarField &, const fvPatch &, const DimensionedField< scalar, volMesh > &, const fvPatchFieldMapper &)
 Construct by mapping given waveSurfacePressureFvPatchScalarField.
 waveSurfacePressureFvPatchScalarField (const waveSurfacePressureFvPatchScalarField &)
 Construct as copy.
 waveSurfacePressureFvPatchScalarField (const waveSurfacePressureFvPatchScalarField &, const DimensionedField< scalar, volMesh > &)
 Construct as copy setting internal field reference.
virtual tmp< fvPatchField< scalar > > clone () const
 Return a clone.
virtual tmp< fvPatchField< scalar > > clone (const DimensionedField< scalar, volMesh > &iF) const
 Clone with an internal field reference.
virtual void updateCoeffs ()
 Update the coefficients associated with the patch field.
virtual void write (Ostream &) const
 Write.

Detailed Description

This is a pressure boundary condition, whose value is calculated as the hydrostatic pressure based on a given displacement:

\‍[        p = -\rho*g*\zeta
\‍]

$        \rho  $=density [kg/m3]
$        g     $=acceleration due to gravity [m/s2]
$        \zeta $=wave amplitude [m]

The wave amplitude is updated as part of the calculation, derived from the local volumetric flux.

Usage
Property Description Required Default value
phi flux field name no phi
rho density field name no rho
zeta wave amplitude field name no zeta

Example of the boundary condition specification:

    <patchName>
    {
        type            waveSurfacePressure;
        phi             phi;
        rho             rho;
        zeta            zeta;
        value           uniform 0;  // place holder
    }

The density field is only required if the flux is mass-based as opposed to volumetric-based.

See also
Foam::fixedValueFvPatchField
Source files

Definition at line 122 of file waveSurfacePressureFvPatchScalarField.H.

Member Enumeration Documentation

◆ ddtSchemeType

Enumeration defining the available ddt schemes.

Enumerator
tsEuler 
tsCrankNicolson 
tsBackward 

Definition at line 133 of file waveSurfacePressureFvPatchScalarField.H.

Constructor & Destructor Documentation

◆ waveSurfacePressureFvPatchScalarField() [1/5]

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

Construct from patch and internal field.

Definition at line 57 of file waveSurfacePressureFvPatchScalarField.C.

References p.

Referenced by TypeName(), waveSurfacePressureFvPatchScalarField(), waveSurfacePressureFvPatchScalarField(), and waveSurfacePressureFvPatchScalarField().

Here is the caller graph for this function:

◆ waveSurfacePressureFvPatchScalarField() [2/5]

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

Construct from patch, internal field and dictionary.

Definition at line 71 of file waveSurfacePressureFvPatchScalarField.C.

References dict, and p.

◆ waveSurfacePressureFvPatchScalarField() [3/5]

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

Construct by mapping given waveSurfacePressureFvPatchScalarField.

onto a new patch

Definition at line 86 of file waveSurfacePressureFvPatchScalarField.C.

References p, and waveSurfacePressureFvPatchScalarField().

Here is the call graph for this function:

◆ waveSurfacePressureFvPatchScalarField() [4/5]

waveSurfacePressureFvPatchScalarField ( const waveSurfacePressureFvPatchScalarField & wspsf)

Construct as copy.

Definition at line 102 of file waveSurfacePressureFvPatchScalarField.C.

References waveSurfacePressureFvPatchScalarField().

Here is the call graph for this function:

◆ waveSurfacePressureFvPatchScalarField() [5/5]

waveSurfacePressureFvPatchScalarField ( const waveSurfacePressureFvPatchScalarField & wspsf,
const DimensionedField< scalar, volMesh > & iF )

Construct as copy setting internal field reference.

Definition at line 115 of file waveSurfacePressureFvPatchScalarField.C.

References waveSurfacePressureFvPatchScalarField().

Here is the call graph for this function:

Member Function Documentation

◆ TypeName()

TypeName ( "waveSurfacePressure" )

Runtime type information.

References waveSurfacePressureFvPatchScalarField().

Here is the call graph for this function:

◆ clone() [1/2]

virtual tmp< fvPatchField< scalar > > clone ( ) const
inlinevirtual

Return a clone.

Definition at line 228 of file waveSurfacePressureFvPatchScalarField.H.

References fvPatchField< Type >::Clone().

Here is the call graph for this function:

◆ clone() [2/2]

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

Clone with an internal field reference.

Definition at line 236 of file waveSurfacePressureFvPatchScalarField.H.

References fvPatchField< Type >::Clone().

Here is the call graph for this function:

◆ updateCoeffs()

◆ write()

void write ( Ostream & os) const
virtual

Write.

Definition at line 223 of file waveSurfacePressureFvPatchScalarField.C.

References os(), fvPatchField< Type >::write(), and fvPatchField< Type >::writeValueEntry().

Here is the call graph for this function:

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