Public Member Functions | List of all members
waveVelocityFvPatchVectorField Class Reference

This boundary condition provides a waveVelocity condition. This sets the velocity to that specified by a superposition of wave models. The corresponding phase fraction condition looks this condition up and re-uses the wave modelling. More...

Inheritance diagram for waveVelocityFvPatchVectorField:
Inheritance graph
[legend]
Collaboration diagram for waveVelocityFvPatchVectorField:
Collaboration graph
[legend]

Public Member Functions

 TypeName ("waveVelocity")
 Runtime type information. More...
 
 waveVelocityFvPatchVectorField (const fvPatch &, const DimensionedField< vector, volMesh > &)
 Construct from patch and internal field. More...
 
 waveVelocityFvPatchVectorField (const fvPatch &, const DimensionedField< vector, volMesh > &, const dictionary &)
 Construct from patch, internal field and dictionary. More...
 
 waveVelocityFvPatchVectorField (const waveVelocityFvPatchVectorField &, const fvPatch &, const DimensionedField< vector, volMesh > &, const fvPatchFieldMapper &)
 Construct by mapping given mixedTypeFvPatchField onto a new patch. More...
 
 waveVelocityFvPatchVectorField (const waveVelocityFvPatchVectorField &)
 Construct as copy. More...
 
virtual tmp< fvPatchVectorFieldclone () const
 Construct and return a clone. More...
 
 waveVelocityFvPatchVectorField (const waveVelocityFvPatchVectorField &, const DimensionedField< vector, volMesh > &)
 Construct as copy setting internal field reference. More...
 
virtual tmp< fvPatchVectorFieldclone (const DimensionedField< vector, volMesh > &iF) const
 Construct and return a clone setting internal field reference. More...
 
const waveSuperpositionwaves () const
 Access the wave models. More...
 
tmp< vectorFieldU () const
 Return the current modelled velocity field. More...
 
virtual void updateCoeffs ()
 Update the coefficients associated with the patch field. More...
 
virtual void write (Ostream &) const
 Write. More...
 

Detailed Description

This boundary condition provides a waveVelocity condition. This sets the velocity to that specified by a superposition of wave models. The corresponding phase fraction condition looks this condition up and re-uses the wave modelling.

Usage
Property Description Req'd? Default
origin origin of the wave coordinate system yes
direction direction of the mean flow yes
speed speed of the mean flow yes
waves list of wave models to superimpose yes
scale scale factor along the mean flow direction no None
crossScale scale factor across the mean flow direction no None

Example of the boundary condition specification:

    <patchName>
    {
        type        waveVelocity;
        origin      (0 25 0);
        direction   (1 0 0);
        speed       2;
        waves
        (
            Airy
            {
                length      40;
                amplitude   0.5;
                phase       0;
                angle       0;
            }
            Airy
            {
                length      20;
                amplitude   0.25;
                phase       1.5708;
                angle       0;
            }
        );
        scale       table ((100 1) (200 0));
        crossScale  constant 1;
    }
Source files

Definition at line 131 of file waveVelocityFvPatchVectorField.H.

Constructor & Destructor Documentation

◆ waveVelocityFvPatchVectorField() [1/5]

Construct from patch and internal field.

Definition at line 35 of file waveVelocityFvPatchVectorField.C.

References Foam::Zero.

Referenced by waveVelocityFvPatchVectorField::clone(), and waveVelocityFvPatchVectorField::waveVelocityFvPatchVectorField().

Here is the caller graph for this function:

◆ waveVelocityFvPatchVectorField() [2/5]

waveVelocityFvPatchVectorField ( const fvPatch p,
const DimensionedField< vector, volMesh > &  iF,
const dictionary dict 
)

Construct from patch, internal field and dictionary.

Definition at line 50 of file waveVelocityFvPatchVectorField.C.

References dictionary::found(), fvPatch::size(), vectorField(), waveVelocityFvPatchVectorField::waveVelocityFvPatchVectorField(), and Foam::Zero.

Here is the call graph for this function:

◆ waveVelocityFvPatchVectorField() [3/5]

waveVelocityFvPatchVectorField ( const waveVelocityFvPatchVectorField ptf,
const fvPatch p,
const DimensionedField< vector, volMesh > &  iF,
const fvPatchFieldMapper mapper 
)

Construct by mapping given mixedTypeFvPatchField onto a new patch.

Definition at line 75 of file waveVelocityFvPatchVectorField.C.

References waveVelocityFvPatchVectorField::waveVelocityFvPatchVectorField().

Here is the call graph for this function:

◆ waveVelocityFvPatchVectorField() [4/5]

Construct as copy.

Definition at line 88 of file waveVelocityFvPatchVectorField.C.

References waveVelocityFvPatchVectorField::waveVelocityFvPatchVectorField().

Here is the call graph for this function:

◆ waveVelocityFvPatchVectorField() [5/5]

Construct as copy setting internal field reference.

Definition at line 98 of file waveVelocityFvPatchVectorField.C.

Member Function Documentation

◆ TypeName()

TypeName ( "waveVelocity"  )

Runtime type information.

◆ clone() [1/2]

virtual tmp<fvPatchVectorField> clone ( ) const
inlinevirtual

Construct and return a clone.

Definition at line 180 of file waveVelocityFvPatchVectorField.H.

References waveVelocityFvPatchVectorField::waveVelocityFvPatchVectorField().

Here is the call graph for this function:

◆ clone() [2/2]

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

Construct and return a clone setting internal field reference.

Definition at line 197 of file waveVelocityFvPatchVectorField.H.

References waveVelocityFvPatchVectorField::waveVelocityFvPatchVectorField().

Here is the call graph for this function:

◆ waves()

const waveSuperposition& waves ( ) const
inline

Access the wave models.

Definition at line 213 of file waveVelocityFvPatchVectorField.H.

References waveVelocityFvPatchVectorField::U(), waveVelocityFvPatchVectorField::updateCoeffs(), and waveVelocityFvPatchVectorField::write().

Referenced by waveAlphaFvPatchScalarField::alpha().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ U()

Foam::tmp< Foam::vectorField > U ( ) const

Return the current modelled velocity field.

Definition at line 110 of file waveVelocityFvPatchVectorField.C.

References waveSuperposition::height(), Foam::levelSetAverage(), waveSuperposition::UGas(), and waveSuperposition::ULiquid().

Referenced by waveVelocityFvPatchVectorField::updateCoeffs(), and waveVelocityFvPatchVectorField::waves().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateCoeffs()

void updateCoeffs ( )
virtual

Update the coefficients associated with the patch field.

Definition at line 128 of file waveVelocityFvPatchVectorField.C.

References Foam::I, Foam::pos0(), Foam::sqr(), waveVelocityFvPatchVectorField::U(), and waveVelocityFvPatchVectorField::write().

Referenced by waveVelocityFvPatchVectorField::waves().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ write()

void write ( Ostream os) const
virtual

Write.

Definition at line 151 of file waveVelocityFvPatchVectorField.C.

References Foam::makePatchTypeField(), Foam::blockMeshTools::write(), and waveSuperposition::write().

Referenced by waveVelocityFvPatchVectorField::updateCoeffs(), and waveVelocityFvPatchVectorField::waves().

Here is the call graph for this function:
Here is the caller graph for this function:

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