Gram-multilevel Gauss–Newton optimizer
Implementation & benchmark of arXiv:2607.07485 — A black-box, multilevel algebraic preconditioning framework for conforming finite elements
Source paper: A black-box, multilevel algebraic preconditioning framework for conforming finite elements arXiv:2607.07485 ⓘ · analyzed Aug 30, 2026
AI-generated research hypothesis, automatically tested. Not peer-reviewed.
Idea description
Replace an unpreconditioned conjugate-gradient solve for a damped Gauss–Newton step with a two-level algebraic preconditioner derived from local Jacobian-row supports. Use overlapping local parameter blocks as Schwarz subdomains and a coarse basis containing low-energy local modes, so the optimizer can correct both localized and globally coupled parameter errors.
Formulas
Mathematical statement
The paper represents an SPD matrix as A = G^T G = sum_{j=1}^m g_j g_j^T, where G has m rows, g_j in R^n is row j transposed, n is the number of unknowns, and each rank-one term g_j g_j^T is an SPSD local energy. For a neural least-squares problem with residual vector r(theta) in R^m and Jacobian J(theta) in R^{m x n}, use G = J and A_lambda = J^T J + lambda I, where theta in R^n is the parameter vector and lambda > 0 is damping. The paper's two-level error propagator is E_TG = (I - M^{-T} A)(I - P A_c^{-1} P^T A)(I - M^{-1} A), with P in R^{n x n_c} the interpolation/coarse basis, A_c = P^T A P = (G P)^T(G P), n_c the coarse dimension, and M^{-1} a block-Schwarz smoother. The exact identity A_c = (G P)^T(G P) means the coarse operator can be formed by applying J to coarse basis vectors, without assembling a new dense Hessian. Define the row-touching set R_omega = {j : supp(g_j) intersects omega} for parameter block omega, and the G-row closure Omega_omega^G = union_{j in R_omega} supp(g_j); this supplies an algebraic overlap rule. In the adaptation, local operators are A_i = J_i^T J_i + lambda I on overlapping closures Omega_i^G, local eigenvectors with smallest generalized energy are retained in P, and the preconditioner is evaluated through local solves plus a coarse solve.
Implementation notes
Integrate this at the optimizer step for a least-squares model, immediately after computing a minibatch residual r and Jacobian J. Do not form J^T J explicitly. Use parameter blocks omega_i, initially one block per layer or per group of neurons. First compute approximate row supports: for each residual/Jacobian row j, record parameter blocks whose Jacobian norm exceeds a threshold tau; define each block's overlap Omega_i as the union of blocks touched by those rows. Pseudocode: (1) compute r and J or Jacobian-vector products; (2) set A_lambda = J^T J + lambda I conceptually; (3) for every overlapping Omega_i, form the restricted Jacobian J_i and solve (J_i^T J_i + lambda I) z_i = R_i v using a small dense Cholesky or a few CG iterations; combine z = sum_i R_i^T z_i with diagonal overlap normalization to obtain M^{-1}v; (4) build P by taking k low-energy eigenvectors from each local generalized problem (J_i^T J_i + lambda I)u = mu (D_i + lambda I)u, where D_i is the local diagonal or block-diagonal preconditioner; discard duplicate vectors and orthonormalize; (5) apply the coarse correction by solving A_c y = P^T b with A_c represented as (JP)^T(JP) + lambda P^T P; (6) run preconditioned CG on A_lambda Delta_theta = -J^T r, then update theta <- theta + Delta_theta. The paper supplies the Gram preservation, row-closure rule, and multiplicative error-correction structure; the eigenvalue cutoff k, overlap threshold tau, damping lambda, and CG tolerance are empirical. Start with a two-level method and k=2 to 8 modes per layer. The first experiment should use a width-256 MLP on a 20-dimensional nonlinear regression dataset, comparing Adam, ordinary damped Gauss–Newton CG, block-Jacobi-preconditioned CG, and this method at equal Jacobian evaluations. Measure residual decrease per CG iteration, wall-clock time to a fixed training loss, number of CG iterations, and damping sensitivity. Success is a 2x reduction in CG iterations or a lower loss at equal Jacobian/FLOP budget without worsening final residual; a useful negative result is no improvement over block Jacobi when supports are dense.
Verification
Stage 1 · Toy mechanism gate: Failed ✗
Stage 2 · Mechanism transferred to benchmark: Not tested
Stage 2 · Practical benchmark result: Not run
Methodology: Toy-system gate first; the benchmark stage runs only after a pass. How verification works
Stage 1 — Mechanism check agent confidence 9/10
Built a self-contained row-closure Gram preconditioner experiment with multiplicity-weighted local SPSD splitting, local generalized modes, and Galerkin coarse correction. The exact splitting error was 8.7e-17 and the coarse Gram identity error was 1.2e-15, confirming the algebra. However, on the 1D Gram test, unpreconditioned CG converged in 120 iterations, block Jacobi in 166, while the two-level method reached the 500-iteration cap with relative residual 8.46e-5; damping checks also gave 500 iterations for the idea versus 310, 166, and 52 for block Jacobi at lambda 1e-6, 1e-4, and 1e-2. This MVP therefore shows no promised optimization win and possibly an unsuitable coarse/smoother composition.
- Agent confidence
- 9/10
- Baseline
- Unpreconditioned CG: 120 iterations, 2.47e-15 relative residual. Block Jacobi: 166 iterations, 9.85e-10 relative residual at lambda=1e-4.
- Idea
- Two-level row-closure method: 500-iteration cap, 8.46e-5 relative residual at lambda=1e-4; 500 iterations at lambda=1e-6 and 1e-2 in the damping check.
Limitations: This was a small structured linear Gram-system sanity test, not the requested width-256 nonlinear MLP/minibatch Jacobian experiment. No wall-clock/FLOP accounting, Adam comparison, GPU execution, or genuinely multiplicative symmetric Schwarz cycle was tested. The implementation follows the idea’s smallest-local-mode wording, while the paper section describes retaining modes above a cutoff, so mode-selection conventions remain a significant unresolved limitation.
How to run: python3 gram_multilevel_experiment.py
Verdict computed by deterministic test code from paired-seed statistics — not by the language model.