34 template<
class CloudType>
42 turbulenceModel::propertiesName,
54 <<
"Turbulence model not found in mesh database" <<
nl 55 <<
"Database objects include: " << obr.
sortedToc()
62 template<
class CloudType>
70 turbulenceModel::propertiesName,
78 return turb->epsilon();
82 <<
"Turbulence model not found in mesh database" <<
nl 83 <<
"Database objects include: " << obr.
sortedToc()
92 template<
class CloudType>
102 epsilonPtr_(nullptr),
107 template<
class CloudType>
116 epsilonPtr_(dm.epsilonPtr_),
117 ownEpsilon_(dm.ownEpsilon_)
126 template<
class CloudType>
135 template<
class CloudType>
152 tmp<volScalarField> tepsilon = this->epsilonModel();
153 if (tepsilon.isTmp())
155 epsilonPtr_ = tepsilon.ptr();
160 epsilonPtr_ = &tepsilon();
171 if (ownEpsilon_ && epsilonPtr_)
180 template<
class CloudType>
bool isTmp() const noexcept
Identical to is_pointer()
tmp< volScalarField > kModel() const
Return the k field from the turbulence model.
bool ownEpsilon_
Take ownership of the epsilon field.
error FatalError
Error stream (stdout output on all processes), with additional 'FOAM FATAL ERROR' header text and sta...
A list of keyword definitions, which are a keyword followed by a number of values (eg...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
constexpr char nl
The newline '\n' character (0x0a)
compressible::turbulenceModel & turb
Ostream & writeEntry(const keyType &key, const T &value)
Write a keyword/value entry.
const Type * findObject(const word &name, const bool recursive=false) const
Return const pointer to the object of the given Type.
virtual void write(Ostream &os) const
Write to os.
virtual ~DispersionRASModel()
Destructor.
bool ownK_
Take ownership of the k field.
Abstract base class for turbulence models (RAS, LES and laminar).
constexpr const char *const group
Group name for atomic constants.
virtual void cacheFields(const bool store)
Cache carrier fields.
DispersionRASModel(const dictionary &dict, CloudType &owner)
Construct from components.
A class for handling words, derived from Foam::string.
virtual void write(Ostream &os) const
Write.
errorManip< error > abort(error &err)
OBJstream os(runTime.globalPath()/outputName)
const fvMesh & mesh() const
Return reference to the mesh.
Template functions to aid in the implementation of demand driven data.
tmp< volScalarField > epsilonModel() const
Return the epsilon field from the turbulence model.
List< Key > sortedToc() const
The table of contents (the keys) in sorted order.
Base class for dispersion modelling.
T * ptr() const
Return managed pointer for reuse, or clone() the object reference.
A class for managing temporary objects.
Registry of regIOobjects.
Base class for particle dispersion models based on RAS turbulence.
void deleteDemandDrivenData(DataPtr &dataPtr)
Templated base class for dsmc cloud.