Go to the documentation of this file.
54 Foam::scalar Foam::waveModels::StokesI::eta
66 scalar phaseTot = Kx*
x + Ky*
y - omega*t + phase;
68 return H*0.5*
cos(phaseTot);
83 for (
int i=1; i<=100; i++)
106 scalar
k =
sqrt(Kx*Kx + Ky*Ky);
107 scalar phaseTot = Kx*
x + Ky*
y - omega*t +
phase;
111 scalar v = u*
sin(waveAngle_);
112 u *=
cos(waveAngle_);
127 const scalar waveKx = waveK*
cos(waveAngle_);
128 const scalar waveKy = waveK*
sin(waveAngle_);
145 level[paddlei] = waterDepthRef_ + tCoeff*eta;
159 const scalar waveKx = waveK*
cos(waveAngle_);
160 const scalar waveKy = waveK*
sin(waveAngle_);
170 setPaddlePropeties(level, facei, fraction, z);
174 const label paddlei = faceToPaddle_[facei];
190 U_[facei] = fraction*
Uf*tCoeff;
219 if (regularWaveModel::readDict(overrideDict))
221 waveLength_ = waveLength(waterDepthRef_, wavePeriod_);
232 regularWaveModel::info(
os);
234 os <<
" Wave type: " << waveType() <<
nl;
addToRunTimeSelectionTable(decompositionMethod, kahipDecomp, dictionary)
const vector L(dict.get< vector >("L"))
dimensionedScalar cosh(const dimensionedScalar &ds)
Single incompressible phase derived from the phase-fraction. Used as part of the multiPhaseMixture fo...
Different types of constants.
virtual void setLevel(const scalar t, const scalar tCoeff, scalarField &level) const
Set the water level.
dimensionedScalar sin(const dimensionedScalar &ds)
volScalarField H(IOobject("H", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::AUTO_WRITE), mesh, dimensionedScalar(dimLength, Zero))
autoPtr< surfaceVectorField > Uf
InfoProxy< IOobject > info() const
Return info proxy.
#define forAll(list, i)
Loop across all elements in list.
virtual vector UfBase(const scalar H, const scalar h, const scalar Kx, const scalar x, const scalar Ky, const scalar y, const scalar omega, const scalar t, const scalar phase, const scalar z) const
Wave velocity.
dimensionedScalar tanh(const dimensionedScalar &ds)
const dimensionedScalar h
Planck constant.
A patch is a list of labels that address the faces in the global face list.
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
constexpr scalar twoPi(2 *M_PI)
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
OBJstream os(runTime.globalPath()/outputName)
Macros for easy insertion into run-time selection tables.
Mesh data needed to do the Finite Volume discretisation.
Vector< scalar > vector
A scalar version of the templated Vector.
virtual scalar waveLength(const scalar h, const scalar T) const
Return the wavelength.
void readFields(const typename GeoFieldType::Mesh &mesh, const IOobjectList &objects, const wordHashSet &selectedFields, LIFOStack< regIOobject * > &storedObjects)
Read the selected GeometricFields of the templated type.
virtual void setVelocity(const scalar t, const scalar tCoeff, const scalarField &level)
Calculate the wave model velocity.
constexpr scalar pi(M_PI)
const std::string patch
OpenFOAM patch number as a std::string.
virtual bool readDict(const dictionary &overrideDict)
Read from dictionary.
dimensionedScalar sqrt(const dimensionedScalar &ds)
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
label k
Boltzmann constant.
StokesI(const dictionary &dict, const fvMesh &mesh, const polyPatch &patch, const bool readFields=true)
Constructor.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
defineTypeNameAndDebug(combustionModel, 0)
dimensionedScalar cos(const dimensionedScalar &ds)
dimensionedScalar sinh(const dimensionedScalar &ds)