81 is >> start_ >> end_ >> data_;
90 reinterpret_cast<char*
>(&start_),
91 sizeof(start_) +
sizeof(end_) +
sizeof(data_)
106 const scalar maxTrackLen
109 td.switchProcessor =
false;
110 td.keepParticle =
true;
112 while (
td.keepParticle && !
td.switchProcessor && stepFraction() < 1)
114 const scalar
f = 1 - stepFraction();
115 trackToAndHitFace(
f*(end_ - start_),
f,
cloud,
td);
121 if (stepFraction() >= 1 || !
td.keepParticle)
125 td.cellToData()[cell()].append(data());
129 return td.keepParticle;
146 td.keepParticle =
false;
157 td.keepParticle =
false;
168 td.keepParticle =
false;
179 td.keepParticle =
false;
191 td.keepParticle =
false;
203 td.keepParticle =
false;
214 td.switchProcessor =
true;
225 td.keepParticle =
false;
245 reinterpret_cast<const char*
>(&
p.start_),
246 sizeof(
p.start_) +
sizeof(
p.end_) +
sizeof(
p.data_)
Base cloud calls templated on particle type.
streamFormat format() const noexcept
Get the current stream format.
@ ASCII
"ascii" (normal default)
virtual bool check(const char *operation) const
Check IOstream status for given operation.
bool fatalCheckNativeSizes(const char *operation) const
Assert that the label/scalar byte-size associated with the stream are the native label/scalar sizes.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
virtual Istream & read(token &)=0
Return next token from stream.
virtual Ostream & write(const char c) override
Write character.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
A cloud is a registry collection of lagrangian particles.
Class used to pass tracking data to the trackToFace function.
Particle class that finds cells by tracking.
bool hitPatch(Cloud< findCellParticle > &, trackingData &)
Overridable function to handle the particle hitting a patch.
void hitWallPatch(Cloud< findCellParticle > &, trackingData &)
Overridable function to handle the particle hitting a wallPatch.
void hitProcessorPatch(Cloud< findCellParticle > &, trackingData &)
Overridable function to handle the particle hitting a processorPatch.
void hitSymmetryPatch(Cloud< findCellParticle > &, trackingData &)
Overridable function to handle the particle hitting a.
void hitCyclicACMIPatch(Cloud< findCellParticle > &, trackingData &, const vector &)
Overridable function to handle the particle hitting a cyclicACMI.
void hitSymmetryPlanePatch(Cloud< findCellParticle > &, trackingData &)
Overridable function to handle the particle hitting a.
bool move(Cloud< findCellParticle > &, trackingData &, const scalar)
Track all particles to their end point.
findCellParticle(const polyMesh &mesh, const barycentric &coordinates, const label celli, const label tetFacei, const label tetPti, const point &end, const label data)
Construct from components.
label data() const noexcept
Transported label.
const point & end() const noexcept
Point to track to.
void hitWedgePatch(Cloud< findCellParticle > &, trackingData &)
Overridable function to handle the particle hitting a wedge.
void hitCyclicAMIPatch(Cloud< findCellParticle > &, trackingData &, const vector &)
Overridable function to handle the particle hitting a cyclicAMI.
void hitCyclicPatch(Cloud< findCellParticle > &, trackingData &)
Overridable function to handle the particle hitting a cyclic.
vector position() const
Return current particle position.
static void readFields(TrackCloudType &c)
Read the fields associated with the owner cloud.
const polyMesh & mesh() const noexcept
Return the mesh database.
const barycentric & coordinates() const noexcept
Return current particle coordinates.
scalar stepFraction() const noexcept
Return the fraction of time-step completed.
void trackToAndHitFace(const vector &direction, const scalar fraction, TrackCloudType &cloud, trackingData &td)
Convenience function. Combines trackToFace and hitFace.
label cell() const noexcept
Return current cell particle is in.
particle(const polyMesh &mesh, const barycentric &coordinates, const label celli, const label tetFacei, const label tetPti)
Construct from components.
Mesh consisting of general polyhedral cells.
OBJstream os(runTime.globalPath()/outputName)
wallPoints::trackData td(isBlockedFace, regionToBlockSize)
void readFields(const typename GeoFieldType::Mesh &mesh, const IOobjectList &objects, const NameMatchPredicate &selectedFields, DynamicList< regIOobject * > &storedObjects)
Read the selected GeometricFields of the templated type and store on the objectRegistry.
Ostream & operator<<(Ostream &, const boundaryPatch &p)
Write boundaryPatch as dictionary entries (without surrounding braces).
vector point
Point is a vector.
Barycentric< scalar > barycentric
A scalar version of the templated Barycentric.