DL00A5

matrix_lattice_positive_gap_integer_transport

A genuine nonnegative signed gap transports across integer cross-sum equality by additive cancellation.

Alpha v34 checked-use · first admitted v27 · independently kernel and Lean verified; not Stable

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.

This branch proves the finite determinant/rank/span substrate. It does not claim Smith or Hermite normal form, lattice index equals determinant, determinant multiplicativity, lattice reduction, or geometry-of-numbers theorems.

Exact theorem in conservative defined notation

∀ p. ∀ n. ∀ P. ∀ N. ∀ D. p + N = P + n → P = N + D → p = n + D

Every linked abbreviation expands hygienically to the identical original native formula.

Definition DAG

none

Actual proof prerequisites

add_right_cancel · checked external prerequisitefour_square_euler_add_swap_last · checked external prerequisiteadd_comm · checked external prerequisite
Original expanded first-order statement
forall p n P N D. p + N = P + n -> P = N + D -> p = n + D

Complete tactic proof in conservative notation

All 21 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

21 script commands · 10 reading checkpoints · 0 local claims

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.

Definition notation is shown below. Open the paired exact edition for the original native formulas. Source pairing is not a new equivalence certificate.

01Fix variables and assumptionsL1–7

Work with arbitrary variables or the premises of the current implication.

  1. L1
    intro p
  2. L2
    intro n
  3. L3
    intro P
  4. L4
    intro N
  5. L5
    intro D
  6. L6
    intro hbalance
  7. L7
    intro hgap
02Use earlier factsL8–11

Instantiate or apply named facts and discharge the corresponding proof obligations.

  1. L8
    specialize add_right_cancel (p)
  2. L9
    specialize add_right_cancel (n + D)
  3. L10
    specialize add_right_cancel (N)
  4. L11
    apply add_right_cancel
03Calculate and transport equalitiesL12–12

Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.

  1. L12
    trans P + n
04Use earlier factsL13–13

Instantiate or apply named facts and discharge the corresponding proof obligations.

  1. L13
    exact hbalance
05Calculate and transport equalitiesL14–15

Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.

  1. L14
    rewrite hgap
  2. L15
    trans (N + n) + D
06Use earlier factsL16–16

Instantiate or apply named facts and discharge the corresponding proof obligations.

  1. L16
    apply four_square_euler_add_swap_last
07Calculate and transport equalitiesL17–18

Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.

  1. L17
    trans (n + N) + D
  2. L18
    congr
08Use earlier factsL19–19

Instantiate or apply named facts and discharge the corresponding proof obligations.

  1. L19
    apply add_comm
09Calculate and transport equalitiesL20–20

Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.

  1. L20
    refl
10Use earlier factsL21–21

Instantiate or apply named facts and discharge the corresponding proof obligations.

  1. L21
    apply four_square_euler_add_swap_last

Library-wide reading audit

Original defined command ledger · 21 lines
  1. 0001intro p
  2. 0002intro n
  3. 0003intro P
  4. 0004intro N
  5. 0005intro D
  6. 0006intro hbalance
  7. 0007intro hgap
  8. 0008specialize add_right_cancel (p)
  9. 0009specialize add_right_cancel (n + D)
  10. 0010specialize add_right_cancel (N)
  11. 0011apply add_right_cancel
  12. 0012trans P + n
  13. 0013exact hbalance
  14. 0014rewrite hgap
  15. 0015trans (N + n) + D
  16. 0016apply four_square_euler_add_swap_last
  17. 0017trans (n + N) + D
  18. 0018congr
  19. 0019apply add_comm
  20. 0020refl
  21. 0021apply four_square_euler_add_swap_last