40 template<
class BasicMomentumTransportModel>
44 epsilon_ =
max(epsilon_, tCmuk2()/(this->nutMaxCoeff_*this->nu()));
49 template<
class BasicMomentumTransportModel>
52 return max(k_/epsilon_, 6.0*
sqrt(this->nu()/epsilon_));
56 template<
class BasicMomentumTransportModel>
61 /epsilon_, Ceta_*
pow025(
pow3(this->nu())/epsilon_));
65 template<
class BasicMomentumTransportModel>
68 this->nut_ =
min(boundEpsilon()/epsilon_, this->Cmu_*v2_*Ts());
69 this->nut_.correctBoundaryConditions();
76 template<
class BasicMomentumTransportModel>
195 this->groupName(
"k"),
196 this->runTime_.
name(),
207 this->groupName(
"epsilon"),
208 this->runTime_.
name(),
219 this->groupName(
"v2"),
220 this->runTime_.
name(),
231 this->groupName(
"f"),
232 this->runTime_.
name(),
247 if (
type == typeName)
249 this->printCoeffs(
type);
256 template<
class BasicMomentumTransportModel>
261 Cmu_.readIfPresent(this->coeffDict());
262 CmuKEps_.readIfPresent(this->coeffDict());
263 C1_.readIfPresent(this->coeffDict());
264 C2_.readIfPresent(this->coeffDict());
265 CL_.readIfPresent(this->coeffDict());
266 Ceta_.readIfPresent(this->coeffDict());
267 Ceps2_.readIfPresent(this->coeffDict());
268 Ceps3_.readIfPresent(this->coeffDict());
269 sigmaK_.readIfPresent(this->coeffDict());
270 sigmaEps_.readIfPresent(this->coeffDict());
281 template<
class BasicMomentumTransportModel>
284 if (!this->turbulence_)
317 1.0/Ts*((C1_ - N)*v2_ - 2.0/3.0*k_*(C1_ - 1.0))
323 1.4*(1.0 + 0.05*
min(
sqrt(k_/v2_), scalar(100.0)))
327 epsilon_.boundaryFieldRef().updateCoeffs();
342 epsEqn.
ref().relax();
344 epsEqn.
ref().boundaryManipulate(epsilon_.boundaryFieldRef());
367 bound(k_, this->kMin_);
376 - 1.0/L2/k_*(v2fAlpha - C2_*
G)
Bound the given scalar field where it is below the specified minimum.
Generic GeometricField class.
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
Templated abstract base class for RAS turbulence models.
Abstract base-class for v2-f models to provide BCs access to the v2 and f fields.
volScalarField k_
Turbulence kinetic energy.
v2f(const alphaField &alpha, const rhoField &rho, const volVectorField &U, const surfaceScalarField &alphaRhoPhi, const surfaceScalarField &phi, const viscosity &viscosity, const word &type=typeName)
Construct from components.
virtual void correct()
Solve the turbulence equations and correct the turbulence viscosity.
tmp< volScalarField > boundEpsilon()
Bound epsilon and return Cmu*sqr(k) for nut.
tmp< volScalarField > Ts() const
Return time scale, Ts.
virtual void correctNut()
Correct the eddy-viscosity nut.
volScalarField f_
Damping function.
tmp< volScalarField > Ls() const
Return length scale, Ls.
virtual bool read()
Read RASProperties dictionary.
volScalarField v2_
Turbulence stress normal to streamlines.
static autoPtr< dictionary > New(Istream &)
Construct top-level dictionary on freestore from Istream.
Generic dimensioned Type class.
Eddy viscosity turbulence model base class.
Finite volume constraints.
bool constrain(fvMatrix< Type > &eqn) const
Apply constraints to an equation.
tmp< fvMatrix< Type > > source(const VolField< Type > &field) const
Return source for an equation.
BasicMomentumTransportModel::alphaField alphaField
BasicMomentumTransportModel::rhoField rhoField
A class for managing temporary objects.
T & ref() const
Return non-const reference or generate a fatal error.
Abstract base class for all fluid physical properties.
A class for handling words, derived from string.
Foam::fvConstraints & fvConstraints(Foam::fvConstraints::New(mesh))
Foam::fvModels & fvModels(Foam::fvModels::New(mesh))
volScalarField alpha(IOobject("alpha", runTime.name(), mesh, IOobject::READ_IF_PRESENT, IOobject::AUTO_WRITE), lambda *max(Ua &U, zeroSensitivity))
void correct(const RdeltaTType &rDeltaT, const RhoType &rho, volScalarField &psi, const surfaceScalarField &phiCorr, const SpType &Sp, const SuType &Su)
const dimensionedScalar G
Newtonian constant of gravitation.
tmp< VolField< typename outerProduct< vector, Type >::type > > grad(const SurfaceField< Type > &ssf)
tmp< VolField< Type > > div(const SurfaceField< Type > &ssf)
tmp< surfaceScalarField > absolute(const tmp< surfaceScalarField > &tphi, const volVectorField &U)
Return the given relative flux in absolute form.
tmp< fvMatrix< Type > > laplacian(const VolField< Type > &vf, const word &name)
tmp< fvMatrix< Type > > div(const surfaceScalarField &flux, const VolField< Type > &vf, const word &name)
tmp< fvMatrix< Type > > Sp(const volScalarField::Internal &, const VolField< Type > &)
tmp< fvMatrix< Type > > SuSp(const volScalarField::Internal &, const VolField< Type > &)
tmp< fvMatrix< Type > > ddt(const VolField< Type > &vf)
dimensionedSymmTensor dev(const dimensionedSymmTensor &dt)
dimensionedSymmTensor symm(const dimensionedSymmTensor &dt)
bool read(const char *, int32_t &)
dimensionedSymmTensor sqr(const dimensionedVector &dv)
const HashTable< dimensionSet > & dimensions()
Get the table of dimension sets.
dimensionedScalar pow3(const dimensionedScalar &ds)
word name(const bool)
Return a word representation of a bool.
const dimensionSet dimless
layerAndWeight min(const layerAndWeight &a, const layerAndWeight &b)
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
dimensionedScalar sqrt(const dimensionedScalar &ds)
word typedName(Name name)
Return the name of the object within the given type.
layerAndWeight max(const layerAndWeight &a, const layerAndWeight &b)
bool bound(volScalarField &, const dimensionedScalar &min)
Bound the given scalar field where it is below the specified min value.
dimensioned< scalar > magSqr(const dimensioned< Type > &)
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
SolverPerformance< Type > solve(fvMatrix< Type > &, const word &)
Solve returning the solution statistics given convergence tolerance.
dimensionedScalar pow025(const dimensionedScalar &ds)