33 template<
class BasicTurbulenceModel>
38 Info<< coeffDict_.dictName() << coeffDict_ <<
endl;
45 template<
class BasicTurbulenceModel>
49 const alphaField&
alpha,
55 const word& propertiesName
69 RASDict_(this->subOrEmptyDict(
"RAS")),
70 turbulence_(RASDict_.getOrDefault<
Switch>(
"turbulence", true)),
71 printCoeffs_(RASDict_.getOrDefault<
Switch>(
"printCoeffs", false)),
72 coeffDict_(RASDict_.optionalSubDict(
type +
"Coeffs")),
106 this->mesh_.deltaCoeffs();
112 template<
class BasicTurbulenceModel>
122 const word& propertiesName
129 IOobject::groupName(propertiesName, alphaRhoPhi.
group()),
134 IOobject::NO_REGISTER
143 dict.getCompat<
word>(
"model", {{
"RASModel", -2006}})
146 Info<<
"Selecting RAS turbulence model " << modelType <<
endl;
148 auto* ctorPtr = dictionaryConstructorTable(modelType);
157 *dictionaryConstructorTablePtr_
161 return autoPtr<RASModel>
163 ctorPtr(
alpha,
rho,
U, alphaRhoPhi,
phi, transport, propertiesName)
170 template<
class BasicTurbulenceModel>
175 RASDict_ <<= this->subDict(
"RAS");
176 RASDict_.readEntry(
"turbulence", turbulence_);
178 coeffDict_ <<= RASDict_.optionalSubDict(
type() +
"Coeffs");
180 kMin_.readIfPresent(RASDict_);
181 epsilonMin_.readIfPresent(RASDict_);
182 omegaMin_.readIfPresent(RASDict_);
190 template<
class BasicTurbulenceModel>
194 const scalar Cmu = 0.09;
200 IOobject::groupName(
"epsilon", this->alphaRhoPhi_.group()),
201 this->mesh_.time().timeName(),
204 Cmu*this->
k()*this->omega()
209 template<
class BasicTurbulenceModel>
213 const scalar betaStar = 0.09;
220 IOobject::groupName(
"omega", this->alphaRhoPhi_.group()),
221 this->mesh_.time().timeName(),
224 this->
epsilon()/(betaStar*(this->
k() + k0))
229 template<
class BasicTurbulenceModel>
static word group(const word &name)
Return group (extension part of name)
errorManipArg< error, int > exit(error &err, const int errNo=1)
A list of keyword definitions, which are a keyword followed by a number of values (eg...
dimensionedSymmTensor sqr(const dimensionedVector &dv)
Ostream & endl(Ostream &os)
Add newline and flush stream.
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh >> &tf1, const word &name, const dimensionSet &dimensions, const bool initCopy=false)
Global function forwards to reuseTmpDimensionedField::New.
A simple wrapper around bool so that it can be read as a word: true/false, on/off, yes/no, any/none. Also accepts 0/1 as a string and shortcuts t/f, y/n.
label k
Boltzmann constant.
Generic dimensioned Type class.
const dimensionSet dimless
Dimensionless.
virtual bool read()
Read model coefficients if they have changed.
const dictionary & subDict(const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const
Find and return a sub-dictionary.
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
virtual tmp< volScalarField > epsilon() const
Return the turbulence kinetic energy dissipation rate.
virtual tmp< volScalarField > omega() const
Return the specific dissipation rate.
A class for handling words, derived from Foam::string.
virtual void printCoeffs(const word &type)
Print model coefficients.
Info<< "Predicted p max-min : "<< max(p).value()<< " "<< min(p).value()<< endl;rho==max(psi *p+alphal *rhol0+((alphav *psiv+alphal *psil) - psi) *pSat, rhoMin);# 1 "/home/chef2/andy/OpenFOAM/release/v2306/OpenFOAM-v2306/applications/solvers/multiphase/cavitatingFoam/alphavPsi.H" 1{ alphav=clamp((rho - rholSat)/(rhovSat - rholSat), zero_one{});alphal=1.0 - alphav;Info<< "max-min alphav: "<< max(alphav).value()<< " "<< min(alphav).value()<< endl;psiModel-> correct()
static autoPtr< RASModel > New(const alphaField &alpha, const rhoField &rho, const volVectorField &U, const surfaceScalarField &alphaRhoPhi, const surfaceScalarField &phi, const transportModel &transport, const word &propertiesName=turbulenceModel::propertiesName)
Return a reference to the selected RAS model.
const dimensionSet dimLength(0, 1, 0, 0, 0, 0, 0)
Base-class for all transport models used by the incompressible turbulence models. ...
const dimensionSet dimTime(0, 0, 1, 0, 0, 0, 0)
messageStream Info
Information stream (stdout output on master, null elsewhere)
TransportModel transportModel
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
A class for managing temporary objects.
const dimensionedScalar alpha
Fine-structure constant: default SI units: [].
Defines the attributes of an object for which implicit objectRegistry management is supported...
#define FatalIOErrorInLookup(ios, lookupTag, lookupName, lookupTable)
Report an error message using Foam::FatalIOError.
virtual void correct()
Solve the turbulence equations and correct the turbulence viscosity.
IOerror FatalIOError
Error stream (stdout output on all processes), with additional 'FOAM FATAL IO ERROR' header text and ...
const dimensionSet dimVelocity
RASModel(const RASModel &)=delete
No copy construct.