FP002D

prime_field_zero_extended_inverse_exists

Alpha v34 independently verified · alpha_closed; checked-use authorized; not Stable

Totalize only the inverse table by recording zero at zero; the nonzero branch constructs a genuine inverse.

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 a. (~((p) = 1) /\ forall pfa_factor_left_zero_extended_domain pfa_factor_right_zero_extended_domain. (p) = pfa_factor_left_zero_extended_domain * pfa_factor_right_zero_extended_domain -> pfa_factor_left_zero_extended_domain = 1 \/ pfa_factor_right_zero_extended_domain = 1) -> (exists pfa_gap_zero_extended_bound. pfa_gap_zero_extended_bound + S (a) = (p)) -> exists b. (((exists pfa_gap_zero_extended_resultinput. pfa_gap_zero_extended_resultinput + S (a) = (p)) /\ (((exists pfa_gap_zero_extended_resultoutput. pfa_gap_zero_extended_resultoutput + S (b) = (p)) /\ ((((a) = 0 /\ (b) = 0) \/ (((~((a) = 0)) /\ ((((exists pfa_gap_zero_extended_resultnonzeromultiplicationleft. pfa_gap_zero_extended_resultnonzeromultiplicationleft + S (a) = (p)) /\ (((exists pfa_gap_zero_extended_resultnonzeromultiplicationright. pfa_gap_zero_extended_resultnonzeromultiplicationright + S (b) = (p)) /\ ((((exists pfa_gap_zero_extended_resultnonzeromultiplicationresultbound. pfa_gap_zero_extended_resultnonzeromultiplicationresultbound + S (1) = (p)) /\ ((exists pfa_offset_left_zero_extended_resultnonzeromultiplicationresultcongruence pfa_offset_right_zero_extended_resultnonzeromultiplicationresultcongruence. ((a) * (b)) + (p) * pfa_offset_left_zero_extended_resultnonzeromultiplicationresultcongruence = (1) + (p) * pfa_offset_right_zero_extended_resultnonzeromultiplicationresultcongruence))))))))))))))))))

Constructive proof overview

Generated structural guide

Totalize only the inverse table by recording zero at zero; the nonzero branch constructs a genuine inverse.

The unchanged tactic script uses 3 declared prerequisites and contains 38 exact native proof lines.

Alpha v34 checked-use · first admitted v31 · independently kernel and Lean verified; not Stable

Proof neighborhood

Direct dependencies

eq_decidable Stable theorem; checked-use authorized FP0002 prime_field_zero_below_prime FP001E prime_field_inverse_exists

Direct 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

38 script commands · 20 reading checkpoints · 2 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.

Named ingredients (2)

Long local formulas use this family’s existing definitions. Each new abbreviation was expanded back to the identical native formula, including its free-variable context. The original edition is preserved below.

01Fix variables and assumptionsL1–4

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

  1. L1
    intro p
  2. L2
    intro a
  3. L3
    intro hp
  4. L4
    intro ha
02Establish hcasesL5–8

Establish this local claim before using it. It is not an additional assumption. The following proof commands apply eq decidable.

  1. L5
    have hcases : a = 0 \/ ~(a = 0)
  2. L6
    specialize eq_decidable (a)
  3. L7
    specialize eq_decidable (0)
  4. L8
    apply eq_decidable
03Separate the logical casesL9–9

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

  1. L9
    cases hcases
04Construct an explicit witnessL10–10

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

  1. L10
    exists 0
05Separate the logical casesL11–11

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

  1. L11
    split
06Use earlier factsL12–12

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

  1. L12
    exact ha
07Separate the logical casesL13–13

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

  1. L13
    split
08Use earlier factsL14–16

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

  1. L14
    specialize prime_field_zero_below_prime (p)
  2. L15
    apply prime_field_zero_below_prime
  3. L16
    exact hp
09Separate the logical casesL17–18

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

  1. L17
    left
  2. L18
    split
10Use earlier factsL19–19

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

  1. L19
    exact hcases_left
11Calculate and transport equalitiesL20–20

Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.

  1. L20
    refl
12Establish hiL21–27

Establish this local claim before using it. It is not an additional assumption. The following proof commands apply prime field inverse exists.

  1. L21
    have hi : ∃ b. FpInv(p,a,b)Definitions: FpInv
  2. L22
    specialize prime_field_inverse_exists (p)
  3. L23
    specialize prime_field_inverse_exists (a)
  4. L24
    apply prime_field_inverse_exists
  5. L25
    exact hp
  6. L26
    exact ha
  7. L27
    exact hcases_right
13Separate the logical casesL28–28

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

  1. L28
    cases hi
14Construct an explicit witnessL29–29

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

  1. L29
    exists x
15Separate the logical casesL30–30

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

  1. L30
    split
16Use earlier factsL31–31

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

  1. L31
    exact ha
17Separate the logical casesL32–35

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

  1. L32
    split
  2. L33
    cases hi_witness
  3. L34
    cases hi_witness_right
  4. L35
    cases hi_witness_right_right
18Use earlier factsL36–36

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

  1. L36
    exact hi_witness_right_right_left
19Separate the logical casesL37–37

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

  1. L37
    right
20Use earlier factsL38–38

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

  1. L38
    exact hi_witness

Library-wide reading audit

Original exact command ledger · 38 lines
  1. 0001intro p
  2. 0002intro a
  3. 0003intro hp
  4. 0004intro ha
  5. 0005have hcases : a = 0 \/ ~(a = 0)
  6. 0006specialize eq_decidable (a)
  7. 0007specialize eq_decidable (0)
  8. 0008apply eq_decidable
  9. 0009cases hcases
  10. 0010exists 0
  11. 0011split
  12. 0012exact ha
  13. 0013split
  14. 0014specialize prime_field_zero_below_prime (p)
  15. 0015apply prime_field_zero_below_prime
  16. 0016exact hp
  17. 0017left
  18. 0018split
  19. 0019exact hcases_left
  20. 0020refl
  21. 0021have hi : exists b. (((~((a) = 0)) /\ ((((exists pfa_gap_zero_extended_inversemultiplicationleft. pfa_gap_zero_extended_inversemultiplicationleft + S (a) = (p)) /\ (((exists pfa_gap_zero_extended_inversemultiplicationright. pfa_gap_zero_extended_inversemultiplicationright + S (b) = (p)) /\ ((((exists pfa_gap_zero_extended_inversemultiplicationresultbound. pfa_gap_zero_extended_inversemultiplicationresultbound + S (1) = (p)) /\ ((exists pfa_offset_left_zero_extended_inversemultiplicationresultcongruence pfa_offset_right_zero_extended_inversemultiplicationresultcongruence. ((a) * (b)) + (p) * pfa_offset_left_zero_extended_inversemultiplicationresultcongruence = (1) + (p) * pfa_offset_right_zero_extended_inversemultiplicationresultcongruence))))))))))))
  22. 0022specialize prime_field_inverse_exists (p)
  23. 0023specialize prime_field_inverse_exists (a)
  24. 0024apply prime_field_inverse_exists
  25. 0025exact hp
  26. 0026exact ha
  27. 0027exact hcases_right
  28. 0028cases hi
  29. 0029exists x
  30. 0030split
  31. 0031exact ha
  32. 0032split
  33. 0033cases hi_witness
  34. 0034cases hi_witness_right
  35. 0035cases hi_witness_right_right
  36. 0036exact hi_witness_right_right_left
  37. 0037right
  38. 0038exact hi_witness