nx_linalg_chol_gate.nx
buildroot/runtime/nx_linalg_chol_gate.nx
about
nx_linalg_chol_gate.nx -- THE REFEREE FOR THE Q30 CHOLESKY (graphics GR47).
The done-rule GR47 declared BEFORE this was written, quoted from graphics.plan so the bar cannot drift:
"a Q30 fixed-point Cholesky over nx_fixq30_lib arithmetic factors any SPD matrix up to the
identity-space dimension, L times L-transposed reproduces the input within a stated Q30 band on
random SPD fixtures, a non-SPD input is refused by name rather than producing garbage, and GR24
composes it for its draw (one ruler, never a second decomposition)"
This gate proves the first three clauses. The fourth is GR24's own rung and is NOT claimed here.
THE LOAD-BEARING TOOTH IS THE TEXTBOOK 3x3, because its factor is known by hand and INDEPENDENTLY of this
implementation: A = [[4,12,-16],[12,37,-43],[-16,-43,98]] has L = [[2,0,0],[6,1,0],[-8,5,3]] exactly.
A residual check alone would pass for any L whose product happens to reconstruct A; comparing against a
hand-derived L tests that this is THE Cholesky factor and not merely A factor.
license_tier: ORIGINAL No hw writes (Rule 26).
dependencies 3 imports · 0 importers
imports: nx_syscalls.nxnx_gate_verdict.nxnx_linalg.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| 19 | const LCG_MAXN: i64 = 8 |
functions
| 22 | func lcg_mat(n: i64, vals: *i64) -> *Mat |
| 32 | func lcg_vals(n: i64) -> *i64 { return sys_mmap(n * n * 8) as *i64 } |
| 35 | func lcg_l_diff(l: *Mat, exp: *Mat) -> i64 |
| 53 | func lcg_is_lower(l: *Mat) -> i64 |
| 63 | func lcg_all_zero(l: *Mat) -> i64 |
| 74 | func main() -> i64 |