63 template<
class Po
int,
class Po
intRef>
class tetrahedron;
65 template<
class Po
int,
class Po
intRef>
72 template<
class Po
int,
class Po
intRef>
85 template<
class Po
int,
class Po
intRef>
121 tetIntersectionList& tets_;
134 PointRef a_, b_, c_, d_;
136 inline static point planeIntersection
144 template<
class TetOp>
145 inline static void decomposePrism
151 template<
class AboveTetOp,
class BelowTetOp>
152 inline static void tetSliceWithPlane
199 inline const Point&
a()
const;
201 inline const Point&
b()
const;
203 inline const Point&
c()
const;
205 inline const Point&
d()
const;
222 inline Point
centre()
const;
225 inline scalar
mag()
const;
263 template<
class AboveTetOp,
class BelowTetOp>
275 tetIntersectionList& insideTets,
277 tetIntersectionList& outsideTets,
305 friend Istream&
operator>> <Point, PointRef>
311 friend Ostream& operator<< <Point, PointRef>
void gradNiSquared(scalarField &buffer) const
Fill buffer with shape function products.
const pointField & points
Simple random number generator.
cachedRandom rndGen(label(0),-1)
tetrahedron(const Point &a, const Point &b, const Point &c, const Point &d)
Construct from points.
triPointRef tri(const label faceI) const
Return i-th face.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
scalar barycentric(const point &pt, List< scalar > &bary) const
Calculate the barycentric coordinates of the given.
bool inside(const point &pt) const
Return true if point is inside tetrahedron.
void gradNiGradNj(tensorField &buffer) const
A 1D vector of objects of type <T> with a fixed size <Size>.
void sliceWithPlane(const plane &pl, AboveTetOp &aboveOp, BelowTetOp &belowOp) const
Decompose tet into tets above and below plane.
A triangle primitive used to calculate face normals and swept volumes.
tetrahedron< point, const point & > tetPointRef
pointHit containmentSphere(const scalar tol) const
Return (min)containment sphere, i.e. the smallest sphere with.
scalar mag() const
Return volume.
Point centre() const
Return centre (centroid)
scalar quality() const
Return quality: Ratio of tetrahedron and circum-sphere.
void operator()(const tetPoints &)
Forward declarations of the specialisations of Field<T> for scalar, vector and tensor.
const Point & a() const
Return vertices.
Point circumCentre() const
Return circum-centre.
Geometric class that creates a 2D plane and can return the intersection point between a line and the ...
Point randomPoint(Random &rndGen) const
Return a random point in the tetrahedron from a.
FixedList< tetPoints, 200 > tetIntersectionList
Storage type for tets originating from intersecting tets.
void gradNiGradNi(tensorField &buffer) const
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
void gradNiDotGradNj(scalarField &buffer) const
vector Sa() const
Return face normal.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
scalar circumRadius() const
Return circum-radius.
pointHit nearestPoint(const point &p) const
Return nearest point to p on tetrahedron. Is p itself.
void tetOverlap(const tetrahedron< Point, PointRef > &tetB, tetIntersectionList &insideTets, label &nInside, tetIntersectionList &outsideTets, label &nOutside) const
Decompose tet into tets inside and outside other tet.
Tet storage. Null constructable (unfortunately tetrahedron<point, point> is not)