Go to the documentation of this file.
40 (a[0] ==
b[0] && a[1] ==
b[1] && a[2] ==
b[2])
41 || (a[0] ==
b[1] && a[1] ==
b[2] && a[2] ==
b[0])
42 || (a[0] ==
b[2] && a[1] ==
b[0] && a[2] ==
b[1])
50 (a[0] ==
b[2] && a[1] ==
b[1] && a[2] ==
b[0])
51 || (a[0] ==
b[1] && a[1] ==
b[0] && a[2] ==
b[2])
52 || (a[0] ==
b[0] && a[1] ==
b[2] && a[2] ==
b[1])
111 if (
operator[](0) ==
operator[](1) ||
operator[](1) == -1)
116 else if (
operator[](1) ==
operator[](2) ||
operator[](2) == -1)
121 if (
operator[](0) ==
operator[](2))
133 Swap(
operator[](1),
operator[](2));
192 return s < ROOTVSMALL ?
Zero :
n/
s;
211 return triFace(
operator[](0),
operator[](2),
operator[](1));
236 (npts[operator[](0)] - opts[operator[](0)])
238 (opts[
operator[](1)] - opts[
operator[](0)])
239 ^ (opts[operator[](2)] - opts[operator[](0)])
243 (npts[
operator[](1)] - opts[operator[](1)])
245 (opts[
operator[](2)] - opts[
operator[](1)])
246 ^ (npts[operator[](0)] - opts[operator[](1)])
250 (opts[
operator[](2)] - npts[operator[](2)])
252 (npts[
operator[](1)] - npts[
operator[](2)])
253 ^ (npts[operator[](0)] - npts[operator[](2)])
268 return this->tri(
points).inertia(refPt, density);
281 return this->tri(
points).ray(
p, q, alg, dir);
295 return this->tri(
points).intersection(
p, q, alg, tol);
319 return this->tri(
points).nearestPoint(
p);
331 return this->tri(
points).nearestPointClassify(
p, nearType, nearLabel);
342 return this->tri(
points).sign(
p, tol);
356 e[0].first() = operator[](0);
357 e[0].second() = operator[](1);
359 e[1].first() = operator[](1);
360 e[1].second() = operator[](2);
362 e[2].first() = operator[](2);
363 e[2].second() = operator[](0);
371 return edge(
operator[](
n),
operator[](fcIndex(
n)));
383 (
operator[](0) ==
e.first() && operator[](1) ==
e.second())
384 || (
operator[](1) ==
e.first() && operator[](2) ==
e.second())
385 || (
operator[](2) ==
e.first() && operator[](0) ==
e.second())
392 (
operator[](0) ==
e.second() && operator[](1) ==
e.first())
393 || (
operator[](1) ==
e.second() && operator[](2) ==
e.first())
394 || (
operator[](2) ==
e.second() && operator[](0) ==
e.first())
tensor inertia(const UList< point > &points, const point &refPt=vector::zero, scalar density=1.0) const
Return the inertia tensor, with optional reference.
triFace reverseFace() const
Return face with reverse direction.
Useful combination of include files which define Sin, Sout and Serr and the use of IO streams general...
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))
static constexpr const zero Zero
Global zero.
vector areaNormal(const UList< point > &points) const
The area normal - with magnitude equal to area of face.
An edge is a list of two point labels. The functionality it provides supports the discretisation on a...
bool found(const label pointLabel) const
Return true if the point label is found in face.
face triFaceFace() const
Return triangle as a face.
vector unitNormal(const UList< point > &points) const
The unit normal.
void Swap(DynamicList< T, SizeMin1 > &a, DynamicList< T, SizeMin2 > &b)
triPointRef tri(const UList< point > &points) const
Return the triangle.
void flip()
Flip the face in-place.
label collapse()
'Collapse' face by marking duplicate point labels.
Swap arguments as per std::swap, but in Foam namespace.
bool operator!=(const eddy &a, const eddy &b)
bool found(const T &val, const label start=0) const
True if the value if found in the list. Linear search.
A triangle primitive used to calculate face normals and swept volumes.
label which(const label pointLabel) const
Find local index on face for the point label.
pointField points(const UList< point > &points) const
Return the points corresponding to this face.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
const dimensionedScalar b
Wien displacement law constant: default SI units: [m.K].
tmp< faMatrix< Type > > operator==(const faMatrix< Type > &, const faMatrix< Type > &)
int sign(const point &p, const UList< point > &points, const scalar tol=SMALL) const
The sign for which side of the face plane the point is on.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
edgeList edges() const
Return edges in face point ordering,.
edge faceEdge(const label n) const
Return n-th face edge.
label find(const T &val, const label start=0) const
Find index of the first occurence of the value.
scalar sweptVol(const UList< point > &opts, const UList< point > &npts) const
Return swept-volume from old-points to new-points.
point centre(const UList< point > &points) const
Return centre (centroid)
pointHit nearestPoint(const point &p, const UList< point > &points) const
Return nearest point to face.
pointHit nearestPointClassify(const point &p, const UList< point > &points, label &nearType, label &nearLabel) const
Return nearest point to face and classify it:
A triangular face using a FixedList of labels corresponding to mesh vertices.
pointHit ray(const point &p, const vector &q, const UList< point > &points, const intersection::algorithm=intersection::FULL_RAY, const intersection::direction dir=intersection::VECTOR) const
Return point intersection with a ray starting at p, in direction q.
scalar mag(const UList< point > &points) const
Magnitude of face area.
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
A 1D vector of objects of type <T> with a fixed length <N>.
pointHit intersection(const point &p, const vector &q, const UList< point > &points, const intersection::algorithm alg, const scalar tol=0.0) const
Fast intersection with a ray.
const dimensionedScalar e
Elementary charge.
const dimensionedScalar c
Speed of light in a vacuum.
int edgeDirection(const edge &e) const
Return the edge direction on the face.
A face is a list of labels corresponding to mesh vertices.
triFace()
Construct null with invalid point labels (-1)
static int compare(const triFace &a, const triFace &b)
Compare triFaces.
label nTriangles() const
Number of triangles after splitting.
label nEdges() const
Return number of edges.
triangle< point, const point & > triPointRef