94 for (
const label pointi : *
this)
108 return s < ROOTVSMALL ?
Zero :
n/
s;
123 for (
const label pointi : *
this)
125 bb.first() =
min(bb.first(),
pts[pointi]);
126 bb.second() =
max(bb.second(),
pts[pointi]);
142 return Foam::edge(thisLabel(edgei), nextLabel(edgei));
152 return vector(
pts[nextLabel(edgei)] -
pts[thisLabel(edgei)]);
160 const label pointi = edgei ? (nEdges() - edgei) : 0;
161 return Foam::edge(thisLabel(pointi), prevLabel(pointi));
173 const label pointi = edgei ? (nEdges() - edgei) : 0;
174 return vector(
pts[prevLabel(pointi)] -
pts[thisLabel(pointi)]);
210 for (
const label pointi : *
this)
224 for (
const label pointi : *
this)
226 if (other.contains(pointi))
241 for (label& vrt : static_cast<labelList&>(*
this))
bool contains(const T &val, label pos=0) const
Is the value contained in the list?
scalar mag(const UList< point > &p) const
Magnitude of face area.
A face is a list of labels corresponding to mesh vertices.
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
A 1D vector of objects of type <T> with a fixed length <N>.
label find(const label &val, label pos=0) const
Find index of the first occurrence of the value.
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
constexpr face() noexcept=default
Default construct.
label nextLabel(const label i) const
Next vertex on face.
Foam::edge rcEdge(const label edgei) const
Return i-th face edge in reverse walk order.
vector unitNormal(const UList< point > &p) const
The unit normal.
Pair< point > box(const UList< point > &pts) const
The enclosing (bounding) box for the face.
label prevLabel(const label i) const
Previous vertex on face.
label & operator[](const label i)
Return element of UList.
pointField points(const UList< point > &pts) const
Return the points corresponding to this face.
An ordered pair of two objects of type <T> with first() and second() elements.
const label & fcValue(const label i) const
Return forward circular value (ie, next value in the list)
An edge is a list of two vertex labels. This can correspond to a directed graph edge or an edge on a ...
const dimensionedScalar b
Wien displacement law constant: default SI units: [m.K].
label which(const label vertex) const
Find local vertex on face for the vertex label, same as find()
label min(const labelHashSet &set, label minValue=labelMax)
Find the min value in labelHashSet, optionally limited by second argument.
iterator begin() noexcept
Return an iterator to begin traversing the UList.
void operator+=(const label vertexOffset)
Increment (offset) vertices by given amount.
label nEdges() const noexcept
Return number of edges.
A Vector of values with scalar precision, where scalar is float/double depending on the compilation f...
Foam::edge edge(const label edgei) const
Return i-th face edge (forward walk order).
bool connected(const labelUList &other) const
True if the face has at least one vertex in common with other.
label thisLabel(const label i) const
The vertex on face - identical to operator[], but with naming similar to nextLabel(), prevLabel()
bool operator!=(const eddy &a, const eddy &b)
label nTriangles() const
Number of triangles after splitting.
static int compare(const face &a, const face &b)
Compare faces.
tmp< faMatrix< Type > > operator==(const faMatrix< Type > &, const faMatrix< Type > &)
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
const label & rcValue(const label i) const
Return reverse circular value (ie, previous value in the list)
static constexpr const zero Zero
Global zero (0)