50 #ifndef KinematicParcel_H 51 #define KinematicParcel_H 66 template<
class ParcelType>
74 template<
class ParcelType>
85 template<
class ParcelType>
93 static label maxTrackAttempts;
154 inline scalar
rhoMin()
const;
157 inline scalar
rho0()
const;
166 public ParcelType::trackingData
243 template <
class TrackCloudType>
246 const TrackCloudType&
cloud,
266 inline scalar
rhoc()
const;
269 inline scalar&
rhoc();
278 inline scalar
muc()
const;
281 inline scalar&
muc();
284 inline const vector&
g()
const;
293 template<
class TrackCloudType>
343 template<
class TrackCloudType>
346 TrackCloudType&
cloud,
378 +
" (UTurbx UTurby UTurbz)" 379 +
" (UCorrectx UCorrecty UCorrectz)" 392 const label tetFacei,
411 const label tetFacei,
414 const scalar nParticle0,
416 const scalar dTarget0,
427 bool newFormat =
true 461 autoPtr<KinematicParcel<ParcelType>>
operator()(Istream& is)
const 463 return autoPtr<KinematicParcel<ParcelType>>
465 new KinematicParcel<ParcelType>(mesh_, is,
true)
476 inline bool active()
const;
479 inline label
typeId()
const;
485 inline scalar
d()
const;
491 inline const vector&
U()
const;
494 inline scalar
rho()
const;
497 inline scalar
age()
const;
500 inline scalar
tTurb()
const;
512 inline void active(
const bool state);
530 inline scalar&
rho();
533 inline scalar&
age();
536 inline scalar&
tTurb();
548 inline scalar
massCell(
const trackingData& td)
const;
551 inline scalar
mass()
const;
557 inline scalar
volume()
const;
560 inline static scalar
volume(
const scalar
d);
563 inline scalar
areaP()
const;
566 inline static scalar
areaP(
const scalar
d);
569 inline scalar
areaS()
const;
572 inline static scalar
areaS(
const scalar
d);
578 inline static scalar
Re 595 inline static scalar
We 612 inline static scalar
Eo 626 template<
class TrackCloudType>
631 template<
class TrackCloudType>
634 TrackCloudType&
cloud,
640 template<
class TrackCloudType>
643 TrackCloudType&
cloud,
649 template<
class TrackCloudType>
652 TrackCloudType&
cloud,
658 template<
class TrackCloudType>
661 TrackCloudType&
cloud,
670 template<
class TrackCloudType>
673 TrackCloudType&
cloud,
675 const scalar trackTime
683 template<
class TrackCloudType>
688 template<
class TrackCloudType>
692 template<
class TrackCloudType>
707 template<
class TrackCloudType>
711 template<
class TrackCloudType>
720 const bool namesOnly =
false 724 template<
class CloudType>
728 template<
class CloudType>
734 friend Ostream& operator<< <ParcelType>
scalar massCell(const trackingData &td) const
Cell owner mass.
const vector & U() const
Return const access to velocity.
static void writeFields(const TrackCloudType &c)
Write.
scalar tTurb() const
Return const access to time spent in turbulent eddy.
scalar rhoMin() const
Return const access to the minimum density.
const vector & UTurb() const
Return const access to turbulent velocity fluctuation.
A list of keyword definitions, which are a keyword followed by a number of values (eg...
Kinematic parcel class with rotational motion (as spherical particles only) and one/two-way coupling ...
autoPtr< KinematicParcel< ParcelType > > operator()(Istream &is) const
TypeName("KinematicParcel")
Runtime type information.
scalar nParticle() const
Return const access to number of particles.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
Class to hold kinematic particle constant properties.
scalar mass() const
Particle mass.
scalar d() const
Return const access to diameter.
scalar tTurb_
Time spent in turbulent eddy [s].
scalar rho() const
Return const access to density.
bool cp(const fileName &src, const fileName &dst, const bool followLink=true)
Copy the source to the destination (recursively if necessary).
const interpolation< vector > & UInterp() const
Return const access to the interpolator for continuous phase velocity field.
scalar rho0() const
Return const access to the particle density.
void setCellValues(TrackCloudType &cloud, trackingData &td)
Set cell values.
constantProperties()
Default construct.
scalar areaP() const
Particle projected area.
dimensionedScalar sigma("sigma", dimMass/sqr(dimTime), transportProperties)
KinematicParcel(const polyMesh &mesh, const barycentric &coordinates, const label celli, const label tetFacei, const label tetPti)
Construct from mesh, coordinates and topology.
const vector & UCorrect() const
Return const access to correction velocity.
scalar dTarget() const
Return const access to target diameter.
label parcelTypeId() const
Return const access to the parcel type id.
scalar dTarget_
Target diameter [m].
scalar age() const
Return const access to the age.
trackPart part() const
Return the part of the tracking operation taking place.
void cellValueSourceCorrection(TrackCloudType &cloud, trackingData &td, const scalar dt)
Correct cell values using latest transfer information.
scalar Eo(const trackingData &td, const scalar sigma) const
Eotvos number.
AddToPropertyList(ParcelType, " active"+" typeId"+" nParticle"+" d"+" dTarget"+" (Ux Uy Uz)"+" rho"+" age"+" tTurb"+" (UTurbx UTurby UTurbz)"+" (UCorrectx UCorrecty UCorrectz)")
String representation of properties.
scalar rho_
Density [kg/m3].
virtual void transformProperties(const tensor &T)
Transform the physical properties of the particle.
scalar momentOfInertia() const
Particle moment of inertia around diameter axis.
A class for handling words, derived from Foam::string.
static void writeObjects(const CloudType &c, objectRegistry &obr)
Write particle fields as objects into the obr registry.
const dictionary dict_
Constant properties dictionary.
A cloud is a registry collection of lagrangian particles.
label typeId_
Parcel type id.
void writeProperties(Ostream &os, const wordRes &filters, const word &delim, const bool namesOnly=false) const
Write individual parcel properties to stream.
vector UTurb_
Turbulent velocity fluctuation [m/s].
Base class for lagrangian averaging methods.
A List of wordRe with additional matching capabilities.
static void readFields(TrackCloudType &c)
Read.
void calc(TrackCloudType &cloud, trackingData &td, const scalar dt)
Update parcel properties over the time interval.
bool active() const
Return const access to active flag.
static const std::size_t sizeofFields
Size in bytes of the fields.
const vector calcVelocity(TrackCloudType &cloud, trackingData &td, const scalar dt, const scalar Re, const scalar mu, const scalar mass, const vector &Su, vector &dUTrans, scalar &Spu) const
Calculate new particle velocity.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
const uniformDimensionedVectorField & g
static void readObjects(CloudType &c, const objectRegistry &obr)
Read particle fields as objects from the obr registry.
A Vector of values with scalar precision, where scalar is float/double depending on the compilation f...
scalar rhoc() const
Return the continuous phase density.
OBJstream os(runTime.globalPath()/outputName)
scalar muc() const
Return the continuous phase viscosity.
scalar nParticle_
Number of particles in Parcel.
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
scalar minParcelMass() const
Return const access to the minimum parcel mass.
trackingData(const TrackCloudType &cloud, trackPart part=tpLinearTrack)
Construct from components.
const dimensionedScalar mu
Atomic mass unit.
iNew(const polyMesh &mesh)
vector U_
Velocity of Parcel [m/s].
virtual autoPtr< particle > clone() const
Construct and return a (basic particle) clone.
PtrList< coordinateSystem > coordinates(solidRegions.size())
const dimensionedScalar c
Speed of light in a vacuum.
scalar volume() const
Particle volume.
const interpolation< scalar > & rhoInterp() const
Return const access to the interpolator for continuous phase density field.
const interpolation< scalar > & muInterp() const
Return const access to the interpolator for continuous phase dynamic viscosity field.
scalar Re(const trackingData &td) const
Reynolds number.
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
Mesh consisting of general polyhedral cells.
bool move(TrackCloudType &cloud, trackingData &td, const scalar trackTime)
Move the parcel.
label active_
Active flag - tracking inactive when active = false.
Registry of regIOobjects.
label typeId() const
Return const access to type id.
Tensor of scalars, i.e. Tensor<scalar>.
Templated base class for dsmc cloud.
void hitProcessorPatch(TrackCloudType &cloud, trackingData &td)
Overridable function to handle the particle hitting a.
scalar areaS() const
Particle surface area.
bool hitPatch(TrackCloudType &cloud, trackingData &td)
Overridable function to handle the particle hitting a patch.
const vector & Uc() const
Return the continuous phase velocity.
vector UCorrect_
Velocity correction due to collisions MPPIC [m/s].
void calcUCorrection(TrackCloudType &cloud, trackingData &td, const scalar dt)
Correct U following MP-PIC sub-models.
scalar We(const trackingData &td, const scalar sigma) const
Weber number.
void calcDispersion(TrackCloudType &cloud, trackingData &td, const scalar dt)
Apply dispersion to the carrier phase velocity and update.
const dictionary & dict() const
Return const access to the constant properties dictionary.
void hitWallPatch(TrackCloudType &cloud, trackingData &td)
Overridable function to handle the particle hitting a wallPatch.
void updateAverages(const TrackCloudType &cloud)
Update the MPPIC averages.