First-order wave model. More...
Public Member Functions | |
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 autoPtr< waveModel > | clone () const |
Construct a clone. 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 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... | |
Protected Member Functions | |
scalar | k () const |
The angular wavenumber [rad/m]. More... | |
bool | deep () const |
Return whether shallow and intermediate effects are to be omitted. More... | |
virtual scalar | celerity () const |
The wave celerity [m/s]. 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 | 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... | |
First-order wave model.
Stokes, G.G. (1847) On the theory of oscillatory waves. Transactions of the Cambridge Philosophical Society, 8, 441.
See the leading terms of equations 18 and 19.
Construct a copy.
Definition at line 158 of file Airy.C.
Referenced by Airy::celerity(), and Airy::clone().
Airy | ( | const dictionary & | dict, |
const scalar | g, | ||
const word & | modelName = Airy::typeName , |
||
scalar(*)(scalar, scalar, scalar, scalar) | modelCelerity = &Airy::celerity |
||
) |
Construct from a dictionary and gravity.
Definition at line 169 of file Airy.C.
References Airy::amplitude(), Foam::constant::universal::c, Airy::depth(), Foam::endl(), Foam::Info, and Airy::length().
|
virtual |
Destructor.
Definition at line 192 of file Airy.C.
References Airy::elevation().
Referenced by Airy::clone().
|
staticprotected |
The angular wavenumber [rad/m].
Definition at line 91 of file Airy.C.
References Foam::constant::mathematical::pi().
|
staticprotected |
Return whether shallow and intermediate effects are to be omitted.
Definition at line 97 of file Airy.C.
References Airy::celerity(), k, and Foam::log().
|
staticprotected |
The wave celerity [m/s].
Definition at line 104 of file Airy.C.
References Airy::angle(), k, Foam::sqrt(), and Foam::tanh().
|
inlineprotected |
The angular wavenumber [rad/m].
Definition at line 118 of file Airy.H.
Referenced by Airy::velocity().
|
inlineprotected |
Return whether shallow and intermediate effects are to be omitted.
Definition at line 124 of file Airy.H.
References Airy::depth(), and Airy::length().
Referenced by Airy::write().
|
inlineprotectedvirtual |
The wave celerity [m/s].
Reimplemented in Stokes2, and Stokes5.
Definition at line 130 of file Airy.H.
References Airy::Airy(), Airy::amplitude(), Airy::angle(), Airy::depth(), waveModel::g(), Airy::length(), Airy::TypeName(), Airy::vi(), Foam::fvPatchDistWave::wave(), and x.
Referenced by Stokes5::celerity(), Stokes2::celerity(), Airy::deep(), Stokes5::velocity(), Stokes2::velocity(), and Airy::velocity().
|
protected |
Angle of the oscillation [rad].
Definition at line 118 of file Airy.C.
References k, and Airy::vi().
Referenced by Airy::celerity(), and Airy::elevation().
|
protected |
Return the non-dimensionalised i-th harmonic of the velocity.
Definition at line 128 of file Airy.C.
References Field< Type >::component(), Foam::cos(), Foam::cosh(), Foam::exp(), k, Foam::log(), Foam::max(), Foam::min(), phi, Foam::sin(), Foam::sinh(), x, and Foam::zip().
Referenced by Airy::angle(), Airy::celerity(), and Airy::velocity().
TypeName | ( | "Airy" | ) |
Runtime type information.
Referenced by Airy::celerity().
Construct a clone.
Implements waveModel.
Reimplemented in Stokes2, and Stokes5.
Definition at line 173 of file Airy.H.
References Airy::Airy(), and Airy::~Airy().
|
inline |
Get the depth.
Definition at line 188 of file Airy.H.
Referenced by Airy::Airy(), Stokes5::celerity(), Stokes2::celerity(), Airy::celerity(), and Airy::deep().
|
inline |
|
inline |
Get the amplitude at steady state.
Definition at line 200 of file Airy.H.
Referenced by Airy::Airy(), Stokes5::celerity(), Stokes2::celerity(), Airy::celerity(), Airy::elevation(), and Airy::velocity().
|
inline |
Get the length.
Definition at line 206 of file Airy.H.
Referenced by Airy::Airy(), Stokes5::celerity(), Stokes2::celerity(), Airy::celerity(), and Airy::deep().
|
inline |
Get the phase.
Definition at line 212 of file Airy.H.
References Airy::elevation(), Airy::velocity(), and Airy::write().
|
virtual |
Get the wave elevation at a given time and local coordinates. Local.
x is aligned with the direction of propagation.
Implements waveModel.
Reimplemented in Stokes2, and Stokes5.
Definition at line 199 of file Airy.C.
References Airy::amplitude(), Airy::angle(), Foam::cos(), and Airy::velocity().
Referenced by Stokes2::elevation(), Airy::phase(), and Airy::~Airy().
|
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.
Reimplemented in Stokes2, and Stokes5.
Definition at line 209 of file Airy.C.
References Airy::amplitude(), Airy::celerity(), Airy::k(), and Airy::vi().
Referenced by Airy::elevation(), Airy::phase(), and Stokes2::velocity().
|
virtual |
Write.
Reimplemented from waveModel.
Definition at line 220 of file Airy.C.
References Airy::deep(), waveModel::write(), and Foam::writeEntry().
Referenced by Airy::phase().