33 template<
class CloudType>
46 template<
class CloudType>
53 gradkPtr_(dm.gradkPtr_),
54 ownGradK_(dm.ownGradK_)
62 template<
class CloudType>
71 template<
class CloudType>
78 gradkPtr_ =
fvc::grad(*this->kPtr_).ptr();
93 template<
class CloudType>
106 const scalar cps = 0.16432;
108 const scalar
k = this->kPtr_->primitiveField()[celli];
110 this->epsilonPtr_->primitiveField()[celli] + rootVSmall;
111 const vector& gradk = this->gradkPtr_->primitiveField()[celli];
113 const scalar UrelMag =
mag(
U - Uc - UTurb);
115 const scalar tTurbLoc =
124 if (tTurb > tTurbLoc)
129 const vector dir = -gradk/(
mag(gradk) + small);
137 if (this->owner().mesh().nSolutionD() == 2)
146 UTurb =
sigma*fac*dir;
Templated base class for dsmc cloud.
Base class for particle dispersion models based on RAS turbulence.
virtual void cacheFields(const bool store)
Cache carrier fields.
The velocity is perturbed in the direction of -grad(k), with a Gaussian random number distribution wi...
virtual ~GradientDispersionRAS()
Destructor.
virtual void cacheFields(const bool store)
Cache carrier fields.
GradientDispersionRAS(const dictionary &dict, CloudType &owner)
Construct from components.
virtual vector update(const scalar dt, const label celli, const vector &U, const vector &Uc, vector &UTurb, scalar &tTurb)
Update (disperse particles)
bool ownGradK_
Take ownership of the grad(k)
A list of keyword definitions, which are a keyword followed by any number of values (e....
Standard normal distribution. Not selectable.
virtual scalar sample() const
Sample the distribution.
Template functions to aid in the implementation of demand driven data.
Calculate the gradient of the given field.
const dimensionedScalar sigma
Stefan-Boltzmann constant: default SI units: [W/m^2/K^4].
tmp< VolField< typename outerProduct< vector, Type >::type > > grad(const SurfaceField< Type > &ssf)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
void deleteDemandDrivenData(DataType *&dataPtr)
layerAndWeight min(const layerAndWeight &a, const layerAndWeight &b)
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
dimensionedScalar sqrt(const dimensionedScalar &ds)
dimensioned< scalar > mag(const dimensioned< Type > &)