_calc_kernel
tit._calc_kernel ¶
numba kernel for the K>=2 sphere maximum of :func:tit.calc.envelope_max.
One element at a time, parallel over elements: track the three eigen-branches of
cos(t) C+ - sin(t) C- over tit.calc._THETA_GRID, root-find every sign change of
g = cos^2(t) u - sin^2(t) v along a branch, add safeguard candidates, then polish the best
candidates with Newton ascent. Each step is load-bearing: removing any of them, or lowering
tit.calc._ROOT_ITERS / _NEWTON_ITERS, fails the dense-search tests in
tests/test_calc.py. The 3x3 eigensolver is cyclic Jacobi warm-started from the previous
eigenvectors (LAPACK's per-call overhead was most of the cost of a NumPy version).
numba is a hard dependency: the image ships it and container/blueprint/verify_runtime.py
fails the build without it. Accuracy is pinned against independent oracles in
tests/test_calc.py (host) and tests/numerical/test_calc_kernel.py (image).
max_sphere ¶
K>=2 sphere maximum of E (2K, n, 3): (amp, n_hat, ok), parallel over elements.
ok is False where an eigen-solve did not converge; tit.calc raises on any such row.