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 expanded first-order arithmetic statement
forall p n t a r s. (~((p) = 1) /\ forall pfa_factor_left_step_prime pfa_factor_right_step_prime. (p) = pfa_factor_left_step_prime * pfa_factor_right_step_prime -> pfa_factor_left_step_prime = 1 \/ pfa_factor_right_step_prime = 1) -> (exists pfa_gap_step_base. pfa_gap_step_base + S (t) = (p)) -> (exists pfa_gap_step_coefficient. pfa_gap_step_coefficient + S (a) = (p)) -> (((exists pfa_gap_step_previousbound. pfa_gap_step_previousbound + S (r) = (p)) /\ ((exists pfa_offset_left_step_previouscongruence pfa_offset_right_step_previouscongruence. (n) + (p) * pfa_offset_left_step_previouscongruence = (r) + (p) * pfa_offset_right_step_previouscongruence)))) -> (((exists pfa_gap_step_nextbound. pfa_gap_step_nextbound + S (s) = (p)) /\ ((exists pfa_offset_left_step_nextcongruence pfa_offset_right_step_nextcongruence. (n*t+a) + (p) * pfa_offset_left_step_nextcongruence = (s) + (p) * pfa_offset_right_step_nextcongruence)))) -> exists k. ((((exists pfa_gap_step_productleft. pfa_gap_step_productleft + S (r) = (p)) /\ (((exists pfa_gap_step_productright. pfa_gap_step_productright + S (t) = (p)) /\ ((((exists pfa_gap_step_productresultbound. pfa_gap_step_productresultbound + S (k) = (p)) /\ ((exists pfa_offset_left_step_productresultcongruence pfa_offset_right_step_productresultcongruence. ((r) * (t)) + (p) * pfa_offset_left_step_productresultcongruence = (k) + (p) * pfa_offset_right_step_productresultcongruence))))))))) /\ ((((exists pfa_gap_step_sumleft. pfa_gap_step_sumleft + S (k) = (p)) /\ (((exists pfa_gap_step_sumright. pfa_gap_step_sumright + S (a) = (p)) /\ ((((exists pfa_gap_step_sumresultbound. pfa_gap_step_sumresultbound + S (s) = (p)) /\ ((exists pfa_offset_left_step_sumresultcongruence pfa_offset_right_step_sumresultcongruence. ((k) + (a)) + (p) * pfa_offset_left_step_sumresultcongruence = (s) + (p) * pfa_offset_right_step_sumresultcongruence)))))))))))Constructive proof overview
Generated structural guide
Construct an actual canonical multiply-then-add step from proved residues of the corresponding natural step.
The unchanged tactic script uses 6 declared prerequisites and contains 79 exact native proof lines.
Alpha v34 checked-use · first admitted v31 · independently kernel and Lean verified; not Stable
Proof neighborhood
Direct dependencies
prime_field_multiply_exists Alpha theorem; checked-use authorized prime_field_add_exists Alpha theorem; checked-use authorized prime_field_residue_multiply Alpha theorem; checked-use authorized prime_field_residue_add Alpha theorem; checked-use authorized prime_field_residue_reflexive Alpha theorem; checked-use authorized binary_canonical_residue_functional Alpha theorem; checked-use authorizedDirect dependents
Formal native tactic body
Dependencies are introduced as named hypotheses before line 1. Local theorem links identify exact declared prerequisites. This exact body belongs to a complete independently kernel-checked constructive proof bundle and has Alpha checked-use authority; it does not imply Stable membership.
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–10
02Fix variables and assumptionsL11–11
Work with arbitrary variables or the premises of the current implication.
- L11
intro hs
03Establish hrcopyL12–13
Establish this local claim before using it. It is not an additional assumption.
- L12
have hrcopy : ((exists pfa_gap_step_previous_copybound. pfa_gap_step_previous_copybound + S (r) = (p)) /\ ((exists pfa_offset_left_step_previous_copycongruence pfa_offset_right_step_previous_copycongruence. (n) + (p) * pfa_offset_left_step_previous_copycongruence = (r) + (p) * pfa_offset_right_step_previous_copycongruence))) - L13
exact hr
04Separate the logical casesL14–14
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L14
cases hrcopy
05Establish hmL15–22
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply prime field multiply exists.
- L15
have hm : exists k. (((exists pfa_gap_step_chosen_productleft. pfa_gap_step_chosen_productleft + S (r) = (p)) /\ (((exists pfa_gap_step_chosen_productright. pfa_gap_step_chosen_productright + S (t) = (p)) /\ ((((exists pfa_gap_step_chosen_productresultbound. pfa_gap_step_chosen_productresultbound + S (k) = (p)) /\ ((exists pfa_offset_left_step_chosen_productresultcongruence pfa_offset_right_step_chosen_productresultcongruence. ((r) * (t)) + (p) * pfa_offset_left_step_chosen_productresultcongruence = (k) + (p) * pfa_offset_right_step_chosen_productresultcongruence))))))))) - L16
specialize prime_field_multiply_exists (p) - L17
specialize prime_field_multiply_exists (r) - L18
specialize prime_field_multiply_exists (t) - L19
apply prime_field_multiply_exists - L20
exact hp - L21
exact hrcopy_left - L22
exact ht
06Separate the logical casesL23–23
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L23
cases hm
07Establish hmcopyL24–25
Establish this local claim before using it. It is not an additional assumption.
- L24
have hmcopy : ((exists pfa_gap_step_product_copyleft. pfa_gap_step_product_copyleft + S (r) = (p)) /\ (((exists pfa_gap_step_product_copyright. pfa_gap_step_product_copyright + S (t) = (p)) /\ ((((exists pfa_gap_step_product_copyresultbound. pfa_gap_step_product_copyresultbound + S (x) = (p)) /\ ((exists pfa_offset_left_step_product_copyresultcongruence pfa_offset_right_step_product_copyresultcongruence. ((r) * (t)) + (p) * pfa_offset_left_step_product_copyresultcongruence = (x) + (p) * pfa_offset_right_step_product_copyresultcongruence)))))))) - L25
exact hm_witness
08Separate the logical casesL26–28
09Establish haddL29–36
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply prime field add exists.
- L29
have hadd : exists z. (((exists pfa_gap_step_chosen_sumleft. pfa_gap_step_chosen_sumleft + S (x) = (p)) /\ (((exists pfa_gap_step_chosen_sumright. pfa_gap_step_chosen_sumright + S (a) = (p)) /\ ((((exists pfa_gap_step_chosen_sumresultbound. pfa_gap_step_chosen_sumresultbound + S (z) = (p)) /\ ((exists pfa_offset_left_step_chosen_sumresultcongruence pfa_offset_right_step_chosen_sumresultcongruence. ((x) + (a)) + (p) * pfa_offset_left_step_chosen_sumresultcongruence = (z) + (p) * pfa_offset_right_step_chosen_sumresultcongruence))))))))) - L30
specialize prime_field_add_exists (p) - L31
specialize prime_field_add_exists (x) - L32
specialize prime_field_add_exists (a) - L33
apply prime_field_add_exists - L34
exact hp - L35
exact hmcopy_right_right_left - L36
exact ha
10Separate the logical casesL37–37
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L37
cases hadd
11Establish hmulresL38–47
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply prime field residue multiply.
- L38
have hmulres : ((exists pfa_gap_step_product_residuebound. pfa_gap_step_product_residuebound + S (x) = (p)) /\ ((exists pfa_offset_left_step_product_residuecongruence pfa_offset_right_step_product_residuecongruence. (n*t) + (p) * pfa_offset_left_step_product_residuecongruence = (x) + (p) * pfa_offset_right_step_product_residuecongruence))) - L39
specialize prime_field_residue_multiply (p) - L40
specialize prime_field_residue_multiply (n) - L41
specialize prime_field_residue_multiply (t) - L42
specialize prime_field_residue_multiply (r) - L43
specialize prime_field_residue_multiply (t) - L44
specialize prime_field_residue_multiply (x) - L45
apply prime_field_residue_multiply - L46
exact hr - L47
specialize prime_field_residue_reflexive (p)
12Use earlier factsL48–51
13Establish hsumresL52–61
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply prime field residue add.
- L52
have hsumres : ((exists pfa_gap_step_sum_residuebound. pfa_gap_step_sum_residuebound + S (x1) = (p)) /\ ((exists pfa_offset_left_step_sum_residuecongruence pfa_offset_right_step_sum_residuecongruence. (n*t+a) + (p) * pfa_offset_left_step_sum_residuecongruence = (x1) + (p) * pfa_offset_right_step_sum_residuecongruence))) - L53
specialize prime_field_residue_add (p) - L54
specialize prime_field_residue_add (n*t) - L55
specialize prime_field_residue_add (a) - L56
specialize prime_field_residue_add (x) - L57
specialize prime_field_residue_add (a) - L58
specialize prime_field_residue_add (x1) - L59
apply prime_field_residue_add - L60
exact hmulres - L61
specialize prime_field_residue_reflexive (p)
14Use earlier factsL62–65
15Establish heqL66–73
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply binary canonical residue functional.
- L66
have heq : x1=s - L67
specialize binary_canonical_residue_functional (p) - L68
specialize binary_canonical_residue_functional (n*t+a) - L69
specialize binary_canonical_residue_functional (x1) - L70
specialize binary_canonical_residue_functional (s) - L71
apply binary_canonical_residue_functional - L72
exact hsumres - L73
exact hs
16Construct an explicit witnessL74–74
Supply the displayed value, then prove that it has the required property.
- L74
exists x
17Separate the logical casesL75–75
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L75
split
18Use earlier factsL76–76
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L76
exact hm_witness
19Calculate and transport equalitiesL77–78
20Use earlier factsL79–79
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L79
exact hadd_witness
Original exact command ledger · 79 lines
- 0001
intro p - 0002
intro n - 0003
intro t - 0004
intro a - 0005
intro r - 0006
intro s - 0007
intro hp - 0008
intro ht - 0009
intro ha - 0010
intro hr - 0011
intro hs - 0012
have hrcopy : ((exists pfa_gap_step_previous_copybound. pfa_gap_step_previous_copybound + S (r) = (p)) /\ ((exists pfa_offset_left_step_previous_copycongruence pfa_offset_right_step_previous_copycongruence. (n) + (p) * pfa_offset_left_step_previous_copycongruence = (r) + (p) * pfa_offset_right_step_previous_copycongruence))) - 0013
exact hr - 0014
cases hrcopy - 0015
have hm : exists k. (((exists pfa_gap_step_chosen_productleft. pfa_gap_step_chosen_productleft + S (r) = (p)) /\ (((exists pfa_gap_step_chosen_productright. pfa_gap_step_chosen_productright + S (t) = (p)) /\ ((((exists pfa_gap_step_chosen_productresultbound. pfa_gap_step_chosen_productresultbound + S (k) = (p)) /\ ((exists pfa_offset_left_step_chosen_productresultcongruence pfa_offset_right_step_chosen_productresultcongruence. ((r) * (t)) + (p) * pfa_offset_left_step_chosen_productresultcongruence = (k) + (p) * pfa_offset_right_step_chosen_productresultcongruence))))))))) - 0016
specialize prime_field_multiply_exists (p) - 0017
specialize prime_field_multiply_exists (r) - 0018
specialize prime_field_multiply_exists (t) - 0019
apply prime_field_multiply_exists - 0020
exact hp - 0021
exact hrcopy_left - 0022
exact ht - 0023
cases hm - 0024
have hmcopy : ((exists pfa_gap_step_product_copyleft. pfa_gap_step_product_copyleft + S (r) = (p)) /\ (((exists pfa_gap_step_product_copyright. pfa_gap_step_product_copyright + S (t) = (p)) /\ ((((exists pfa_gap_step_product_copyresultbound. pfa_gap_step_product_copyresultbound + S (x) = (p)) /\ ((exists pfa_offset_left_step_product_copyresultcongruence pfa_offset_right_step_product_copyresultcongruence. ((r) * (t)) + (p) * pfa_offset_left_step_product_copyresultcongruence = (x) + (p) * pfa_offset_right_step_product_copyresultcongruence)))))))) - 0025
exact hm_witness - 0026
cases hmcopy - 0027
cases hmcopy_right - 0028
cases hmcopy_right_right - 0029
have hadd : exists z. (((exists pfa_gap_step_chosen_sumleft. pfa_gap_step_chosen_sumleft + S (x) = (p)) /\ (((exists pfa_gap_step_chosen_sumright. pfa_gap_step_chosen_sumright + S (a) = (p)) /\ ((((exists pfa_gap_step_chosen_sumresultbound. pfa_gap_step_chosen_sumresultbound + S (z) = (p)) /\ ((exists pfa_offset_left_step_chosen_sumresultcongruence pfa_offset_right_step_chosen_sumresultcongruence. ((x) + (a)) + (p) * pfa_offset_left_step_chosen_sumresultcongruence = (z) + (p) * pfa_offset_right_step_chosen_sumresultcongruence))))))))) - 0030
specialize prime_field_add_exists (p) - 0031
specialize prime_field_add_exists (x) - 0032
specialize prime_field_add_exists (a) - 0033
apply prime_field_add_exists - 0034
exact hp - 0035
exact hmcopy_right_right_left - 0036
exact ha - 0037
cases hadd - 0038
have hmulres : ((exists pfa_gap_step_product_residuebound. pfa_gap_step_product_residuebound + S (x) = (p)) /\ ((exists pfa_offset_left_step_product_residuecongruence pfa_offset_right_step_product_residuecongruence. (n*t) + (p) * pfa_offset_left_step_product_residuecongruence = (x) + (p) * pfa_offset_right_step_product_residuecongruence))) - 0039
specialize prime_field_residue_multiply (p) - 0040
specialize prime_field_residue_multiply (n) - 0041
specialize prime_field_residue_multiply (t) - 0042
specialize prime_field_residue_multiply (r) - 0043
specialize prime_field_residue_multiply (t) - 0044
specialize prime_field_residue_multiply (x) - 0045
apply prime_field_residue_multiply - 0046
exact hr - 0047
specialize prime_field_residue_reflexive (p) - 0048
specialize prime_field_residue_reflexive (t) - 0049
apply prime_field_residue_reflexive - 0050
exact ht - 0051
exact hm_witness - 0052
have hsumres : ((exists pfa_gap_step_sum_residuebound. pfa_gap_step_sum_residuebound + S (x1) = (p)) /\ ((exists pfa_offset_left_step_sum_residuecongruence pfa_offset_right_step_sum_residuecongruence. (n*t+a) + (p) * pfa_offset_left_step_sum_residuecongruence = (x1) + (p) * pfa_offset_right_step_sum_residuecongruence))) - 0053
specialize prime_field_residue_add (p) - 0054
specialize prime_field_residue_add (n*t) - 0055
specialize prime_field_residue_add (a) - 0056
specialize prime_field_residue_add (x) - 0057
specialize prime_field_residue_add (a) - 0058
specialize prime_field_residue_add (x1) - 0059
apply prime_field_residue_add - 0060
exact hmulres - 0061
specialize prime_field_residue_reflexive (p) - 0062
specialize prime_field_residue_reflexive (a) - 0063
apply prime_field_residue_reflexive - 0064
exact ha - 0065
exact hadd_witness - 0066
have heq : x1=s - 0067
specialize binary_canonical_residue_functional (p) - 0068
specialize binary_canonical_residue_functional (n*t+a) - 0069
specialize binary_canonical_residue_functional (x1) - 0070
specialize binary_canonical_residue_functional (s) - 0071
apply binary_canonical_residue_functional - 0072
exact hsumres - 0073
exact hs - 0074
exists x - 0075
split - 0076
exact hm_witness - 0077
rewrite heq at hadd_witness - 0078
rewrite heq at hadd_witness - 0079
exact hadd_witness