Solitary wave model. More...
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< waveModel > | clone () 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... | |
scalar | celerity () const |
The wave celerity [m/s]. More... | |
virtual tmp< scalarField > | elevation (const scalar t, const scalarField &x) const |
Get the wave elevation at a given time and local coordinates. Local. More... | |
virtual tmp< vector2DField > | velocity (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< waveModel > | New (const dictionary &dict, const scalar g) |
Select. More... | |
static autoPtr< waveModel > | New (const word &type, const dictionary &dict, const scalar g) |
Select. More... | |
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.
Property | Description | Required? | Default |
---|---|---|---|
depth | The water depth [m] | no | great |
amplitude | Peak amplitude [m] | yes | |
offset | The positional offset [m] | yes |
Example specification in constant/waveProperties:
waves ( solitary { length 40; amplitude 0.5; offset 0; } );
Definition at line 100 of file solitary.H.
Construct a copy.
Definition at line 86 of file solitary.C.
Referenced by solitary::clone().
solitary | ( | const dictionary & | dict, |
const scalar | g | ||
) |
Construct from a dictionary and gravity.
Definition at line 95 of file solitary.C.
|
virtual |
Destructor.
Definition at line 110 of file solitary.C.
TypeName | ( | "solitary" | ) |
Runtime type information.
Construct a clone.
Implements waveModel.
Definition at line 155 of file solitary.H.
References solitary::solitary().
|
inline |
Get the depth.
Definition at line 170 of file solitary.H.
|
inline |
Get the amplitude.
Definition at line 176 of file solitary.H.
|
inline |
Get the offset.
Definition at line 182 of file solitary.H.
|
virtual |
The wave celerity [m/s].
Implements waveModel.
Definition at line 56 of file solitary.C.
References alpha(), and Foam::sqrt().
|
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 116 of file solitary.C.
References x.
|
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 126 of file solitary.C.
References A, alpha(), Field< Type >::component(), k, Foam::max(), Foam::sqr(), Foam::tanh(), and Foam::zip().
|
virtual |
Write.
Reimplemented from waveModel.
Definition at line 154 of file solitary.C.
References waveModel::write(), and Foam::writeEntry().