Go to the documentation of this file.
45 (void)
mesh.tetBasePtIs();
57 nFaces += bm[patchIDs[i]].
size();
72 bndFaces[nFaces++] = pp.
start()+i;
73 const face&
f = pp[i];
77 overallBb.
min() =
min(overallBb.
min(), pt);
78 overallBb.
max() =
max(overallBb.
max(), pt);
85 overallBb.
min() -=
point(ROOTVSMALL, ROOTVSMALL, ROOTVSMALL);
86 overallBb.
max() +=
point(ROOTVSMALL, ROOTVSMALL, ROOTVSMALL);
107 scalar span = boundaryTree.
bb().
mag();
124 if (isA<emptyPolyPatch>(bm[
patchi]))
127 <<
" The sample point: " <<
sample
128 <<
" belongs to " <<
patchi
129 <<
" which is an empty patch. This is not permitted. "
130 <<
" This sample will not be included "
155 nearest[probeI]= sampleInfo;
169 operator[](sampleI) = nearest[sampleI].first().rawPoint();
175 Info<<
"patchProbes::findElements" <<
" : " <<
endl;
178 label procI = nearest[sampleI].second().second();
179 label localI = nearest[sampleI].first().index();
181 Info<<
" " << sampleI <<
" coord:"<< operator[](sampleI)
182 <<
" found on processor:" << procI
183 <<
" in local face:" << localI
184 <<
" with location:" << nearest[sampleI].first().rawPoint()
201 faceList_[sampleI] = nearest[sampleI].first().index();
225 const bool loadFromFiles,
226 const bool doFindElements
252 if (this->size() && prepare())
254 sampleAndWrite(scalarFields_);
255 sampleAndWrite(vectorFields_);
256 sampleAndWrite(sphericalTensorFields_);
257 sampleAndWrite(symmTensorFields_);
258 sampleAndWrite(tensorFields_);
260 sampleAndWriteSurfaceFields(surfaceScalarFields_);
261 sampleAndWriteSurfaceFields(surfaceVectorFields_);
262 sampleAndWriteSurfaceFields(surfaceSphericalTensorFields_);
263 sampleAndWriteSurfaceFields(surfaceSymmTensorFields_);
264 sampleAndWriteSurfaceFields(surfaceTensorFields_);
virtual void findElements(const fvMesh &)
Find elements containing patchProbes.
wordReList patchNames_
Patches to sample.
Simple random number generator.
label index() const
Return index.
scalar mag() const
The magnitude of the bounding box span.
const Field< PointType > & points() const
Return reference to global points.
A class for handling words, derived from string.
virtual ~patchProbes()
Destructor.
const point & max() const
Maximum describing the bounding box.
#define forAll(list, i)
Loop across all elements in list.
bool readIfPresent(const word &, T &, bool recursive=false, bool patternMatch=true) const
Find an entry if present, and assign to T.
const Type2 & second() const
Return second.
patchProbes(const patchProbes &)
Disallow default bitwise copy construct.
void readDict(const dictionary &dict)
Read dictionary settings.
Standard boundBox + extra functionality for use in octree.
const Type1 & first() const
Return first.
List< wordRe > wordReList
A List of wordRe (word or regular expression)
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
bool hit() const
Is there a hit.
const Type & shapes() const
Reference to shape.
Ostream & endl(Ostream &os)
Add newline and flush stream.
A wordRe is a word, but can also have a regular expression for matching words.
Registry of regIOobjects.
This class describes the interaction of (usually) a face and a point. It carries the info of a succes...
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
treeBoundBox extend(Random &, const scalar s) const
Return slightly wider bounding box.
const Point & hitPoint() const
Return hit point.
A patch is a list of labels that address the faces in the global face list.
tmp< Field< Type > > sample(const GeometricField< Type, fvPatchField, volMesh > &) const
Sample a volume field at all locations.
Non-pointer based hierarchical recursive searching.
Istream and Ostream manipulators taking arguments.
label whichPatch(const label faceIndex) const
Return patch index for a given face label.
const point & min() const
Minimum describing the bounding box.
Set of locations to sample.
A list of keyword definitions, which are a keyword followed by any number of values (e....
Mesh data needed to do the Finite Volume discretisation.
const double e
Elementary charge.
List< Key > sortedToc() const
Return the table of contents as a sorted list.
label start() const
Return start label of this patch in the polyMesh face list.
static int myProcNo(const label communicator=0)
Number of this process (starting from masterNo() = 0)
const treeBoundBox & bb() const
Top bounding box.
static void listCombineGather(const List< commsStruct > &comms, List< T > &Value, const CombineOp &cop, const int tag, const label comm)
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
void setSize(const label)
Reset size of List.
static const treeBoundBox invertedBox
As per boundBox::invertedBox, but with GREAT instead of VGREAT.
dimensionedSymmTensor sqr(const dimensionedVector &dv)
PointIndexHit< point > pointIndexHit
virtual const pointField & probeLocations() const
Return locations to probe.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Encapsulation of data needed to search for faces.
label size() const
Return the number of elements in the PtrList.
virtual void read(const dictionary &)
Read.
void findNearest(const label nodeI, const linePointRef &ln, treeBoundBox &tightest, label &nearestShapeI, point &linePoint, point &nearestPoint, const FindNearestOp &fnOp) const
Find nearest point to line.
virtual void write()
Public members.
A face is a list of labels corresponding to mesh vertices.
void size(const label)
Override size to be inconsistent with allocated storage.
A 2-tuple for storing two objects of different types.
static void listCombineScatter(const List< commsStruct > &comms, List< T > &Value, const int tag, const label comm)
Scatter data. Reverse of combineGather.
vector point
Point is a vector.
labelHashSet patchSet(const UList< wordRe > &patchNames, const bool warnNotFound=true, const bool usePatchGroups=true) const
Return the set of patch IDs corresponding to the given names.
void readDict(const dictionary &dict)
Read dictionary settings.
defineTypeNameAndDebug(combustionModel, 0)
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
#define WarningInFunction
Report a warning using Foam::Warning.
dimensioned< scalar > magSqr(const dimensioned< Type > &)
cachedRandom rndGen(label(0), -1)
word name(const complex &)
Return a string representation of a complex.