101 if (pt.
z() > mid.
z())
134 if (pt.
x() > mid.
x())
138 else if (pt.
x() == mid.
x())
143 if (pt.
y() > mid.
y())
147 else if (pt.
y() == mid.
y())
152 if (pt.
z() > mid.
z())
156 else if (pt.
z() == mid.
z())
180 if (pt.
x() > mid.
x())
184 else if (pt.
x() == mid.
x())
193 if (pt.
y() > mid.
y())
197 else if (pt.
y() == mid.
y())
206 if (pt.
z() > mid.
z())
210 else if (pt.
z() == mid.
z())
257 if (dist.
x() < dist.
y())
259 if (dist.
y() < dist.
z())
265 else if (dist.
z() < dist.
x())
280 if (dist.
z() < dist.
y())
286 else if (dist.
x() < dist.
z())
301 octantOrder[0] = octant;
303 octantOrder[1] = octant ^
min;
304 octantOrder[2] = octant ^ mid;
305 octantOrder[3] = octant ^
max;
307 octantOrder[4] = octantOrder[1] ^ mid;
308 octantOrder[5] = octantOrder[1] ^
max;
309 octantOrder[6] = octantOrder[2] ^
max;
311 octantOrder[7] = octantOrder[4] ^
max;
331 newSpan[dir] =
Foam::max(newSpan[dir], minSpan);
A 1D vector of objects of type <T> with a fixed size <Size>.
const point & min() const
Minimum describing the bounding box.
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
treeBoundBox extend(Random &, const scalar s) const
Return slightly wider bounding box.
const point & max() const
Maximum describing the bounding box.
point midpoint() const
The midpoint of the bounding box.
A bounding box defined in terms of the points at its extremities.
static const direction nComponents
Number of components in this vector space.
vector vector01()
Vector with every component scalar01.
scalar typDim() const
Typical dimension length,height,width.
void searchOrder(const point &pt, FixedList< direction, 8 > &octantOrder) const
Calculates optimal order to look for nearest to point.
treeBoundBox()
Construct null setting points to zero.
direction subOctant(const point &pt) const
Returns octant number given point and the calculated midpoint.
vector span() const
The bounding box span (from minimum to maximum)
Simple random number generator.
dimensioned< Type > cmptMultiply(const dimensioned< Type > &, const dimensioned< Type > &)
point corner(const direction) const
Corner point given octant.
vector point
Point is a vector.
Standard boundBox + extra functionality for use in octree.
dimensioned< scalar > mag(const dimensioned< Type > &)
scalar avgDim() const
Average length/height/width dimension.