Second-order wave model. More...
Public Member Functions | |
TypeName ("Stokes2") | |
Runtime type information. More... | |
Stokes2 (const dictionary &dict, const scalar g, const word &modelName=Stokes2::typeName, scalar(*modelCelerity)(scalar, scalar, scalar, scalar)=&Stokes2::celerity) | |
Construct from a dictionary and gravity. More... | |
virtual autoPtr< waveModel > | clone () const |
Construct a clone. More... | |
virtual | ~Stokes2 () |
Destructor. 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... | |
Public Member Functions inherited from Airy | |
TypeName ("Airy") | |
Runtime type information. More... | |
Airy (const Airy &wave) | |
Construct a copy. More... | |
Airy (const dictionary &dict, const scalar g, const word &modelName=Airy::typeName, scalar(*modelCelerity)(scalar, scalar, scalar, scalar)=&Airy::celerity) | |
Construct from a dictionary and gravity. More... | |
virtual | ~Airy () |
Destructor. More... | |
scalar | depth () const |
Get the depth. More... | |
scalar | amplitude (const scalar t) const |
Get the amplitude. More... | |
scalar | amplitude () const |
Get the amplitude at steady state. More... | |
scalar | length () const |
Get the length. More... | |
scalar | phase () const |
Get the phase. 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... | |
Protected Member Functions | |
virtual scalar | celerity () const |
The wave celerity [m/s]. More... | |
Protected Member Functions inherited from Airy | |
scalar | k () const |
The angular wavenumber [rad/m]. More... | |
bool | deep () const |
Return whether shallow and intermediate effects are to be omitted. More... | |
tmp< scalarField > | angle (const scalar t, const scalarField &x) const |
Angle of the oscillation [rad]. More... | |
tmp< vector2DField > | vi (const label i, const scalar t, const vector2DField &xz) const |
Return the non-dimensionalised i-th harmonic of the velocity. More... | |
Static Protected Member Functions | |
static scalar | celerity (const scalar depth, const scalar amplitude, const scalar length, const scalar g) |
The wave celerity [m/s]. More... | |
Static Protected Member Functions inherited from Airy | |
static scalar | k (const scalar length) |
The angular wavenumber [rad/m]. More... | |
static bool | deep (const scalar length, const scalar depth) |
Return whether shallow and intermediate effects are to be omitted. More... | |
static scalar | celerity (const scalar depth, const scalar amplitude, const scalar length, const scalar g) |
The wave celerity [m/s]. 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... | |
Second-order wave model.
Stokes, G.G. (1847) On the theory of oscillatory waves. Transactions of the Cambridge Philosophical Society, 8, 441.
See equations 18 and 19.
Stokes2 | ( | const dictionary & | dict, |
const scalar | g, | ||
const word & | modelName = Stokes2::typeName , |
||
scalar(*)(scalar, scalar, scalar, scalar) | modelCelerity = &Stokes2::celerity |
||
) |
Construct from a dictionary and gravity.
Definition at line 72 of file Stokes2.C.
Referenced by Stokes2::celerity(), and Stokes2::clone().
|
virtual |
Destructor.
Definition at line 85 of file Stokes2.C.
References Stokes2::elevation().
Referenced by Stokes2::clone().
|
staticprotected |
The wave celerity [m/s].
Definition at line 44 of file Stokes2.C.
References Airy::celerity(), Foam::cosh(), Foam::endl(), Foam::Info, k, Foam::log(), Foam::max(), Foam::min(), Foam::fvm::S(), Foam::sqr(), and Stokes2::Stokes2().
|
inlineprotectedvirtual |
The wave celerity [m/s].
Reimplemented from Airy.
Reimplemented in Stokes5.
Definition at line 77 of file Stokes2.H.
References Airy::amplitude(), Airy::depth(), dict, waveModel::g(), Airy::length(), Stokes2::Stokes2(), and Stokes2::TypeName().
Referenced by Stokes5::celerity().
TypeName | ( | "Stokes2" | ) |
Runtime type information.
Referenced by Stokes2::celerity().
Construct a clone.
Reimplemented from Airy.
Reimplemented in Stokes5.
Definition at line 102 of file Stokes2.H.
References Stokes2::elevation(), Stokes2::Stokes2(), Stokes2::velocity(), x, and Stokes2::~Stokes2().
|
virtual |
Get the wave elevation at a given time and local coordinates. Local.
x is aligned with the direction of propagation.
Reimplemented from Airy.
Reimplemented in Stokes5.
Definition at line 92 of file Stokes2.C.
References Foam::cos(), Airy::elevation(), Foam::endl(), Foam::Info, k, Foam::log(), Foam::max(), Foam::min(), Foam::sqr(), Foam::T(), Foam::tanh(), and Stokes2::velocity().
Referenced by Stokes2::clone(), Stokes5::elevation(), and Stokes2::~Stokes2().
|
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.
Reimplemented from Airy.
Reimplemented in Stokes5.
Definition at line 117 of file Stokes2.C.
References Airy::celerity(), Foam::endl(), Foam::Info, k, Foam::log(), Foam::max(), Foam::min(), Foam::pow3(), Foam::sinh(), Foam::sqr(), and Airy::velocity().
Referenced by Stokes2::clone(), Stokes2::elevation(), and Stokes5::velocity().