MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  pythagtriplem19 Structured version   Visualization version   GIF version

Theorem pythagtriplem19 16534
Description: Lemma for pythagtrip 16535. Introduce 𝑘 and remove the relative primality requirement. (Contributed by Scott Fenton, 18-Apr-2014.) (Revised by Mario Carneiro, 19-Apr-2014.)
Assertion
Ref Expression
pythagtriplem19 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ ∃𝑘 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
Distinct variable groups:   𝐴,𝑚,𝑛,𝑘   𝐵,𝑚,𝑛,𝑘   𝐶,𝑚,𝑛,𝑘

Proof of Theorem pythagtriplem19
StepHypRef Expression
1 gcdnncl 16214 . . . . 5 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℕ)
213adant3 1131 . . . 4 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℕ)
323ad2ant1 1132 . . 3 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐴 gcd 𝐵) ∈ ℕ)
4 nnz 12342 . . . . . . . . . . 11 (𝐴 ∈ ℕ → 𝐴 ∈ ℤ)
5 nnz 12342 . . . . . . . . . . 11 (𝐵 ∈ ℕ → 𝐵 ∈ ℤ)
6 gcddvds 16210 . . . . . . . . . . 11 ((𝐴 ∈ ℤ ∧ 𝐵 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵))
74, 5, 6syl2an 596 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵))
873adant3 1131 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵))
98simpld 495 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∥ 𝐴)
102nnzd 12425 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℤ)
112nnne0d 12023 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ≠ 0)
1243ad2ant1 1132 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐴 ∈ ℤ)
13 dvdsval2 15966 . . . . . . . . 9 (((𝐴 gcd 𝐵) ∈ ℤ ∧ (𝐴 gcd 𝐵) ≠ 0 ∧ 𝐴 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ↔ (𝐴 / (𝐴 gcd 𝐵)) ∈ ℤ))
1410, 11, 12, 13syl3anc 1370 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ↔ (𝐴 / (𝐴 gcd 𝐵)) ∈ ℤ))
159, 14mpbid 231 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 / (𝐴 gcd 𝐵)) ∈ ℤ)
16 nnre 11980 . . . . . . . . 9 (𝐴 ∈ ℕ → 𝐴 ∈ ℝ)
17163ad2ant1 1132 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐴 ∈ ℝ)
182nnred 11988 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℝ)
19 nngt0 12004 . . . . . . . . 9 (𝐴 ∈ ℕ → 0 < 𝐴)
20193ad2ant1 1132 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < 𝐴)
212nngt0d 12022 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < (𝐴 gcd 𝐵))
2217, 18, 20, 21divgt0d 11910 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < (𝐴 / (𝐴 gcd 𝐵)))
23 elnnz 12329 . . . . . . 7 ((𝐴 / (𝐴 gcd 𝐵)) ∈ ℕ ↔ ((𝐴 / (𝐴 gcd 𝐵)) ∈ ℤ ∧ 0 < (𝐴 / (𝐴 gcd 𝐵))))
2415, 22, 23sylanbrc 583 . . . . . 6 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 / (𝐴 gcd 𝐵)) ∈ ℕ)
25243ad2ant1 1132 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐴 / (𝐴 gcd 𝐵)) ∈ ℕ)
268simprd 496 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∥ 𝐵)
2753ad2ant2 1133 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐵 ∈ ℤ)
28 dvdsval2 15966 . . . . . . . . 9 (((𝐴 gcd 𝐵) ∈ ℤ ∧ (𝐴 gcd 𝐵) ≠ 0 ∧ 𝐵 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐵 ↔ (𝐵 / (𝐴 gcd 𝐵)) ∈ ℤ))
2910, 11, 27, 28syl3anc 1370 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐵 ↔ (𝐵 / (𝐴 gcd 𝐵)) ∈ ℤ))
3026, 29mpbid 231 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵 / (𝐴 gcd 𝐵)) ∈ ℤ)
31 nnre 11980 . . . . . . . . 9 (𝐵 ∈ ℕ → 𝐵 ∈ ℝ)
32313ad2ant2 1133 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐵 ∈ ℝ)
33 nngt0 12004 . . . . . . . . 9 (𝐵 ∈ ℕ → 0 < 𝐵)
34333ad2ant2 1133 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < 𝐵)
3532, 18, 34, 21divgt0d 11910 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < (𝐵 / (𝐴 gcd 𝐵)))
36 elnnz 12329 . . . . . . 7 ((𝐵 / (𝐴 gcd 𝐵)) ∈ ℕ ↔ ((𝐵 / (𝐴 gcd 𝐵)) ∈ ℤ ∧ 0 < (𝐵 / (𝐴 gcd 𝐵))))
3730, 35, 36sylanbrc 583 . . . . . 6 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵 / (𝐴 gcd 𝐵)) ∈ ℕ)
38373ad2ant1 1132 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐵 / (𝐴 gcd 𝐵)) ∈ ℕ)
39 dvdssq 16272 . . . . . . . . . . . . . . 15 (((𝐴 gcd 𝐵) ∈ ℤ ∧ 𝐴 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2)))
4010, 12, 39syl2anc 584 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2)))
41 dvdssq 16272 . . . . . . . . . . . . . . 15 (((𝐴 gcd 𝐵) ∈ ℤ ∧ 𝐵 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐵 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)))
4210, 27, 41syl2anc 584 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐵 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)))
4340, 42anbi12d 631 . . . . . . . . . . . . 13 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵) ↔ (((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2) ∧ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2))))
448, 43mpbid 231 . . . . . . . . . . . 12 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2) ∧ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)))
452nnsqcld 13959 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ∈ ℕ)
4645nnzd 12425 . . . . . . . . . . . . 13 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ∈ ℤ)
47 nnsqcl 13847 . . . . . . . . . . . . . . 15 (𝐴 ∈ ℕ → (𝐴↑2) ∈ ℕ)
48473ad2ant1 1132 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴↑2) ∈ ℕ)
4948nnzd 12425 . . . . . . . . . . . . 13 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴↑2) ∈ ℤ)
50 nnsqcl 13847 . . . . . . . . . . . . . . 15 (𝐵 ∈ ℕ → (𝐵↑2) ∈ ℕ)
51503ad2ant2 1133 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵↑2) ∈ ℕ)
5251nnzd 12425 . . . . . . . . . . . . 13 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵↑2) ∈ ℤ)
53 dvds2add 15999 . . . . . . . . . . . . 13 ((((𝐴 gcd 𝐵)↑2) ∈ ℤ ∧ (𝐴↑2) ∈ ℤ ∧ (𝐵↑2) ∈ ℤ) → ((((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2) ∧ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)) → ((𝐴 gcd 𝐵)↑2) ∥ ((𝐴↑2) + (𝐵↑2))))
5446, 49, 52, 53syl3anc 1370 . . . . . . . . . . . 12 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2) ∧ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)) → ((𝐴 gcd 𝐵)↑2) ∥ ((𝐴↑2) + (𝐵↑2))))
5544, 54mpd 15 . . . . . . . . . . 11 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ∥ ((𝐴↑2) + (𝐵↑2)))
5655adantr 481 . . . . . . . . . 10 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴 gcd 𝐵)↑2) ∥ ((𝐴↑2) + (𝐵↑2)))
57 simpr 485 . . . . . . . . . 10 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2))
5856, 57breqtrd 5100 . . . . . . . . 9 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴 gcd 𝐵)↑2) ∥ (𝐶↑2))
59 nnz 12342 . . . . . . . . . . . 12 (𝐶 ∈ ℕ → 𝐶 ∈ ℤ)
60593ad2ant3 1134 . . . . . . . . . . 11 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐶 ∈ ℤ)
61 dvdssq 16272 . . . . . . . . . . 11 (((𝐴 gcd 𝐵) ∈ ℤ ∧ 𝐶 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐶↑2)))
6210, 60, 61syl2anc 584 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐶↑2)))
6362adantr 481 . . . . . . . . 9 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐶↑2)))
6458, 63mpbird 256 . . . . . . . 8 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → (𝐴 gcd 𝐵) ∥ 𝐶)
65 dvdsval2 15966 . . . . . . . . . 10 (((𝐴 gcd 𝐵) ∈ ℤ ∧ (𝐴 gcd 𝐵) ≠ 0 ∧ 𝐶 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ (𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ))
6610, 11, 60, 65syl3anc 1370 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ (𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ))
6766adantr 481 . . . . . . . 8 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ (𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ))
6864, 67mpbid 231 . . . . . . 7 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → (𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ)
69 nnre 11980 . . . . . . . . . 10 (𝐶 ∈ ℕ → 𝐶 ∈ ℝ)
70693ad2ant3 1134 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐶 ∈ ℝ)
71 nngt0 12004 . . . . . . . . . 10 (𝐶 ∈ ℕ → 0 < 𝐶)
72713ad2ant3 1134 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < 𝐶)
7370, 18, 72, 21divgt0d 11910 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < (𝐶 / (𝐴 gcd 𝐵)))
7473adantr 481 . . . . . . 7 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → 0 < (𝐶 / (𝐴 gcd 𝐵)))
75 elnnz 12329 . . . . . . 7 ((𝐶 / (𝐴 gcd 𝐵)) ∈ ℕ ↔ ((𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ ∧ 0 < (𝐶 / (𝐴 gcd 𝐵))))
7668, 74, 75sylanbrc 583 . . . . . 6 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → (𝐶 / (𝐴 gcd 𝐵)) ∈ ℕ)
77763adant3 1131 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐶 / (𝐴 gcd 𝐵)) ∈ ℕ)
7848nncnd 11989 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴↑2) ∈ ℂ)
7951nncnd 11989 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵↑2) ∈ ℂ)
8045nncnd 11989 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ∈ ℂ)
8145nnne0d 12023 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ≠ 0)
8278, 79, 80, 81divdird 11789 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (((𝐴↑2) + (𝐵↑2)) / ((𝐴 gcd 𝐵)↑2)) = (((𝐴↑2) / ((𝐴 gcd 𝐵)↑2)) + ((𝐵↑2) / ((𝐴 gcd 𝐵)↑2))))
83823ad2ant1 1132 . . . . . 6 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (((𝐴↑2) + (𝐵↑2)) / ((𝐴 gcd 𝐵)↑2)) = (((𝐴↑2) / ((𝐴 gcd 𝐵)↑2)) + ((𝐵↑2) / ((𝐴 gcd 𝐵)↑2))))
84 nncn 11981 . . . . . . . . . 10 (𝐶 ∈ ℕ → 𝐶 ∈ ℂ)
85843ad2ant3 1134 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐶 ∈ ℂ)
862nncnd 11989 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℂ)
8785, 86, 11sqdivd 13877 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐶 / (𝐴 gcd 𝐵))↑2) = ((𝐶↑2) / ((𝐴 gcd 𝐵)↑2)))
88873ad2ant1 1132 . . . . . . 7 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ((𝐶 / (𝐴 gcd 𝐵))↑2) = ((𝐶↑2) / ((𝐴 gcd 𝐵)↑2)))
89 oveq1 7282 . . . . . . . 8 (((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) → (((𝐴↑2) + (𝐵↑2)) / ((𝐴 gcd 𝐵)↑2)) = ((𝐶↑2) / ((𝐴 gcd 𝐵)↑2)))
90893ad2ant2 1133 . . . . . . 7 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (((𝐴↑2) + (𝐵↑2)) / ((𝐴 gcd 𝐵)↑2)) = ((𝐶↑2) / ((𝐴 gcd 𝐵)↑2)))
9188, 90eqtr4d 2781 . . . . . 6 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ((𝐶 / (𝐴 gcd 𝐵))↑2) = (((𝐴↑2) + (𝐵↑2)) / ((𝐴 gcd 𝐵)↑2)))
92 nncn 11981 . . . . . . . . . 10 (𝐴 ∈ ℕ → 𝐴 ∈ ℂ)
93923ad2ant1 1132 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐴 ∈ ℂ)
9493, 86, 11sqdivd 13877 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 / (𝐴 gcd 𝐵))↑2) = ((𝐴↑2) / ((𝐴 gcd 𝐵)↑2)))
95 nncn 11981 . . . . . . . . . 10 (𝐵 ∈ ℕ → 𝐵 ∈ ℂ)
96953ad2ant2 1133 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐵 ∈ ℂ)
9796, 86, 11sqdivd 13877 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐵 / (𝐴 gcd 𝐵))↑2) = ((𝐵↑2) / ((𝐴 gcd 𝐵)↑2)))
9894, 97oveq12d 7293 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (((𝐴 / (𝐴 gcd 𝐵))↑2) + ((𝐵 / (𝐴 gcd 𝐵))↑2)) = (((𝐴↑2) / ((𝐴 gcd 𝐵)↑2)) + ((𝐵↑2) / ((𝐴 gcd 𝐵)↑2))))
99983ad2ant1 1132 . . . . . 6 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (((𝐴 / (𝐴 gcd 𝐵))↑2) + ((𝐵 / (𝐴 gcd 𝐵))↑2)) = (((𝐴↑2) / ((𝐴 gcd 𝐵)↑2)) + ((𝐵↑2) / ((𝐴 gcd 𝐵)↑2))))
10083, 91, 993eqtr4rd 2789 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (((𝐴 / (𝐴 gcd 𝐵))↑2) + ((𝐵 / (𝐴 gcd 𝐵))↑2)) = ((𝐶 / (𝐴 gcd 𝐵))↑2))
101 gcddiv 16259 . . . . . . . 8 (((𝐴 ∈ ℤ ∧ 𝐵 ∈ ℤ ∧ (𝐴 gcd 𝐵) ∈ ℕ) ∧ ((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵)) → ((𝐴 gcd 𝐵) / (𝐴 gcd 𝐵)) = ((𝐴 / (𝐴 gcd 𝐵)) gcd (𝐵 / (𝐴 gcd 𝐵))))
10212, 27, 2, 8, 101syl31anc 1372 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) / (𝐴 gcd 𝐵)) = ((𝐴 / (𝐴 gcd 𝐵)) gcd (𝐵 / (𝐴 gcd 𝐵))))
10386, 11dividd 11749 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) / (𝐴 gcd 𝐵)) = 1)
104102, 103eqtr3d 2780 . . . . . 6 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 / (𝐴 gcd 𝐵)) gcd (𝐵 / (𝐴 gcd 𝐵))) = 1)
1051043ad2ant1 1132 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ((𝐴 / (𝐴 gcd 𝐵)) gcd (𝐵 / (𝐴 gcd 𝐵))) = 1)
106 simp3 1137 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵)))
107 pythagtriplem18 16533 . . . . 5 ((((𝐴 / (𝐴 gcd 𝐵)) ∈ ℕ ∧ (𝐵 / (𝐴 gcd 𝐵)) ∈ ℕ ∧ (𝐶 / (𝐴 gcd 𝐵)) ∈ ℕ) ∧ (((𝐴 / (𝐴 gcd 𝐵))↑2) + ((𝐵 / (𝐴 gcd 𝐵))↑2)) = ((𝐶 / (𝐴 gcd 𝐵))↑2) ∧ (((𝐴 / (𝐴 gcd 𝐵)) gcd (𝐵 / (𝐴 gcd 𝐵))) = 1 ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵)))) → ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))))
10825, 38, 77, 100, 105, 106, 107syl312anc 1390 . . . 4 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))))
10993, 86, 11divcan2d 11753 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) = 𝐴)
110109eqcomd 2744 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))))
11196, 86, 11divcan2d 11753 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) = 𝐵)
112111eqcomd 2744 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))))
11385, 86, 11divcan2d 11753 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))) = 𝐶)
114113eqcomd 2744 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))))
115110, 112, 1143jca 1127 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵)))))
1161153ad2ant1 1132 . . . . . . 7 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵)))))
117 oveq2 7283 . . . . . . . . . 10 ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) → ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))))
118117eqeq2d 2749 . . . . . . . . 9 ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) → (𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) ↔ 𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2)))))
1191183ad2ant1 1132 . . . . . . . 8 (((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → (𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) ↔ 𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2)))))
120 oveq2 7283 . . . . . . . . . 10 ((𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) → ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))))
121120eqeq2d 2749 . . . . . . . . 9 ((𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) → (𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) ↔ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛)))))
1221213ad2ant2 1133 . . . . . . . 8 (((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → (𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) ↔ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛)))))
123 oveq2 7283 . . . . . . . . . 10 ((𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2)) → ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))) = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))
124123eqeq2d 2749 . . . . . . . . 9 ((𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2)) → (𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))) ↔ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2)))))
1251243ad2ant3 1134 . . . . . . . 8 (((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → (𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))) ↔ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2)))))
126119, 122, 1253anbi123d 1435 . . . . . . 7 (((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → ((𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵)))) ↔ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))))
127116, 126syl5ibcom 244 . . . . . 6 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))))
128127reximdv 3202 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (∃𝑚 ∈ ℕ ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → ∃𝑚 ∈ ℕ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))))
129128reximdv 3202 . . . 4 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))))
130108, 129mpd 15 . . 3 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2)))))
131 oveq1 7282 . . . . . . 7 (𝑘 = (𝐴 gcd 𝐵) → (𝑘 · ((𝑚↑2) − (𝑛↑2))) = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))))
132131eqeq2d 2749 . . . . . 6 (𝑘 = (𝐴 gcd 𝐵) → (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ↔ 𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2)))))
133 oveq1 7282 . . . . . . 7 (𝑘 = (𝐴 gcd 𝐵) → (𝑘 · (2 · (𝑚 · 𝑛))) = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))))
134133eqeq2d 2749 . . . . . 6 (𝑘 = (𝐴 gcd 𝐵) → (𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ↔ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛)))))
135 oveq1 7282 . . . . . . 7 (𝑘 = (𝐴 gcd 𝐵) → (𝑘 · ((𝑚↑2) + (𝑛↑2))) = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))
136135eqeq2d 2749 . . . . . 6 (𝑘 = (𝐴 gcd 𝐵) → (𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2))) ↔ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2)))))
137132, 134, 1363anbi123d 1435 . . . . 5 (𝑘 = (𝐴 gcd 𝐵) → ((𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))))
1381372rexbidv 3229 . . . 4 (𝑘 = (𝐴 gcd 𝐵) → (∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))))
139138rspcev 3561 . . 3 (((𝐴 gcd 𝐵) ∈ ℕ ∧ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))) → ∃𝑘 ∈ ℕ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
1403, 130, 139syl2anc 584 . 2 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ∃𝑘 ∈ ℕ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
141 rexcom 3234 . . 3 (∃𝑘 ∈ ℕ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ ∃𝑛 ∈ ℕ ∃𝑘 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
142 rexcom 3234 . . . 4 (∃𝑘 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ ∃𝑚 ∈ ℕ ∃𝑘 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
143142rexbii 3181 . . 3 (∃𝑛 ∈ ℕ ∃𝑘 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ ∃𝑘 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
144141, 143bitri 274 . 2 (∃𝑘 ∈ ℕ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ ∃𝑘 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
145140, 144sylib 217 1 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ ∃𝑘 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
Colors of variables: wff setvar class
Syntax hints:  ¬ wn 3  wi 4  wb 205  wa 396  w3a 1086   = wceq 1539  wcel 2106  wne 2943  wrex 3065   class class class wbr 5074  (class class class)co 7275  cc 10869  cr 10870  0cc0 10871  1c1 10872   + caddc 10874   · cmul 10876   < clt 11009  cmin 11205   / cdiv 11632  cn 11973  2c2 12028  cz 12319  cexp 13782  cdvds 15963   gcd cgcd 16201
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1798  ax-4 1812  ax-5 1913  ax-6 1971  ax-7 2011  ax-8 2108  ax-9 2116  ax-10 2137  ax-11 2154  ax-12 2171  ax-ext 2709  ax-sep 5223  ax-nul 5230  ax-pow 5288  ax-pr 5352  ax-un 7588  ax-cnex 10927  ax-resscn 10928  ax-1cn 10929  ax-icn 10930  ax-addcl 10931  ax-addrcl 10932  ax-mulcl 10933  ax-mulrcl 10934  ax-mulcom 10935  ax-addass 10936  ax-mulass 10937  ax-distr 10938  ax-i2m1 10939  ax-1ne0 10940  ax-1rid 10941  ax-rnegex 10942  ax-rrecex 10943  ax-cnre 10944  ax-pre-lttri 10945  ax-pre-lttrn 10946  ax-pre-ltadd 10947  ax-pre-mulgt0 10948  ax-pre-sup 10949
This theorem depends on definitions:  df-bi 206  df-an 397  df-or 845  df-3or 1087  df-3an 1088  df-tru 1542  df-fal 1552  df-ex 1783  df-nf 1787  df-sb 2068  df-mo 2540  df-eu 2569  df-clab 2716  df-cleq 2730  df-clel 2816  df-nfc 2889  df-ne 2944  df-nel 3050  df-ral 3069  df-rex 3070  df-rmo 3071  df-reu 3072  df-rab 3073  df-v 3434  df-sbc 3717  df-csb 3833  df-dif 3890  df-un 3892  df-in 3894  df-ss 3904  df-pss 3906  df-nul 4257  df-if 4460  df-pw 4535  df-sn 4562  df-pr 4564  df-op 4568  df-uni 4840  df-iun 4926  df-br 5075  df-opab 5137  df-mpt 5158  df-tr 5192  df-id 5489  df-eprel 5495  df-po 5503  df-so 5504  df-fr 5544  df-we 5546  df-xp 5595  df-rel 5596  df-cnv 5597  df-co 5598  df-dm 5599  df-rn 5600  df-res 5601  df-ima 5602  df-pred 6202  df-ord 6269  df-on 6270  df-lim 6271  df-suc 6272  df-iota 6391  df-fun 6435  df-fn 6436  df-f 6437  df-f1 6438  df-fo 6439  df-f1o 6440  df-fv 6441  df-riota 7232  df-ov 7278  df-oprab 7279  df-mpo 7280  df-om 7713  df-1st 7831  df-2nd 7832  df-frecs 8097  df-wrecs 8128  df-recs 8202  df-rdg 8241  df-1o 8297  df-2o 8298  df-er 8498  df-en 8734  df-dom 8735  df-sdom 8736  df-fin 8737  df-sup 9201  df-inf 9202  df-pnf 11011  df-mnf 11012  df-xr 11013  df-ltxr 11014  df-le 11015  df-sub 11207  df-neg 11208  df-div 11633  df-nn 11974  df-2 12036  df-3 12037  df-n0 12234  df-z 12320  df-uz 12583  df-rp 12731  df-fz 13240  df-fl 13512  df-mod 13590  df-seq 13722  df-exp 13783  df-cj 14810  df-re 14811  df-im 14812  df-sqrt 14946  df-abs 14947  df-dvds 15964  df-gcd 16202  df-prm 16377
This theorem is referenced by:  pythagtrip  16535
  Copyright terms: Public domain W3C validator