34 template<
class CloudType>
43 this->owner().
name() +
":collisionDensity",
58 this->owner().
name() +
":collisionDensityRate",
65 (collisionDensity_ - collisionDensity0_)
66 /(this->owner().
mesh().time().value() - time0_)
70 collisionDensity0_ == collisionDensity_;
71 time0_ = this->owner().mesh().time().value();
77 template<
class CloudType>
86 minSpeed_(dict.lookupOrDefault<scalar>(
"minSpeed", -1)),
89 this->owner().mesh().boundary(),
90 volScalarField::Internal::null(),
95 this->owner().mesh().boundary(),
96 volScalarField::Internal::null(),
99 time0_(this->owner().mesh().time().value())
101 collisionDensity_ == 0;
102 collisionDensity0_ == 0;
106 this->owner().
name() +
":collisionDensity",
108 this->owner().
mesh(),
122 template<
class CloudType>
129 minSpeed_(ppm.minSpeed_),
130 collisionDensity_(ppm.collisionDensity_),
131 collisionDensity0_(ppm.collisionDensity0_),
138 template<
class CloudType>
145 template<
class CloudType>
154 const label patchFacei = p.face() - pp.
start();
157 this->owner().patchData(p, pp, nw, Up);
159 const scalar speed = (p.U() - Up) & nw;
160 if (speed > minSpeed_)
162 collisionDensity_[
patchi][patchFacei] +=
163 1/this->owner().mesh().magSf().boundaryField()[
patchi][patchFacei];
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
bool typeHeaderOk(const bool checkType=true)
Read header (uses typeFilePath to find file) and check header.
A list of keyword definitions, which are a keyword followed by any number of values (e...
const Boundary & boundaryField() const
Return const-reference to the boundary field.
Operations on lists of strings.
void write()
Write post-processing info.
Various functions to operate on Lists.
virtual ~PatchCollisionDensity()
Destructor.
GeometricField< scalar, fvPatchField, volMesh > volScalarField
A class for handling words, derived from string.
This boundary condition is not designed to be evaluated; it is assmued that the value is assigned via...
virtual void postPatch(const parcelType &p, const polyPatch &pp, bool &keepParticle)
Post-patch hook.
word name(const complex &)
Return a string representation of a complex.
const dimensionSet dimless(0, 0, 0, 0, 0, 0, 0)
Function object which generates fields of the number and rate of collisions per unit area on all patc...
label index() const
Return the index of this patch in the boundaryMesh.
label start() const
Return start label of this patch in the polyMesh face list.
const dimensionSet dimTime(0, 0, 1, 0, 0, 0, 0)
PatchCollisionDensity(const dictionary &dict, CloudType &owner, const word &modelName)
Construct from dictionary.
A patch is a list of labels that address the faces in the global face list.
virtual bool write(const bool valid=true) const
Write using setting from DB.
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
Templated base class for dsmc cloud.
Templated cloud function object base class.
const dimensionSet dimArea(sqr(dimLength))