Current library: Alpha v34, 4,223 checked-use theorems; Stable remains 432. Historical first admissions, original proof editions, and non-admitted aliases are preserved.
The input n is positive. Signed code 2 denotes +1, so the actual sum is +1 at n=1 and zero for n>1. The positive-values result permits arbitrary F(0), which the divisor mask excludes. Prime-square multiples contribute zero. Full G007 inversion is established in its separate family.
Exact theorem in conservative defined notation
∀ n. ∀ p. ∀ d. Prime(p) → ∃ x. DivisorPrimeToggle(n,p,d,x)
Every linked abbreviation expands hygienically to the identical original native formula.
Definition DAG
Actual proof prerequisites
Complete tactic proof in conservative notation
All 44 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.
Named ingredients (1)
01Fix variables and assumptionsL1–4
02Establish hzL5–8
03Separate the logical casesL9–9
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L9
cases hz
04Construct an explicit witnessL10–10
Supply the displayed value, then prove that it has the required property.
- L10
exists d
05Separate the logical casesL11–13
06Use earlier factsL14–14
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L14
exact hz_left
07Calculate and transport equalitiesL15–15
Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.
- L15
refl
08Establish hdL16–20
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply multiple decidable nonzero.
09Separate the logical casesL21–21
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L21
cases hd
10Establish heL22–30
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply prime factor toggle exists.
- L22
have he : ∃ e. PrimeFactorToggle(p,d,e)Definitions: PrimeFactorToggle(p,d,e)Original native command in the exact edition - L23
specialize prime_factor_toggle_exists (p) - L24
specialize prime_factor_toggle_exists (d) - L25
apply prime_factor_toggle_exists - L26
intro hzero - L27
specialize prime_nonzero (p) - L28
apply prime_nonzero - L29
exact hp - L30
exact hzero
11Separate the logical casesL31–31
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L31
cases he
12Construct an explicit witnessL32–32
Supply the displayed value, then prove that it has the required property.
- L32
exists x
13Separate the logical casesL33–34
14Use earlier factsL35–35
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L35
exact hz_right
15Separate the logical casesL36–36
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L36
split
16Use earlier factsL37–38
17Construct an explicit witnessL39–39
Supply the displayed value, then prove that it has the required property.
- L39
exists d
18Separate the logical casesL40–42
19Use earlier factsL43–43
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L43
exact hd_right
20Calculate and transport equalitiesL44–44
Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.
- L44
refl
Original defined command ledger · 44 lines
- 0001
intro n - 0002
intro p - 0003
intro d - 0004
intro hp - 0005
have hz : d=0 \/ ~(d=0) - 0006
specialize eq_decidable (d) - 0007
specialize eq_decidable (0) - 0008
apply eq_decidable - 0009
cases hz - 0010
exists d - 0011
right - 0012
split - 0013
left - 0014
exact hz_left - 0015
refl - 0016
have hd : Dvd(d,n) ∨ ¬Dvd(d,n) - 0017
specialize multiple_decidable_nonzero (d) - 0018
specialize multiple_decidable_nonzero (n) - 0019
apply multiple_decidable_nonzero - 0020
exact hz_right - 0021
cases hd - 0022
have he : ∃ e. PrimeFactorToggle(p,d,e) - 0023
specialize prime_factor_toggle_exists (p) - 0024
specialize prime_factor_toggle_exists (d) - 0025
apply prime_factor_toggle_exists - 0026
intro hzero - 0027
specialize prime_nonzero (p) - 0028
apply prime_nonzero - 0029
exact hp - 0030
exact hzero - 0031
cases he - 0032
exists x - 0033
left - 0034
split - 0035
exact hz_right - 0036
split - 0037
exact hd_left - 0038
exact he_witness - 0039
exists d - 0040
right - 0041
split - 0042
right - 0043
exact hd_right - 0044
refl