Current library: Alpha v34, 4,223 checked-use theorems; Stable remains 432. Historical first admissions, original proof editions, and non-admitted aliases are preserved. Exact original first-admission records.
The natural-code carrier consists of genuine pairs of the existing signed integers; no new primitive arithmetic is trusted. The theorem constructs quotient, remainder, and actual norm witnesses. Gaussian gcd, unique factorization, and prime classification are separate targets.
Exact theorem in conservative defined notation
∀ p. ∀ n. ∀ s. ∀ k. SignedDifferenceSquare(p,n,s) → SignedDifferenceSquare(k · p,k · n,k · k · s)
Every linked abbreviation expands hygienically to the identical original native formula.
Definition DAG
Actual proof prerequisites
Complete tactic proof in conservative notation
All 30 original proof lines are preserved. Only local proposition formulas are abbreviated; every abbreviation has an exact binder-safe expansion check. The linked exact edition contains the unchanged replay script.
Read the argument
Proof checkpoints
This is a reading aid, not a new proof or a proof-tree certificate. Checkpoint groups are consecutive commands, not inferred branch boundaries. Every step links to the preserved script.
Named ingredients (1)
01Fix variables and assumptionsL1–5
02Establish hnaturalL6–7
Establish this local claim before using it. It is not an additional assumption.
- L6
have hnatural : SignedDifferenceSquare(k,0,k · k)Definitions: SignedDifferenceSquare(k,0,k · k)Original native command in the exact edition - L7
simp [mul_zero_left, zero_add]
03Establish hproductL8–17
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply gaussian signed square product.
- L8
have hproduct : SignedDifferenceSquare(k · p + 0 · n,k · n + 0 · p,k · k · s)Definitions: SignedDifferenceSquare(k · p + 0 · n,k · n + 0 · p,k · k · s)Original native command in the exact edition - L9
specialize gaussian_signed_square_product k - L10
specialize gaussian_signed_square_product 0 - L11
specialize gaussian_signed_square_product p - L12
specialize gaussian_signed_square_product n - L13
specialize gaussian_signed_square_product k * k - L14
specialize gaussian_signed_square_product s - L15
apply gaussian_signed_square_product - L16
exact hnatural - L17
exact hsquare
04Establish hpositiveL18–19
05Establish hnegativeL20–29
Establish this local claim before using it. It is not an additional assumption.
- L20
have hnegative : k * n + 0 * p = k * n - L21
simp [mul_zero_left, zero_add] - L22
rewrite hpositive at hproduct - L23
rewrite hpositive at hproduct - L24
rewrite hpositive at hproduct - L25
rewrite hpositive at hproduct - L26
rewrite hnegative at hproduct - L27
rewrite hnegative at hproduct - L28
rewrite hnegative at hproduct - L29
rewrite hnegative at hproduct
06Use earlier factsL30–30
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L30
exact hproduct
Original defined command ledger · 30 lines
- 0001
intro p - 0002
intro n - 0003
intro s - 0004
intro k - 0005
intro hsquare - 0006
have hnatural : SignedDifferenceSquare(k,0,k · k) - 0007
simp [mul_zero_left, zero_add] - 0008
have hproduct : SignedDifferenceSquare(k · p + 0 · n,k · n + 0 · p,k · k · s) - 0009
specialize gaussian_signed_square_product k - 0010
specialize gaussian_signed_square_product 0 - 0011
specialize gaussian_signed_square_product p - 0012
specialize gaussian_signed_square_product n - 0013
specialize gaussian_signed_square_product k * k - 0014
specialize gaussian_signed_square_product s - 0015
apply gaussian_signed_square_product - 0016
exact hnatural - 0017
exact hsquare - 0018
have hpositive : k * p + 0 * n = k * p - 0019
simp [mul_zero_left, zero_add] - 0020
have hnegative : k * n + 0 * p = k * n - 0021
simp [mul_zero_left, zero_add] - 0022
rewrite hpositive at hproduct - 0023
rewrite hpositive at hproduct - 0024
rewrite hpositive at hproduct - 0025
rewrite hpositive at hproduct - 0026
rewrite hnegative at hproduct - 0027
rewrite hnegative at hproduct - 0028
rewrite hnegative at hproduct - 0029
rewrite hnegative at hproduct - 0030
exact hproduct