PE0006

least_prime_above_exists_unique

Least-prime search is a total, uniquely valued constructive relation for every natural input.

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.

Every successor is the globally least prime above its predecessor. This is not a sparse Bertrand chain. The bound theorem constructs the list and both power witnesses from k≠0 alone; the separate total-list theorem includes k=0.

Exact theorem in conservative defined notation

∀ a. ∃ p. NextPrime(a,p) ∧ (∀ x. NextPrime(a,x) → x = p)

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

Definition DAG

Actual proof prerequisites

Original expanded first-order statement
forall a. exists p. (((~(p = 1) /\ forall bpr_left_pc_pen_unique_exists_prime bpr_right_pc_pen_unique_exists_prime. p = bpr_left_pc_pen_unique_exists_prime * bpr_right_pc_pen_unique_exists_prime -> bpr_left_pc_pen_unique_exists_prime = 1 \/ bpr_right_pc_pen_unique_exists_prime = 1)) /\ ((exists pc_lt_pen_unique_exists_greater. pc_lt_pen_unique_exists_greater + S (a) = (p)) /\ forall pen_comparison_unique_exists. ((~(pen_comparison_unique_exists = 1) /\ forall bpr_left_pc_pen_unique_exists_comparison bpr_right_pc_pen_unique_exists_comparison. pen_comparison_unique_exists = bpr_left_pc_pen_unique_exists_comparison * bpr_right_pc_pen_unique_exists_comparison -> bpr_left_pc_pen_unique_exists_comparison = 1 \/ bpr_right_pc_pen_unique_exists_comparison = 1)) -> (exists pc_lt_pen_unique_exists_above. pc_lt_pen_unique_exists_above + S (a) = (pen_comparison_unique_exists)) -> (exists pc_le_pen_unique_exists_minimal. pc_le_pen_unique_exists_minimal + (p) = (pen_comparison_unique_exists)))) /\ forall q. (((~(q = 1) /\ forall bpr_left_pc_pen_unique_exists_other_prime bpr_right_pc_pen_unique_exists_other_prime. q = bpr_left_pc_pen_unique_exists_other_prime * bpr_right_pc_pen_unique_exists_other_prime -> bpr_left_pc_pen_unique_exists_other_prime = 1 \/ bpr_right_pc_pen_unique_exists_other_prime = 1)) /\ ((exists pc_lt_pen_unique_exists_other_greater. pc_lt_pen_unique_exists_other_greater + S (a) = (q)) /\ forall pen_comparison_unique_exists_other. ((~(pen_comparison_unique_exists_other = 1) /\ forall bpr_left_pc_pen_unique_exists_other_comparison bpr_right_pc_pen_unique_exists_other_comparison. pen_comparison_unique_exists_other = bpr_left_pc_pen_unique_exists_other_comparison * bpr_right_pc_pen_unique_exists_other_comparison -> bpr_left_pc_pen_unique_exists_other_comparison = 1 \/ bpr_right_pc_pen_unique_exists_other_comparison = 1)) -> (exists pc_lt_pen_unique_exists_other_above. pc_lt_pen_unique_exists_other_above + S (a) = (pen_comparison_unique_exists_other)) -> (exists pc_le_pen_unique_exists_other_minimal. pc_le_pen_unique_exists_other_minimal + (q) = (pen_comparison_unique_exists_other)))) -> q = p

Complete tactic proof in conservative notation

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

14 script commands · 8 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.

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

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

  1. L1
    intro a
02Use earlier factsL2–2

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

  1. L2
    specialize least_prime_above_exists a
03Separate the logical casesL3–3

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

  1. L3
    cases least_prime_above_exists
04Construct an explicit witnessL4–4

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

  1. L4
    exists x
05Separate the logical casesL5–5

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

  1. L5
    split
06Use earlier factsL6–6

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

  1. L6
    exact least_prime_above_exists_witness
07Fix variables and assumptionsL7–8

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

  1. L7
    intro q
  2. L8
    intro hq
08Use earlier factsL9–14

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

  1. L9
    specialize least_prime_above_unique a
  2. L10
    specialize least_prime_above_unique q
  3. L11
    specialize least_prime_above_unique x
  4. L12
    apply least_prime_above_unique
  5. L13
    exact hq
  6. L14
    exact least_prime_above_exists_witness

Library-wide reading audit

Original defined command ledger · 14 lines
  1. 0001intro a
  2. 0002specialize least_prime_above_exists a
  3. 0003cases least_prime_above_exists
  4. 0004exists x
  5. 0005split
  6. 0006exact least_prime_above_exists_witness
  7. 0007intro q
  8. 0008intro hq
  9. 0009specialize least_prime_above_unique a
  10. 0010specialize least_prime_above_unique q
  11. 0011specialize least_prime_above_unique x
  12. 0012apply least_prime_above_unique
  13. 0013exact hq
  14. 0014exact least_prime_above_exists_witness