FA-87445 / Collision detection broadphase / Member archive
SAH always splits because the leaf cost is ignored · case 05
Tiny nodes are split although a leaf is cheaper, deepening the tree.
Case contract
solve(prims): top-down BVH build step. Split axis = larger centroid extent (x on ties). Primitives sorted by centroid on that axis (index tiebreak). Cost of split k = 1 + (P(L)*k + P(R)*(n-k))/P(parent) with P the box perimeter of the primitives' bounds; leaf cost n. Return [best k or 0 for leaf, axis, cost rounded to 6, sorted left indices].
Why this case matters
Broadphase stages decide which object pairs ever reach narrowphase; a wrong boundary, ordering or bookkeeping rule silently drops real contacts or floods the solver with false candidates.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| case 0 | [1, 0, 3.230769, [1]] | [0, 0, 3.0, []] | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗