37 template<
class CloudType>
41 const objectRegistry& obr = this->owner().
mesh();
53 <<
"Turbulence model not found in mesh database" <<
nl
54 <<
"Database objects include: " << obr.sortedToc()
57 return tmp<volScalarField>(
nullptr);
64 template<
class CloudType>
73 lambda_(this->coeffs().template lookup<scalar>(
"lambda")),
74 turbulence_(
readBool(this->coeffs().lookup(
"turbulence"))),
80 template<
class CloudType>
88 turbulence_(bmf.turbulence_),
96 template<
class CloudType>
103 template<
class CloudType>
134 template<
class CloudType>
138 const typename CloudType::parcelType::trackingData& td,
147 const scalar dp =
p.d();
148 const scalar Tc = td.Tc();
150 const scalar
alpha = 2.0*lambda_/dp;
159 const label celli =
p.cell();
161 const scalar kc =
k[celli];
181 const scalar a =
sqrt(1 -
sqr(u));
Calculates particle Brownian motion force.
BrownianMotionForce(CloudType &owner, const fvMesh &mesh, const dictionary &dict)
Construct from mesh.
virtual void cacheFields(const bool store)
Cache fields.
virtual ~BrownianMotionForce()
Destructor.
virtual forceSuSp calcCoupled(const typename CloudType::parcelType &p, const typename CloudType::parcelType::trackingData &td, const scalar dt, const scalar mass, const scalar Re, const scalar muc) const
Calculate the coupled force.
Templated base class for dsmc cloud.
ParcelType parcelType
Type of parcel the cloud was instantiated for.
Generic GeometricField class.
Abstract base class for particle forces.
const fvMesh & mesh() const
Return the mesh database.
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.
Helper container for force Su and Sp terms.
const vector & Su() const
Return const access to the explicit contribution [kg m/s^2].
Mesh data needed to do the Finite Volume discretisation.
virtual tmp< volScalarField > k() const =0
Return the turbulence kinetic energy.
scalar scalar01()
Return a scalar uniformly distributed between zero and one.
A class for managing temporary objects.
bool isTmp() const
Return true if this is really a temporary object.
T * ptr() const
Return tmp pointer for reuse.
Template functions to aid in the implementation of demand driven data.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
Fundamental dimensioned constants.
volScalarField alpha(IOobject("alpha", runTime.name(), mesh, IOobject::READ_IF_PRESENT, IOobject::AUTO_WRITE), lambda *max(Ua &U, zeroSensitivity))
compressibleMomentumTransportModel momentumTransportModel
const scalar twoPi(2 *pi)
dimensionedScalar pow5(const dimensionedScalar &ds)
dimensionedScalar exp(const dimensionedScalar &ds)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
dimensionedSymmTensor sqr(const dimensionedVector &dv)
void deleteDemandDrivenData(DataType *&dataPtr)
errorManip< error > abort(error &err)
dimensionedScalar sin(const dimensionedScalar &ds)
dimensionedScalar sqrt(const dimensionedScalar &ds)
dimensioned< scalar > mag(const dimensioned< Type > &)
dimensionedScalar cos(const dimensionedScalar &ds)
scalarField Re(const UList< complex > &cf)
randomGenerator rndGen(653213)