kernel-Nat.add_assoc
- Kind
- kernel-term
- Status
- checked
Supports: ∀ (n m k : ℕ), n + m + k = n + (m + k)
test "$(cargo run -q -p axeyum-lean-kernel --example nat_theorem_inventory -- add_assoc 2>/dev/null | grep -Ec '^Nat\.add_assoc[[:space:]]')" -ge 1 Evidence notes
`build_nat_prelude` admits `Nat.add_assoc` through the trusted `Kernel::add_declaration` gate, declared in `nat_prelude/algebra.rs`. This is one of `zero_add`/`succ_add`/`add_comm`/`add_assoc`/`add_right_comm` from `nat_prelude/algebra.rs`'s `declare_additive_theorems`, proved by induction on the third argument -- it predates this session and this fact closes by evidence pointing at the existing declaration, no new proof. `nat_theorem_inventory`'s rendered type is `(x0:AxNat)->(x1:AxNat)->(x2:AxNat)->Eq (add (add x0 x1) x2) (add x0 (add x1 x2))`, matching this fact's `formal.statement`. `nat_theorem_inventory` exits non-zero for a name that does not exist, and the `grep -c` count (tested `-ge 1`, not piped into `grep -q`) requires the admitted declaration to actually be printed. Verified both ways: the real name greps to a count `-ge 1`; grepping a made-up name (`Nat.add_assoc_bogus`) greps to `0`.