58 if (sizeA != sizeB || sizeA == 0)
80 if (aCirc() == bCirc())
101 if (aCirc() != bCirc())
129 if (aCirc() != bCirc())
179 if (a[i] == a[j]) aOcc++;
186 if (a[i] ==
b[j]) bOcc++;
190 if (aOcc != bOcc)
return false;
204 for (
label i=1; i<size(); i++)
206 if (
operator[](i) != operator[](ci))
208 operator[](++ci) = operator[](i);
212 if (
operator[](ci) !=
operator[](0))
230 for (
label i=1; i < (
n+1)/2; ++i)
232 Swap(
operator[](i),
operator[](
n-i));
266 for (
label pointi = 1; pointi < newList.
size(); pointi++)
268 newList[pointi] =
f[size() - pointi];
271 return face(move(newList));
327 point centreOldPoint = centre(oldPoints);
328 point centreNewPoint = centre(newPoints);
338 oldPoints[
operator[](
pi)],
339 oldPoints[
operator[](
pi + 1)]
345 newPoints[
operator[](
pi)],
346 newPoints[
operator[](
pi + 1)]
354 oldPoints[
operator[](
nPoints-1)],
355 oldPoints[
operator[](0)]
361 newPoints[
operator[](
nPoints-1)],
362 newPoints[
operator[](0)]
385 ).inertia(refPt, density);
388 const point ctr = centre(
p);
397 p[
operator[](fcIndex(i))],
399 ).inertia(refPt, density);
428 if (
operator[](i) ==
e.start())
430 if (
operator[](rcIndex(i)) ==
e.end())
435 else if (
operator[](fcIndex(i)) ==
e.end())
444 else if (
operator[](i) ==
e.end())
446 if (
operator[](rcIndex(i)) ==
e.start())
451 else if (
operator[](fcIndex(i)) ==
e.start())
471 label longestEdgeI = -1;
472 scalar longestEdgeLength = -small;
476 scalar edgeLength = eds[edI].mag(pts);
478 if (edgeLength > longestEdgeLength)
481 longestEdgeLength = edgeLength;
#define forAll(list, i)
Loop across all elements in list.
Walks over a container as if it were circular. The container must have the following members defined:
void setFulcrumToIterator()
Set the fulcrum to the current position of the iterator.
void setIteratorToFulcrum()
Set the iterator to the current position of the fulcrum.
bool circulate(const CirculatorBase::direction dir=CirculatorBase::direction::none)
Circulate around the list in the given direction.
void size(const label)
Override size to be inconsistent with allocated storage.
A List with indirect addressing.
T & last()
Return the last element of the list.
An edge is a list of two point labels. The functionality it provides supports the discretisation on a...
A face is a list of labels corresponding to mesh vertices.
void flip()
Flip the face in-place.
tensor inertia(const pointField &, const point &refPt=vector::zero, scalar density=1.0) const
Return the inertia tensor, with optional reference.
int edgeDirection(const edge &) const
Return the edge direction on the face.
static int compare(const face &, const face &)
Compare faces.
static bool sameVertices(const face &, const face &)
Return true if the faces have the same vertices.
scalar sweptVol(const pointField &oldPoints, const pointField &newPoints) const
Return the volume swept out by the face when its points move.
static vector centre(const PointField &ps)
Return centre point given face points.
vector normal(const pointField &) const
Return unit normal.
label collapse()
Collapse face by removing duplicate point labels.
face reverseFace() const
Return face with reverse direction.
edgeList edges() const
Return edges in face point ordering,.
static vector area(const PointField &ps)
Return vector area given face points.
label which(const label globalIndex) const
Navigation through face vertices.
static const char *const typeName
Calculates a unique integer (label so might not have enough room - 2G max) for processor + local inde...
A triangular face using a FixedList of labels corresponding to mesh vertices.
A triangle primitive used to calculate face areas and swept volumes.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
dimensionSet normalised(const dimensionSet &)
label longestEdge(const face &f, const pointField &pts)
Find the longest edge on a face. Face point labels index into pts.
triangle< point, const point & > triPointRef
points setSize(newPointi)