space::irbem::Improved
cheatah-space v0.1.0-alpha — Biome Standard 0.6.5-alpha
The improved algorithm — every switch on.
The lane this module ships.
Each switch is justified against the error budget individually in its own documentation below; collectively they change L* by up to the discretization figure of ERROR_BUDGET §2, which is precisely why they are a compile-time choice and why the differential suite compares IrbemFaithful against the oracle instead.
Constants & variables
On — the derivative already evaluated at a step's arrival point becomes the next step's first stage (first-same-as-last), removing one field evaluation in five from the loop that dominates the ~10⁵ model calls of a single L* point.
Bit-exact, not merely within budget: the next step starts from exactly the arrival point, so the carried value is the value the discarded evaluation would have produced. The only way it differs is if the field model is not a pure function of its arguments.
On — each azimuth of the drift shell is seeded from its own local geometry rather than from its neighbour's answer, so the azimuths are independent work items (the shape the GPU lane needs) and the result no longer depends on the traversal order.
Safe because the seed selects only which iterate the search starts from, and the bracketed root-find below converges to the bracketed root regardless — to a tolerance far under the Bmirr budget of 1e-5 relative (ERROR_BUDGET §4). The exception is a shell where the root is not unique in the bracket (shell splitting, a field with multiple minima along the line): there the two seedings can legitimately find different roots, and that case must be reported as a named condition rather than silently resolved by whichever seed was used.
On — the θ march is used only to bracket the B = Bm crossing, and the root is then solved inside that bracket to a tolerance set by the budget rather than by the grid.
This strictly reduces the error at a given resolution: the bracketing march is the same one, and the refinement removes the O(dθ) term the march leaves behind, along with the grid jitter that makes IRBEM's convergence non-monotonic (ERROR_BUDGET §2(b)). It costs a handful of extra field evaluations per mirror point, against the ~10⁵ of an L* point.
On — the I integral is substituted so the square-root vanishing at the mirror points becomes a smooth integrand (write B/Bm = 1 − u², so √(1 − B/Bm) = |u| and the endpoint singularity is absorbed into the Jacobian), and a higher-order rule is then applied to a function that is actually differentiable at its endpoints.
This is the switch that makes the 1e-4 relative budget on XJ (ERROR_BUDGET §4) reachable at the default resolution at all; an O(h) rectangle rule is not within an order of it. It is also the largest of the four changes, so a lane with this on must never be compared point-for-point against the oracle and called agreement.
Human-readable lane name, for the differential suite's per-lane report.
