solitary Class Reference

Solitary wave model. More...

Inheritance diagram for solitary:
Collaboration diagram for solitary:

Public Member Functions

 TypeName ("solitary")
 Runtime type information. More...
 
 solitary (const solitary &wave)
 Construct a copy. More...
 
 solitary (const dictionary &dict, const scalar g)
 Construct from a dictionary and gravity. More...
 
virtual autoPtr< waveModelclone () const
 Construct a clone. More...
 
virtual ~solitary ()
 Destructor. More...
 
scalar depth () const
 Get the depth. More...
 
scalar amplitude () const
 Get the amplitude. More...
 
scalar offset () const
 Get the offset. More...
 
virtual tmp< scalarFieldelevation (const scalar t, const scalarField &x) const
 Get the wave elevation at a given time and local coordinates. Local. More...
 
virtual tmp< vector2DFieldvelocity (const scalar t, const vector2DField &xz) const
 Get the wave velocity at a given time and local coordinates. Local. More...
 
virtual void write (Ostream &os) const
 Write. More...
 
- Public Member Functions inherited from waveModel
 TypeName ("waveModel")
 Runtime type information. More...
 
 declareRunTimeSelectionTable (autoPtr, waveModel, dictionary,(const dictionary &dict, const scalar g),(dict, g))
 
 waveModel (const waveModel &wave)
 Construct a copy. More...
 
 waveModel (const dictionary &dict, const scalar g)
 Construct from a dictionary and gravity. More...
 
virtual ~waveModel ()
 Destructor. More...
 
scalar g () const
 Get the value of gravity. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from waveModel
static autoPtr< waveModelNew (const dictionary &dict, const scalar g)
 Select. More...
 
static autoPtr< waveModelNew (const word &type, const dictionary &dict, const scalar g)
 Select. More...
 

Detailed Description

Solitary wave model.

Reference:

    Dean, R. G., & Dalrymple, R. A. (1991).
    Water wave mechanics for engineers and scientists (Vol. 2).
    World Scientific Publishing Company.

See pages 314-317.

Source files

Definition at line 59 of file solitary.H.

Constructor & Destructor Documentation

◆ solitary() [1/2]

solitary ( const solitary wave)

Construct a copy.

Definition at line 86 of file solitary.C.

Referenced by solitary::clone().

Here is the caller graph for this function:

◆ solitary() [2/2]

solitary ( const dictionary dict,
const scalar  g 
)

Construct from a dictionary and gravity.

Definition at line 96 of file solitary.C.

◆ ~solitary()

~solitary ( )
virtual

Destructor.

Definition at line 110 of file solitary.C.

References solitary::elevation().

Referenced by solitary::clone().

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

Member Function Documentation

◆ TypeName()

TypeName ( "solitary"  )

Runtime type information.

◆ clone()

virtual autoPtr<waveModel> clone ( ) const
inlinevirtual

Construct a clone.

Implements waveModel.

Definition at line 117 of file solitary.H.

References solitary::solitary(), and solitary::~solitary().

Here is the call graph for this function:

◆ depth()

scalar depth ( ) const
inline

Get the depth.

Definition at line 132 of file solitary.H.

Referenced by solitary::velocity().

Here is the caller graph for this function:

◆ amplitude()

scalar amplitude ( ) const
inline

Get the amplitude.

Definition at line 138 of file solitary.H.

Referenced by solitary::elevation().

Here is the caller graph for this function:

◆ offset()

scalar offset ( ) const
inline

Get the offset.

Definition at line 144 of file solitary.H.

References solitary::elevation(), solitary::velocity(), and solitary::write().

Here is the call graph for this function:

◆ elevation()

Foam::tmp< Foam::scalarField > elevation ( const scalar  t,
const scalarField x 
) const
virtual

Get the wave elevation at a given time and local coordinates. Local.

x is aligned with the direction of propagation.

Implements waveModel.

Definition at line 117 of file solitary.C.

References solitary::amplitude(), and solitary::velocity().

Referenced by solitary::offset(), and solitary::~solitary().

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

◆ velocity()

Foam::tmp< Foam::vector2DField > velocity ( const scalar  t,
const vector2DField xz 
) const
virtual

Get the wave velocity at a given time and local coordinates. Local.

x is aligned with the direction of propagation, and z with negative gravity.

Implements waveModel.

Definition at line 127 of file solitary.C.

References Field< Type >::component(), solitary::depth(), Foam::max(), Foam::sqr(), Foam::tanh(), and Foam::zip().

Referenced by solitary::elevation(), and solitary::offset().

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

◆ write()

void write ( Ostream os) const
virtual

Write.

Reimplemented from waveModel.

Definition at line 154 of file solitary.C.

References waveModel::write(), and Foam::writeEntry().

Referenced by solitary::offset().

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: