BX0004

binary_canonical_residue_exists_unique

Each guarded modulus admits exactly one actual bounded residue.

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

G102 was OPEN when this family was first admitted in Alpha v21. It is now CLOSED in Alpha v23: every arbitrary exponent has actual canonical beta-coded digits, a complete modular execution, and exact counted bound operations≤3*BitLen(e)+2.

Exact theorem in conservative defined notation

∀ m. ∀ n. BinaryModulus(m) → ∃ x. CanonicalModularResidue(m,n,x) ∧ (∀ y. CanonicalModularResidue(m,n,y) → x = y)

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

Definition DAG

Actual proof prerequisites

Original expanded first-order statement
forall m n. (exists ff_modulus_gap_binary_guard. ff_modulus_gap_binary_guard + S 1 = m) -> exists r. ((((exists ff_gap_binary_value. ff_gap_binary_value + S (r) = m) /\ (exists ff_left_binary_value_congruence ff_right_binary_value_congruence. (n) + m * ff_left_binary_value_congruence = (r) + m * ff_right_binary_value_congruence))) /\ forall s. (((exists ff_gap_binary_other. ff_gap_binary_other + S (s) = m) /\ (exists ff_left_binary_other_congruence ff_right_binary_other_congruence. (n) + m * ff_left_binary_other_congruence = (s) + m * ff_right_binary_other_congruence))) -> r = s)

Complete unchanged native tactic proof

All 21 lines are the exact independently kernel-checked original script.

Read the argument

Proof checkpoints

21 script commands · 9 reading checkpoints · 1 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.

Named ingredients (2)
01Fix variables and assumptionsL1–3

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

  1. L1
    intro m
  2. L2
    intro n
  3. L3
    intro hmodulus
02Use earlier factsL4–5

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

  1. L4
    specialize binary_canonical_residue_exists m
  2. L5
    specialize binary_canonical_residue_exists n
03Establish hexistsL6–8

Establish this local claim before using it. It is not an additional assumption. The following proof commands apply binary canonical residue exists.

  1. L6
    have hexists : exists r. (((exists ff_gap_binary_value. ff_gap_binary_value + S (r) = m) /\ (exists ff_left_binary_value_congruence ff_right_binary_value_congruence. (n) + m * ff_left_binary_value_congruence = (r) + m * ff_right_binary_value_congruence)))
  2. L7
    apply binary_canonical_residue_exists
  3. L8
    exact hmodulus
04Separate the logical casesL9–9

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

  1. L9
    cases hexists
05Construct an explicit witnessL10–10

Supply the displayed value, then prove that it has the required property.

  1. L10
    exists x
06Separate the logical casesL11–11

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

  1. L11
    split
07Use earlier factsL12–12

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

  1. L12
    exact hexists_witness
08Fix variables and assumptionsL13–14

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

  1. L13
    intro s
  2. L14
    intro hs
09Use earlier factsL15–21

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

  1. L15
    specialize binary_canonical_residue_functional m
  2. L16
    specialize binary_canonical_residue_functional n
  3. L17
    specialize binary_canonical_residue_functional x
  4. L18
    specialize binary_canonical_residue_functional s
  5. L19
    apply binary_canonical_residue_functional
  6. L20
    exact hexists_witness
  7. L21
    exact hs

Library-wide reading audit

Original defined command ledger · 21 lines
  1. 0001intro m
  2. 0002intro n
  3. 0003intro hmodulus
  4. 0004specialize binary_canonical_residue_exists m
  5. 0005specialize binary_canonical_residue_exists n
  6. 0006have hexists : exists r. (((exists ff_gap_binary_value. ff_gap_binary_value + S (r) = m) /\ (exists ff_left_binary_value_congruence ff_right_binary_value_congruence. (n) + m * ff_left_binary_value_congruence = (r) + m * ff_right_binary_value_congruence)))
  7. 0007apply binary_canonical_residue_exists
  8. 0008exact hmodulus
  9. 0009cases hexists
  10. 0010exists x
  11. 0011split
  12. 0012exact hexists_witness
  13. 0013intro s
  14. 0014intro hs
  15. 0015specialize binary_canonical_residue_functional m
  16. 0016specialize binary_canonical_residue_functional n
  17. 0017specialize binary_canonical_residue_functional x
  18. 0018specialize binary_canonical_residue_functional s
  19. 0019apply binary_canonical_residue_functional
  20. 0020exact hexists_witness
  21. 0021exact hs