kernel-Nat.sumRange_rect_eq_diag_add_corner
- Kind
- kernel-term
- Status
- checked
Supports: `Nat.sumRange_rect_eq_diag_add_corner` is admitted with exactly the type in formal.statement. The proof splits every row via the companion `Nat.sumRange_split` at n = (n-i) + i (pointwise for i<n, lifted by `sumRange_congr_lt`), regroups via `sumRange_add`, then replaces the row-major half by the antidiagonal triangle via `Nat.sumRange_diagonal`. THE PARAMETRIZATION IS THE WHOLE DIFFICULTY: the corner summand is `add (sub n i) k` -- ONE truncated subtraction, never nested. The alternative reflection (i,j) |-> (n-1-i, n-1-j) needs nested `Nat.sub` and was rejected for that reason.
test "$(scripts/cargo-serialized.sh test -p axeyum-lean-kernel --lib nat_prelude::nat_prelude_tests::the_rectangle_decomposition_is_stated_exactly -- --exact 2>&1 | grep -Ec 'test result: ok\. 1 passed; 0 failed')" -ge 1 Evidence notes
A footprint check cannot carry this claim: a theorem that DROPPED the corner term entirely -- i.e. the refuted naive identity -- has an identically empty footprint, as does one summing the triangle to `x2` instead of `succ x2`, which loses the whole antidiagonal. Mutation-verified 2026-08-24: rewriting the pinned corner shape `AxNat.add (AxNat.sub x1 x2) x3` to the nested `AxNat.add (AxNat.sub x1 (AxNat.sub x2 x3)) x3` makes cargo report `578 passed; 1 failed`, naming this test and no other; restored, 579/579 green. The command re-derives from source every run and is anchored on the exact `1 passed; 0 failed` count so an unmatched filter -- which prints `running 0 tests ... ok` and exits 0 -- cannot read as success.