GI0003

signed_integer_floor_quotient_transport

Replacing a quotient pair by any equal integer preserves the exact floor equation and the same strict remainder.

Alpha v34 checked-use · first admitted v28 · 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.

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

∀ xp. ∀ xn. ∀ m. ∀ qp. ∀ qn. ∀ Qp. ∀ Qn. ∀ r. qp + Qn = qn + Qp → SignedFloor(xp,xn,m,qp,qn,r)SignedFloor(xp,xn,m,Qp,Qn,r)

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

Definition DAG

Actual proof prerequisites

add_left_cancel · checked external prerequisitemul_add · checked external prerequisiteadd_assoc · checked external prerequisiteadd_comm · checked external prerequisitefour_square_add_swap_right_tail · checked external prerequisite
Original expanded first-order statement
forall xp xn m qp qn Qp Qn r. qp + Qn = qn + Qp -> (((xp) + (m) * (qn) = ((xn) + (m) * (qp)) + (r) /\ exists sif_gap_source. sif_gap_source + S (r) = (m))) -> (((xp) + (m) * (Qn) = ((xn) + (m) * (Qp)) + (r) /\ exists sif_gap_target. sif_gap_target + S (r) = (m)))

Complete tactic proof in conservative notation

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

24 script commands · 5 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–10

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

  1. L1
    intro xp
  2. L2
    intro xn
  3. L3
    intro m
  4. L4
    intro qp
  5. L5
    intro qn
  6. L6
    intro Qp
  7. L7
    intro Qn
  8. L8
    intro r
  9. L9
    intro hbalance
  10. L10
    intro hfloor
02Separate the logical casesL11–12

Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.

  1. L11
    cases hfloor
  2. L12
    split
03Use earlier factsL13–16

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

  1. L13
    specialize add_left_cancel (m * qp)
  2. L14
    specialize add_left_cancel (xp + m * Qn)
  3. L15
    specialize add_left_cancel ((xn + m * Qp) + r)
  4. L16
    apply add_left_cancel
04Calculate and transport equalitiesL17–23

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

  1. L17
    trans xp + m * (qp + Qn)
  2. L18
    simp [mul_add, add_assoc, add_comm, four_square_add_swap_right_tail]
  3. L19
    rewrite hbalance
  4. L20
    trans (xp + m * qn) + m * Qp
  5. L21
    simp [mul_add, add_assoc]
  6. L22
    rewrite hfloor_left
  7. L23
    simp [add_assoc, add_comm, four_square_add_swap_right_tail]
05Use earlier factsL24–24

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

  1. L24
    exact hfloor_right

Library-wide reading audit

Original defined command ledger · 24 lines
  1. 0001intro xp
  2. 0002intro xn
  3. 0003intro m
  4. 0004intro qp
  5. 0005intro qn
  6. 0006intro Qp
  7. 0007intro Qn
  8. 0008intro r
  9. 0009intro hbalance
  10. 0010intro hfloor
  11. 0011cases hfloor
  12. 0012split
  13. 0013specialize add_left_cancel (m * qp)
  14. 0014specialize add_left_cancel (xp + m * Qn)
  15. 0015specialize add_left_cancel ((xn + m * Qp) + r)
  16. 0016apply add_left_cancel
  17. 0017trans xp + m * (qp + Qn)
  18. 0018simp [mul_add, add_assoc, add_comm, four_square_add_swap_right_tail]
  19. 0019rewrite hbalance
  20. 0020trans (xp + m * qn) + m * Qp
  21. 0021simp [mul_add, add_assoc]
  22. 0022rewrite hfloor_left
  23. 0023simp [add_assoc, add_comm, four_square_add_swap_right_tail]
  24. 0024exact hfloor_right