34 const point& position,
36 label& nLocateBoundaryHits,
42 particle(mesh, position, celli, nLocateBoundaryHits),
46 havePosition0_(false),
47 position0_(
point::uniform(NaN))
57 is >> seti_ >> setF_ >> distance_ >> havePosition0_ >> position0_;
72 distance_(
p.distance_),
73 havePosition0_(
p.havePosition0_),
74 position0_(
p.position0_)
117 havePosition0_ =
true;
118 position0_ = position(td.
mesh);
134 const scalar magS =
mag(
s);
136 const scalar
f = trackToFace(td.
mesh, setF_*
s, 0);
137 distance_ += (1 -
f)*setF_*magS;
140 while (onInternalFace(td.
mesh))
145 hitFace(setF_*
s, 0,
cloud, td);
147 const scalar
f = trackToFace(td.
mesh, setF_*
s, 0);
148 distance_ += (1 -
f)*setF_*magS;
157 hitFace(setF_*
s, 0,
cloud, td);
160 if (onBoundaryFace(td.
mesh) && setF_ < rootSmall)
267 os << static_cast<const particle&>(
p)
DynamicList< T, SizeInc, SizeMult, SizeDiv > & append(const T &)
Append an element at the end of the list.
virtual bool check(const char *operation) const
Check IOstream status for given operation.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
A cell is defined as a list of faces with extra functionality.
A cloud is a collection of lagrangian particles.
A face is a list of labels corresponding to mesh vertices.
label sendToProc
Processor to send the particle to. -1 indicates that this.
bool keepParticle
Flag to indicate whether to keep particle (false = delete)
const polyMesh & mesh
Reference to the mesh.
static void readFields(TrackCloudType &c)
Read the fields associated with the owner cloud.
void hitProcessorPatch(TrackCloudType &, trackingData &)
Overridable function to handle the particle hitting a.
void correctAfterParallelTransfer(TrackCloudType &, trackingData &)
Make changes following a parallel transfer. Runs either.
Mesh consisting of general polyhedral cells.
const polyBoundaryMesh & boundaryMesh() const
Return boundary mesh.
Neighbour processor patch.
virtual const transformer & transform() const
Return null transform between processor patches.
A Cloud of sampledSet particles.
DynamicList< label > & cells_
Stored cell indices.
const bool storeCells_
Are we storing the cells we track through?
DynamicList< point > & positions_
Stored positions.
const bool storeSet_
Are we storing the set points?
const List< point > & set_
List of set points to track through.
DynamicList< label > & faces_
Stored face indices.
const label storeFaces_
Are we storing the faces we track through?
DynamicList< scalar > & distances_
Stored distances.
Particle for generating line-type sampled sets.
void hitCyclicPatch(sampledSetCloud &, trackingData &)
Hit a cyclic patch. Ends the track.
void storeFace(sampledSetCloud &, trackingData &)
Store a point on a face.
void hitWallPatch(sampledSetCloud &, trackingData &)
Hit a wall patch. Ends the track.
bool move(sampledSetCloud &, trackingData &)
Track all particles to their end point.
sampledSetParticle(const polyMesh &mesh, const point &position, const label celli, label &nLocateBoundaryHits, const label seti, const scalar setF, const scalar distance)
Construct from components.
void storeCell(sampledSetCloud &, trackingData &)
Store a point in a cell.
void hitSymmetryPatch(sampledSetCloud &, trackingData &)
Hit a symmetry plane patch. Ends the track.
void store(sampledSetCloud &, trackingData &)
Store a point.
void hitWedgePatch(sampledSetCloud &, trackingData &)
Hit a wedge patch. Ends the track.
void correctAfterParallelTransfer(sampledSetCloud &, trackingData &)
Do corrections to the particle and tracking data following a.
void hitProcessorPatch(sampledSetCloud &, trackingData &)
Hit a processor patch. Transfers the particle if there is no.
void hitSymmetryPlanePatch(sampledSetCloud &, trackingData &)
Hit a symmetry patch. Ends the track.
gmvFile<< "tracers "<< particles.size()<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().x()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().y()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.name(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
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 readFields(const typename GeoFieldType::Mesh &mesh, const IOobjectList &objects, const HashSet< word > &selectedFields, LIFOStack< regIOobject * > &storedObjects)
Read the selected GeometricFields of the specified type.
dimensioned< scalar > mag(const dimensioned< Type > &)
Ostream & operator<<(Ostream &os, const fvConstraints &constraints)
static const label labelMax