Current library: Alpha v34, 4,223 checked-use theorems; Stable remains 432. Historical first admissions, original proof editions, and non-admitted aliases are preserved.
Each statement retains its explicit modulus, coprimality and divisibility assumptions. These twelve arithmetic laws do not assert all order, primitive-root, Carmichael, exponential or simultaneous-polynomial congruence goals are finished.
Exact theorem in conservative defined notation
∀ p. ∀ a. ∀ A. Prime(p) → Pow(a,p,A) → ModEq(p,A,a)
Every linked abbreviation expands hygienically to the identical original native formula.
Definition DAG
Actual proof prerequisites
Complete tactic proof in conservative notation
All 83 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.
01Fix variables and assumptionsL1–5
02Establish hp0L6–11
03Establish hpsL12–15
04Separate the logical casesL16–16
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L16
cases hps
05Establish hdecompL17–24
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply pow successor decompose.
- L17
have hdecomp : ∃ r. Pow(a,x,r) ∧ A = r · aDefinitions: Pow(a,x,r)Original native command in the exact edition - L18
specialize pow_successor_decompose a - L19
specialize pow_successor_decompose x - L20
specialize pow_successor_decompose p - L21
specialize pow_successor_decompose A - L22
apply pow_successor_decompose - L23
exact hps_witness - L24
exact hpow
06Separate the logical casesL25–26
07Establish hsplitL27–31
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply prime coprime or divides.
- L27
have hsplit : Coprime(p,a) ∨ Dvd(p,a)Definitions: Coprime(p,a)Dvd(p,a)Original native command in the exact edition - L28
specialize prime_coprime_or_divides p - L29
specialize prime_coprime_or_divides a - L30
apply prime_coprime_or_divides - L31
exact hp
08Separate the logical casesL32–32
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L32
cases hsplit
09Establish hnotdivL33–34
Establish this local claim before using it. It is not an additional assumption.
10Establish hpdivL35–37
Establish this local claim before using it. It is not an additional assumption.
11Establish hponeL38–42
12Separate the logical casesL43–43
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L43
cases hp
13Use earlier factsL44–45
14Establish hprevL46–55
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply fermat predecessor exponent mod one.
- L46
- L47
specialize fermat_predecessor_exponent_mod_one p - L48
specialize fermat_predecessor_exponent_mod_one x - L49
specialize fermat_predecessor_exponent_mod_one a - L50
specialize fermat_predecessor_exponent_mod_one x1 - L51
apply fermat_predecessor_exponent_mod_one - L52
exact hps_witness - L53
exact hp - L54
exact hnotdiv - L55
exact hdecomp_witness_left
15Establish hscaledL56–65
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply mod eq mul right.
- L56
have hscaled : ModEq(p,x1 · a,1 · a)Definitions: ModEq(p,x1 · a,1 · a)Original native command in the exact edition - L57
specialize mod_eq_mul_right p - L58
specialize mod_eq_mul_right x1 - L59
specialize mod_eq_mul_right 1 - L60
specialize mod_eq_mul_right a - L61
apply mod_eq_mul_right - L62
exact hprev - L63
rewrite hdecomp_witness_right - L64
specialize one_mul a - L65
rewrite one_mul at hscaled
16Use earlier factsL66–66
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L66
exact hscaled
17Separate the logical casesL67–67
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L67
cases hsplit_right
18Establish hAdivL68–73
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply multiple mul left.
19Construct an explicit witnessL74–74
Supply the displayed value, then prove that it has the required property.
- L74
exists x2
20Use earlier factsL75–75
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L75
exact hsplit_right_witness
21Separate the logical casesL76–76
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L76
cases hAdiv
22Construct an explicit witnessL77–78
23Calculate and transport equalitiesL79–80
Original defined command ledger · 83 lines
- 0001
intro p - 0002
intro a - 0003
intro A - 0004
intro hp - 0005
intro hpow - 0006
have hp0 : ~(p = 0) - 0007
intro hpzero - 0008
specialize prime_nonzero p - 0009
apply prime_nonzero - 0010
exact hp - 0011
exact hpzero - 0012
have hps : exists n. p = S n - 0013
specialize nonzero_is_succ p - 0014
apply nonzero_is_succ - 0015
exact hp0 - 0016
cases hps - 0017
have hdecomp : ∃ r. Pow(a,x,r) ∧ A = r · a - 0018
specialize pow_successor_decompose a - 0019
specialize pow_successor_decompose x - 0020
specialize pow_successor_decompose p - 0021
specialize pow_successor_decompose A - 0022
apply pow_successor_decompose - 0023
exact hps_witness - 0024
exact hpow - 0025
cases hdecomp - 0026
cases hdecomp_witness - 0027
have hsplit : Coprime(p,a) ∨ Dvd(p,a) - 0028
specialize prime_coprime_or_divides p - 0029
specialize prime_coprime_or_divides a - 0030
apply prime_coprime_or_divides - 0031
exact hp - 0032
cases hsplit - 0033
have hnotdiv : ¬Dvd(p,a) - 0034
intro hdiv - 0035
have hpdiv : Dvd(p,p) - 0036
specialize multiple_refl p - 0037
exact multiple_refl - 0038
have hpone : p = 1 - 0039
specialize hsplit_left p - 0040
apply hsplit_left - 0041
exact hpdiv - 0042
exact hdiv - 0043
cases hp - 0044
apply hp_left - 0045
exact hpone - 0046
have hprev : ModEq(p,x1,1) - 0047
specialize fermat_predecessor_exponent_mod_one p - 0048
specialize fermat_predecessor_exponent_mod_one x - 0049
specialize fermat_predecessor_exponent_mod_one a - 0050
specialize fermat_predecessor_exponent_mod_one x1 - 0051
apply fermat_predecessor_exponent_mod_one - 0052
exact hps_witness - 0053
exact hp - 0054
exact hnotdiv - 0055
exact hdecomp_witness_left - 0056
have hscaled : ModEq(p,x1 · a,1 · a) - 0057
specialize mod_eq_mul_right p - 0058
specialize mod_eq_mul_right x1 - 0059
specialize mod_eq_mul_right 1 - 0060
specialize mod_eq_mul_right a - 0061
apply mod_eq_mul_right - 0062
exact hprev - 0063
rewrite hdecomp_witness_right - 0064
specialize one_mul a - 0065
rewrite one_mul at hscaled - 0066
exact hscaled - 0067
cases hsplit_right - 0068
have hAdiv : Dvd(p,A) - 0069
rewrite hdecomp_witness_right - 0070
specialize multiple_mul_left p - 0071
specialize multiple_mul_left a - 0072
specialize multiple_mul_left x1 - 0073
apply multiple_mul_left - 0074
exists x2 - 0075
exact hsplit_right_witness - 0076
cases hAdiv - 0077
exists x2 - 0078
exists x3 - 0079
rewrite hAdiv_witness - 0080
rewrite hsplit_right_witness - 0081
specialize add_comm (p * x3) - 0082
specialize add_comm (p * x2) - 0083
exact add_comm