ellipsoid_tree 0.1.0
Exact intersection tests for ellipsoids and friends
Loading...
Searching...
No Matches
box_forest.hpp File Reference

Compact box-forest summaries of AABB trees, and point/box queries against them. More...

#include "ellipsoid_tree/aabb_tree.hpp"
#include <Eigen/Dense>
#include <algorithm>
#include <queue>
#include <utility>
#include <vector>

Classes

struct  ellipsoid_tree::BoxForest
 A set of axis-aligned boxes, stored as matrix columns (dim x count). More...
 

Namespaces

namespace  ellipsoid_tree
 

Functions

BoxForest ellipsoid_tree::tree_cut (const AABBTree &tree, int max_boxes)
 Cut of an AABB tree with at most max_boxes boxes.
 
std::vector< int > ellipsoid_tree::forest_query (const AABBTree &tree, const BoxForest &forest)
 External indices of the tree leaves whose boxes touch ANY box of the forest, sorted ascending (deterministic order — required by the distributed determinism discipline) and unique.
 

Detailed Description

Compact box-forest summaries of AABB trees, and point/box queries against them.

A box forest is a small set of axis-aligned boxes summarizing a collection of geometric objects (e.g., the ellipsoid footprints owned by one distributed-memory rank). tree_cut extracts a forest as a cut of an AABB tree: repeatedly splitting the largest box until the budget is reached, so far-apart clusters (multi-component subdomains) end up in separate tight boxes instead of one huge one. forest_query finds which leaves of a tree touch any box of a forest — the conservative candidate query of the distributed halo protocol.

Both functions are pure geometry (no MPI): the caller exchanges forests however it likes. Summary quality affects candidate-set size only, never correctness — downstream consumers resolve candidates exactly.