Go to the documentation of this file.
32 template<
class CloudType>
37 { resetMode::timeStep,
"timeStep" },
38 { resetMode::writeTime,
"writeTime" },
43 template<
class CloudType>
47 const word& fieldName,
53 fieldPtr->primitiveFieldRef() = 0.0;
65 this->owner().
name() +
":" + this->modelName() +
":" + fieldName,
66 mesh.time().timeName(),
68 IOobject::READ_IF_PRESENT,
79 template<
class CloudType>
82 clearOrReset(massPtr_,
"mass",
dimMass);
83 clearOrReset(countPtr_,
"count",
dimless);
87 template<
class CloudType>
110 if (resetMode_ == resetMode::writeTime)
119 template<
class CloudType>
124 const word& modelName
132 resetModeNames_.getOrDefault
144 template<
class CloudType>
153 resetMode_(pii.resetMode_)
159 template<
class CloudType>
162 const typename parcelType::trackingData&
165 if (resetMode_ == resetMode::timeStep)
172 template<
class CloudType>
180 const label patchi = pp.
index();
183 massPtr_->boundaryFieldRef()[patchi][facei] +=
p.nParticle()*
p.mass();
184 countPtr_->boundaryFieldRef()[patchi][facei] += 1;
Defines the attributes of an object for which implicit objectRegistry management is supported,...
PatchInteractionFields(const dictionary &dict, CloudType &owner, const word &modelName)
Construct from dictionary.
Enum is a wrapper around a list of names/values that represent particular enumeration (or int) values...
A class for handling words, derived from Foam::string.
static constexpr const zero Zero
Global zero (0)
Dimension set for the base types, which can be used to implement rigorous dimension checking for alge...
Creates volume fields whose boundaries are used to store patch interaction statistics.
virtual void preEvolve(const typename parcelType::trackingData &td)
Pre-evolve hook.
static const Enum< resetMode > resetModeNames_
virtual void postPatch(const parcelType &p, const polyPatch &pp, bool &keepParticle)
Post-patch hook.
void reset()
Create|read|reset the fields.
const fvMesh & mesh() const
Return reference to the mesh.
A patch is a list of labels that address the faces in the global face list.
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
Templated base class for dsmc cloud.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Mesh data needed to do the Finite Volume discretisation.
const dimensionSet dimMass(1, 0, 0, 0, 0, 0, 0)
label index() const noexcept
The index of this patch in the boundaryMesh.
void clearOrReset(autoPtr< volScalarField > &fieldPtr, const word &fieldName, const dimensionSet &dims) const
Helper function to clear or reset fields.
errorManip< error > abort(error &err)
bool none(const UList< bool > &bools)
True if no entries are 'true'.
meshPtr reset(new Foam::fvMesh(Foam::IOobject(regionName, runTime.timeName(), runTime, Foam::IOobject::MUST_READ), false))
void reset(autoPtr< T > &&other) noexcept
Delete managed object and set to new given pointer.
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
label whichFace(const label l) const
Return label of face in patch from global face label.
Templated cloud function object base class.
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
virtual void write()
Write post-processing info.
const dimensionSet dimless
Dimensionless.