38 namespace compressible
57 const word& sourceName,
58 const word& modelType,
64 phaseName_(
dict.lookupOrDefault(
"phase",
word::null)),
78 betaStar_(
"betaStar",
dimless, 0),
86 fieldName_ = epsilonName;
91 fieldName_ = omegaName;
112 <<
"Cannot find either " << epsilonName <<
" or " << omegaName
131 const word& fieldName
141 mixture_.alpha1()()*mixture_.rho1()()*
sqr(mixture_.thermo1().nu()()())
142 + mixture_.alpha2()()*mixture_.rho2()()*
sqr(mixture_.thermo2().nu()()())
145 if (fieldName ==
"epsilon")
147 eqn += mixture_.interfaceFraction()
148 *C2_*aRhoSqrnu*momentumTransport_.k()()/
pow4(delta_);
150 else if (fieldName ==
"omega")
152 eqn += mixture_.interfaceFraction()
153 *beta_*aRhoSqrnu/(
sqr(betaStar_)*
pow4(delta_));
158 <<
"Support for field " << fieldName <<
" is not implemented"
169 const word& fieldName
179 if (mixture_.alpha1().name() ==
alpha.name())
181 taRhoSqrnu = mixture_.alpha1()()*mixture_.rho1()()
182 *
sqr(mixture_.thermo1().nu()()());
184 else if (mixture_.alpha2().name() ==
alpha.name())
186 taRhoSqrnu = mixture_.alpha2()()*mixture_.rho2()()
187 *
sqr(mixture_.thermo2().nu()()());
192 <<
"Unknown phase-fraction " <<
alpha.name()
198 eqn += mixture_.interfaceFraction()
199 *C2_*taRhoSqrnu*momentumTransport_.k()()/
pow4(delta_);
203 eqn += mixture_.interfaceFraction()
204 *beta_*taRhoSqrnu/(
sqr(betaStar_)*
pow4(delta_));
209 <<
"Support for field " << fieldName <<
" is not implemented"
Macros for easy insertion into run-time selection tables.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
Generic GeometricField class.
static word groupName(Name name, const word &group)
Base class for single-phase compressible turbulence models.
Class to represent a mixture of two rhoThermo-based phases.
A list of keyword definitions, which are a keyword followed by any number of values (e....
bool found(const word &, bool recursive=false, bool patternMatch=true) const
Search dictionary for given keyword.
void read(const dictionary &)
Update the value of dimensioned<Type>
A special matrix type and solver, designed for finite volume solutions of scalar equations....
Mesh data needed to do the Finite Volume discretisation.
Finite volume model abstract base class.
const fvMesh & mesh() const
Return const access to the mesh database.
Free-surface momentumTransport damping function.
virtual bool movePoints()
Update for mesh motion.
virtual wordList addSupFields() const
Return the list of fields for which the option adds source term.
virtual void addSup(const volScalarField &rho, fvMatrix< scalar > &eqn, const word &fieldName) const
Add explicit contribution to epsilon or omega equation.
VoFTurbulenceDamping(const word &sourceName, const word &modelType, const fvMesh &mesh, const dictionary &dict)
Construct from explicit source name and mesh.
virtual void topoChange(const polyTopoChangeMap &)
Update topology using the given map.
virtual void distribute(const polyDistributionMap &)
Redistribute or update using the given distribution map.
virtual void mapMesh(const polyMeshMap &)
Update from another mesh using the given map.
virtual const dictionary & coeffDict() const =0
Const access to the coefficients dictionary.
bool foundObject(const word &name) const
Is the named Type in registry.
Class containing mesh-to-mesh mapping information after a mesh distribution where we send parts of me...
Class containing mesh-to-mesh mapping information.
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
A class for managing temporary objects.
A class for handling words, derived from string.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
volScalarField alpha(IOobject("alpha", runTime.name(), mesh, IOobject::READ_IF_PRESENT, IOobject::AUTO_WRITE), lambda *max(Ua &U, zeroSensitivity))
defineTypeNameAndDebug(VoFCavitation, 0)
addToRunTimeSelectionTable(fvModel, VoFCavitation, dictionary)
errorManipArg< error, int > exit(error &err, const int errNo=1)
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
List< word > wordList
A List of words.
dimensionedSymmTensor sqr(const dimensionedVector &dv)
Ostream & endl(Ostream &os)
Add newline and flush stream.
const dimensionSet dimless
const dimensionSet dimLength
dimensionedScalar pow4(const dimensionedScalar &ds)
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.