Go to the documentation of this file.
38 namespace functionObjects
57 { compressibleField::cfK,
"k" },
58 { compressibleField::cfEpsilon,
"epsilon" },
59 { compressibleField::cfOmega,
"omega" },
60 { compressibleField::cfNuTilda,
"nuTilda" },
61 { compressibleField::cfMut,
"mut" },
62 { compressibleField::cfMuEff,
"muEff" },
63 { compressibleField::cfAlphat,
"alphat" },
64 { compressibleField::cfAlphaEff,
"alphaEff" },
65 { compressibleField::cfR,
"R" },
66 { compressibleField::cfDevRhoReff,
"devRhoReff" },
67 { compressibleField::cfL,
"L" },
68 { compressibleField::cfI,
"I" },
78 { incompressibleField::ifK,
"k" },
79 { incompressibleField::ifEpsilon,
"epsilon" },
80 { incompressibleField::ifOmega,
"omega" },
81 { incompressibleField::ifNuTilda,
"nuTilda" },
82 { incompressibleField::ifNut,
"nut" },
83 { incompressibleField::ifNuEff,
"nuEff" },
84 { incompressibleField::ifR,
"R" },
85 { incompressibleField::ifDevReff,
"devReff" },
86 { incompressibleField::ifL,
"L" },
87 { incompressibleField::ifI,
"I" },
111 <<
"Turbulence model not found in database, deactivating"
120 Foam::functionObjects::turbulenceFields::turbulenceFields
146 if (
dict.found(
"field"))
148 fieldSet_.insert(
dict.get<
word>(
"field"));
156 if (fieldSet_.size())
158 Info<<
"storing fields:" <<
nl;
159 for (
const word&
f : fieldSet_)
161 Info<<
" " << modelName <<
':' <<
f <<
nl;
167 Info<<
"no fields requested to be stored" <<
nl <<
endl;
183 for (
const word&
f : fieldSet_)
185 switch (compressibleFieldNames_[
f])
189 processField<scalar>(
f, model.k());
194 processField<scalar>(
f, model.epsilon());
199 processField<scalar>(
f, omega(model));
204 processField<scalar>(
f, nuTilda(model));
209 processField<scalar>(
f, model.mut());
214 processField<scalar>(
f, model.muEff());
219 processField<scalar>(
f, model.
alphat());
224 processField<scalar>(
f, model.
alphaEff());
229 processField<symmTensor>(
f, model.R());
234 processField<symmTensor>(
f, model.devRhoReff());
239 processField<scalar>(
f,
L(model));
244 processField<scalar>(
f,
I(model));
260 for (
const word&
f : fieldSet_)
262 switch (incompressibleFieldNames_[
f])
266 processField<scalar>(
f, model.
k());
271 processField<scalar>(
f, model.
epsilon());
276 processField<scalar>(
f, omega(model));
281 processField<scalar>(
f, nuTilda(model));
286 processField<scalar>(
f, model.
nut());
291 processField<scalar>(
f, model.
nuEff());
296 processField<symmTensor>(
f, model.
R());
301 processField<symmTensor>(
f, model.
devReff());
306 processField<scalar>(
f,
L(model));
311 processField<scalar>(
f,
I(model));
329 for (
const word&
f : fieldSet_)
331 const word fieldName = modelName +
':' +
f;
332 writeObject(fieldName);
virtual tmp< volSymmTensorField > R() const =0
Return the Reynolds stress tensor.
const vector L(dict.get< vector >("L"))
const objectRegistry & obr_
Reference to the region objectRegistry.
Enum is a wrapper around a list of names/values that represent particular enumeration (or int) values...
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
A class for handling words, derived from Foam::string.
static const Enum< incompressibleField > incompressibleFieldNames_
static const word modelName
virtual tmp< volScalarField > nut() const =0
Return the turbulence viscosity.
bool read(const char *buf, int32_t &val)
Same as readInt32.
static const word propertiesName
Default name of the turbulence properties dictionary.
Ostream & endl(Ostream &os)
Add newline and flush stream.
Specialization of Foam::functionObject for an Foam::fvMesh, providing a reference to the Foam::fvMesh...
addToRunTimeSelectionTable(functionObject, add, dictionary)
bool foundObject(const word &name, const bool recursive=false) const
Is the named Type found?
virtual tmp< volSymmTensorField > devReff() const
Return the effective stress tensor.
virtual bool write()
Do nothing.
messageStream Info
Information stream (uses stdout - output is on the master only)
word name(const complex &c)
Return string representation of complex.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
virtual bool read(const dictionary &dict)
Read optional controls.
Macros for easy insertion into run-time selection tables.
virtual tmp< volScalarField > k() const =0
Return the turbulence kinetic energy.
errorManip< error > abort(error &err)
virtual bool read(const dictionary &)
Read the controls.
errorManipArg< error, int > exit(error &err, const int errNo=1)
defineTypeNameAndDebug(fvMeshFunctionObject, 0)
static const Enum< compressibleField > compressibleFieldNames_
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
virtual tmp< volScalarField > alphaEff() const
Return the effective turbulent thermal diffusivity for enthalpy.
Templated wrapper class to provide compressible turbulence models thermal diffusivity based thermal t...
virtual tmp< volScalarField > alphat() const
Return the turbulent thermal diffusivity for enthalpy [kg/m/s].
fileName::Type type(const fileName &name, const bool followLink=true)
Return the file type: DIRECTORY or FILE, normally following symbolic links.
Templated abstract base class for single-phase incompressible turbulence models.
bool compressible()
Return true if compressible turbulence model is identified.
virtual bool execute()
Calculate turbulence fields.
virtual tmp< volScalarField > nuEff() const =0
Return the effective viscosity.
virtual tmp< volScalarField > epsilon() const =0
Return the turbulence kinetic energy dissipation rate.
virtual ~turbulenceFields()
Destructor.
static const Identity< scalar > I