PF0010 · theorem body

pythagorean_odd_square_pair_two_mod_four

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

The sum of two witnessed odd squares has exact residue two modulo four.

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.

Statement with defined notation

∀ a. ∀ b. Odd(a)Odd(b) → ∃ x. a · a + b · b = 4 · x + 2

Every purple notation token opens its conservative definition. This reading surface never changes the unchanged intuitionistic kernel or confers checked-use authority.

Definitions used by this theorem

In the theorem statement

In local proof propositions

Exact expanded first-order statement
forall a b. (exists i. a = 2 * i + 1) -> (exists j. b = 2 * j + 1) -> exists q. a * a + b * b = 4 * q + 2

Proof neighborhood

Direct theorem prerequisites

odd_square_is_four_multiple_plus_one · Alpha closed mul_add · Stable closed add_assoc · Stable closed add_comm · Stable closed

Direct theorem dependents

Definition-aware tactic body

Only propositions whose conservative expansion has been checked for exact first-order equivalence are compacted. Every changed line retains its immutable exact replay command.

Read the argument

Proof checkpoints

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

Definition notation is shown below. Open the paired exact edition for the original native formulas. Source pairing is not a new equivalence certificate.

01Fix variables and assumptionsL1–4

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

  1. L1
    intro a
  2. L2
    intro b
  3. L3
    intro ha
  4. L4
    intro hb
02Separate the logical casesL5–6

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

  1. L5
    cases ha
  2. L6
    cases hb
03Establish hasquareL7–11

Establish this local claim before using it. It is not an additional assumption. The following proof commands apply odd square is four multiple plus one.

  1. L7
    have hasquare : Mod4One(a · a)Definitions: Mod4One(a · a)Original native command in the exact edition
  2. L8
    specialize odd_square_is_four_multiple_plus_one a
  3. L9
    specialize odd_square_is_four_multiple_plus_one x
  4. L10
    apply odd_square_is_four_multiple_plus_one
  5. L11
    exact ha_witness
04Establish hbsquareL12–16

Establish this local claim before using it. It is not an additional assumption. The following proof commands apply odd square is four multiple plus one.

  1. L12
    have hbsquare : Mod4One(b · b)Definitions: Mod4One(b · b)Original native command in the exact edition
  2. L13
    specialize odd_square_is_four_multiple_plus_one b
  3. L14
    specialize odd_square_is_four_multiple_plus_one x1
  4. L15
    apply odd_square_is_four_multiple_plus_one
  5. L16
    exact hb_witness
05Separate the logical casesL17–18

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

  1. L17
    cases hasquare
  2. L18
    cases hbsquare
06Construct an explicit witnessL19–19

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

  1. L19
    exists x2 + x3
07Calculate and transport equalitiesL20–22

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

  1. L20
    rewrite hasquare_witness
  2. L21
    rewrite hbsquare_witness
  3. L22
    simp [mul_add, add_assoc, add_comm]

Library-wide reading audit

Original defined command ledger · 22 lines
  1. 0001intro a
  2. 0002intro b
  3. 0003intro ha
  4. 0004intro hb
  5. 0005cases ha
  6. 0006cases hb
  7. 0007have hasquare : Mod4One(a · a)
    Exact native replay linehave hasquare : exists q. a * a = 4 * q + 1
  8. 0008specialize odd_square_is_four_multiple_plus_one a
  9. 0009specialize odd_square_is_four_multiple_plus_one x
  10. 0010apply odd_square_is_four_multiple_plus_one
  11. 0011exact ha_witness
  12. 0012have hbsquare : Mod4One(b · b)
    Exact native replay linehave hbsquare : exists q. b * b = 4 * q + 1
  13. 0013specialize odd_square_is_four_multiple_plus_one b
  14. 0014specialize odd_square_is_four_multiple_plus_one x1
  15. 0015apply odd_square_is_four_multiple_plus_one
  16. 0016exact hb_witness
  17. 0017cases hasquare
  18. 0018cases hbsquare
  19. 0019exists x2 + x3
  20. 0020rewrite hasquare_witness
  21. 0021rewrite hbsquare_witness
  22. 0022simp [mul_add, add_assoc, add_comm]