50Foam::vector Foam::fv::atmCoriolisUSource::planetaryRotationVector()
const
65 const word& sourceName,
66 const word& modelType,
74 coeffs_.getCheckOrDefault<scalar>
78 [&](const scalar
x){
return (90 >=
mag(
x)) && (
mag(
x) >= 0); }
81 planetaryRotationPeriod_
83 coeffs_.getCheckOrDefault<scalar>
85 "planetaryRotationPeriod",
87 [&](
const scalar
x){ return x > SMALL; }
95 coeffs_.getOrDefault<
vector>
98 planetaryRotationVector()
103 if (
mag(Omega_.value()) < SMALL)
106 <<
"The magnitude of the rotation vector in atmCoriolisUSource is "
107 <<
"effectively zero, mag(Omega) = " <<
mag(Omega_.value()) <<
nl
108 <<
"Please check input values in atmCoriolisUSource settings."
112 fieldNames_.resize(1,
"U");
116 Log <<
" Applying atmCoriolisUSource to: " << fieldNames_[0] <<
endl;
132 eqn -= (2.0*Omega_)^
U;
148 eqn -=
rho*((2.0*Omega_)^
U);
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
A special matrix type and solver, designed for finite volume solutions of scalar equations....
const GeometricField< Type, fvPatchField, volMesh > & psi(const label i=0) const
Return psi.
Mesh data needed to do the Finite Volume discretisation.
Applies corrections to incorporate the horizontal and vertical components of the Coriolis force for w...
virtual void addSup(fvMatrix< vector > &eqn, const label fieldi)
Add explicit contribution to incompressible momentum equation.
Intermediate abstract class for handling cell-set options for the derived fvOptions.
Base abstract class for handling finite volume options (i.e. fvOption).
void resetApplied()
Resize/reset applied flag list for all fieldNames_ entries.
A class for handling words, derived from Foam::string.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
A special matrix type and solver, designed for finite volume solutions of scalar equations.
#define WarningInFunction
Report a warning using Foam::Warning.
constexpr scalar twoPi(2 *M_PI)
const dimensionSet dimless
Dimensionless.
const dimensionSet dimTime(0, 0, 1, 0, 0, 0, 0)
dimensionedScalar sin(const dimensionedScalar &ds)
Ostream & endl(Ostream &os)
Add newline and flush stream.
constexpr scalar degToRad() noexcept
Multiplication factor for degrees to radians conversion.
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
static constexpr const zero Zero
Global zero (0)
dimensionedScalar cos(const dimensionedScalar &ds)
constexpr char nl
The newline '\n' character (0x0a)
Unit conversion functions.