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

Theorem pythagtriplem19 16462
Description: Lemma for pythagtrip 16463. 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 16142 . . . . 5 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℕ)
213adant3 1130 . . . 4 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℕ)
323ad2ant1 1131 . . 3 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐴 gcd 𝐵) ∈ ℕ)
4 nnz 12272 . . . . . . . . . . 11 (𝐴 ∈ ℕ → 𝐴 ∈ ℤ)
5 nnz 12272 . . . . . . . . . . 11 (𝐵 ∈ ℕ → 𝐵 ∈ ℤ)
6 gcddvds 16138 . . . . . . . . . . 11 ((𝐴 ∈ ℤ ∧ 𝐵 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵))
74, 5, 6syl2an 595 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵))
873adant3 1130 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵))
98simpld 494 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∥ 𝐴)
102nnzd 12354 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℤ)
112nnne0d 11953 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ≠ 0)
1243ad2ant1 1131 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐴 ∈ ℤ)
13 dvdsval2 15894 . . . . . . . . 9 (((𝐴 gcd 𝐵) ∈ ℤ ∧ (𝐴 gcd 𝐵) ≠ 0 ∧ 𝐴 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ↔ (𝐴 / (𝐴 gcd 𝐵)) ∈ ℤ))
1410, 11, 12, 13syl3anc 1369 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ↔ (𝐴 / (𝐴 gcd 𝐵)) ∈ ℤ))
159, 14mpbid 231 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 / (𝐴 gcd 𝐵)) ∈ ℤ)
16 nnre 11910 . . . . . . . . 9 (𝐴 ∈ ℕ → 𝐴 ∈ ℝ)
17163ad2ant1 1131 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐴 ∈ ℝ)
182nnred 11918 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℝ)
19 nngt0 11934 . . . . . . . . 9 (𝐴 ∈ ℕ → 0 < 𝐴)
20193ad2ant1 1131 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < 𝐴)
212nngt0d 11952 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < (𝐴 gcd 𝐵))
2217, 18, 20, 21divgt0d 11840 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < (𝐴 / (𝐴 gcd 𝐵)))
23 elnnz 12259 . . . . . . 7 ((𝐴 / (𝐴 gcd 𝐵)) ∈ ℕ ↔ ((𝐴 / (𝐴 gcd 𝐵)) ∈ ℤ ∧ 0 < (𝐴 / (𝐴 gcd 𝐵))))
2415, 22, 23sylanbrc 582 . . . . . 6 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 / (𝐴 gcd 𝐵)) ∈ ℕ)
25243ad2ant1 1131 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐴 / (𝐴 gcd 𝐵)) ∈ ℕ)
268simprd 495 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∥ 𝐵)
2753ad2ant2 1132 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐵 ∈ ℤ)
28 dvdsval2 15894 . . . . . . . . 9 (((𝐴 gcd 𝐵) ∈ ℤ ∧ (𝐴 gcd 𝐵) ≠ 0 ∧ 𝐵 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐵 ↔ (𝐵 / (𝐴 gcd 𝐵)) ∈ ℤ))
2910, 11, 27, 28syl3anc 1369 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐵 ↔ (𝐵 / (𝐴 gcd 𝐵)) ∈ ℤ))
3026, 29mpbid 231 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵 / (𝐴 gcd 𝐵)) ∈ ℤ)
31 nnre 11910 . . . . . . . . 9 (𝐵 ∈ ℕ → 𝐵 ∈ ℝ)
32313ad2ant2 1132 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐵 ∈ ℝ)
33 nngt0 11934 . . . . . . . . 9 (𝐵 ∈ ℕ → 0 < 𝐵)
34333ad2ant2 1132 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < 𝐵)
3532, 18, 34, 21divgt0d 11840 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < (𝐵 / (𝐴 gcd 𝐵)))
36 elnnz 12259 . . . . . . 7 ((𝐵 / (𝐴 gcd 𝐵)) ∈ ℕ ↔ ((𝐵 / (𝐴 gcd 𝐵)) ∈ ℤ ∧ 0 < (𝐵 / (𝐴 gcd 𝐵))))
3730, 35, 36sylanbrc 582 . . . . . 6 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵 / (𝐴 gcd 𝐵)) ∈ ℕ)
38373ad2ant1 1131 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐵 / (𝐴 gcd 𝐵)) ∈ ℕ)
39 dvdssq 16200 . . . . . . . . . . . . . . 15 (((𝐴 gcd 𝐵) ∈ ℤ ∧ 𝐴 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2)))
4010, 12, 39syl2anc 583 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐴 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2)))
41 dvdssq 16200 . . . . . . . . . . . . . . 15 (((𝐴 gcd 𝐵) ∈ ℤ ∧ 𝐵 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐵 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)))
4210, 27, 41syl2anc 583 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐵 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)))
4340, 42anbi12d 630 . . . . . . . . . . . . 13 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵) ↔ (((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2) ∧ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2))))
448, 43mpbid 231 . . . . . . . . . . . 12 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2) ∧ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)))
452nnsqcld 13887 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ∈ ℕ)
4645nnzd 12354 . . . . . . . . . . . . 13 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ∈ ℤ)
47 nnsqcl 13775 . . . . . . . . . . . . . . 15 (𝐴 ∈ ℕ → (𝐴↑2) ∈ ℕ)
48473ad2ant1 1131 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴↑2) ∈ ℕ)
4948nnzd 12354 . . . . . . . . . . . . 13 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴↑2) ∈ ℤ)
50 nnsqcl 13775 . . . . . . . . . . . . . . 15 (𝐵 ∈ ℕ → (𝐵↑2) ∈ ℕ)
51503ad2ant2 1132 . . . . . . . . . . . . . 14 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵↑2) ∈ ℕ)
5251nnzd 12354 . . . . . . . . . . . . 13 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵↑2) ∈ ℤ)
53 dvds2add 15927 . . . . . . . . . . . . 13 ((((𝐴 gcd 𝐵)↑2) ∈ ℤ ∧ (𝐴↑2) ∈ ℤ ∧ (𝐵↑2) ∈ ℤ) → ((((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2) ∧ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)) → ((𝐴 gcd 𝐵)↑2) ∥ ((𝐴↑2) + (𝐵↑2))))
5446, 49, 52, 53syl3anc 1369 . . . . . . . . . . . 12 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((((𝐴 gcd 𝐵)↑2) ∥ (𝐴↑2) ∧ ((𝐴 gcd 𝐵)↑2) ∥ (𝐵↑2)) → ((𝐴 gcd 𝐵)↑2) ∥ ((𝐴↑2) + (𝐵↑2))))
5544, 54mpd 15 . . . . . . . . . . 11 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ∥ ((𝐴↑2) + (𝐵↑2)))
5655adantr 480 . . . . . . . . . 10 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴 gcd 𝐵)↑2) ∥ ((𝐴↑2) + (𝐵↑2)))
57 simpr 484 . . . . . . . . . 10 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2))
5856, 57breqtrd 5096 . . . . . . . . 9 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴 gcd 𝐵)↑2) ∥ (𝐶↑2))
59 nnz 12272 . . . . . . . . . . . 12 (𝐶 ∈ ℕ → 𝐶 ∈ ℤ)
60593ad2ant3 1133 . . . . . . . . . . 11 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐶 ∈ ℤ)
61 dvdssq 16200 . . . . . . . . . . 11 (((𝐴 gcd 𝐵) ∈ ℤ ∧ 𝐶 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐶↑2)))
6210, 60, 61syl2anc 583 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐶↑2)))
6362adantr 480 . . . . . . . . 9 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ ((𝐴 gcd 𝐵)↑2) ∥ (𝐶↑2)))
6458, 63mpbird 256 . . . . . . . 8 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → (𝐴 gcd 𝐵) ∥ 𝐶)
65 dvdsval2 15894 . . . . . . . . . 10 (((𝐴 gcd 𝐵) ∈ ℤ ∧ (𝐴 gcd 𝐵) ≠ 0 ∧ 𝐶 ∈ ℤ) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ (𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ))
6610, 11, 60, 65syl3anc 1369 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ (𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ))
6766adantr 480 . . . . . . . 8 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → ((𝐴 gcd 𝐵) ∥ 𝐶 ↔ (𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ))
6864, 67mpbid 231 . . . . . . 7 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → (𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ)
69 nnre 11910 . . . . . . . . . 10 (𝐶 ∈ ℕ → 𝐶 ∈ ℝ)
70693ad2ant3 1133 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐶 ∈ ℝ)
71 nngt0 11934 . . . . . . . . . 10 (𝐶 ∈ ℕ → 0 < 𝐶)
72713ad2ant3 1133 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < 𝐶)
7370, 18, 72, 21divgt0d 11840 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 0 < (𝐶 / (𝐴 gcd 𝐵)))
7473adantr 480 . . . . . . 7 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → 0 < (𝐶 / (𝐴 gcd 𝐵)))
75 elnnz 12259 . . . . . . 7 ((𝐶 / (𝐴 gcd 𝐵)) ∈ ℕ ↔ ((𝐶 / (𝐴 gcd 𝐵)) ∈ ℤ ∧ 0 < (𝐶 / (𝐴 gcd 𝐵))))
7668, 74, 75sylanbrc 582 . . . . . 6 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2)) → (𝐶 / (𝐴 gcd 𝐵)) ∈ ℕ)
77763adant3 1130 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐶 / (𝐴 gcd 𝐵)) ∈ ℕ)
7848nncnd 11919 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴↑2) ∈ ℂ)
7951nncnd 11919 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐵↑2) ∈ ℂ)
8045nncnd 11919 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ∈ ℂ)
8145nnne0d 11953 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵)↑2) ≠ 0)
8278, 79, 80, 81divdird 11719 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (((𝐴↑2) + (𝐵↑2)) / ((𝐴 gcd 𝐵)↑2)) = (((𝐴↑2) / ((𝐴 gcd 𝐵)↑2)) + ((𝐵↑2) / ((𝐴 gcd 𝐵)↑2))))
83823ad2ant1 1131 . . . . . 6 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (((𝐴↑2) + (𝐵↑2)) / ((𝐴 gcd 𝐵)↑2)) = (((𝐴↑2) / ((𝐴 gcd 𝐵)↑2)) + ((𝐵↑2) / ((𝐴 gcd 𝐵)↑2))))
84 nncn 11911 . . . . . . . . . 10 (𝐶 ∈ ℕ → 𝐶 ∈ ℂ)
85843ad2ant3 1133 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐶 ∈ ℂ)
862nncnd 11919 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 gcd 𝐵) ∈ ℂ)
8785, 86, 11sqdivd 13805 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐶 / (𝐴 gcd 𝐵))↑2) = ((𝐶↑2) / ((𝐴 gcd 𝐵)↑2)))
88873ad2ant1 1131 . . . . . . 7 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ((𝐶 / (𝐴 gcd 𝐵))↑2) = ((𝐶↑2) / ((𝐴 gcd 𝐵)↑2)))
89 oveq1 7262 . . . . . . . 8 (((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) → (((𝐴↑2) + (𝐵↑2)) / ((𝐴 gcd 𝐵)↑2)) = ((𝐶↑2) / ((𝐴 gcd 𝐵)↑2)))
90893ad2ant2 1132 . . . . . . 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 11911 . . . . . . . . . 10 (𝐴 ∈ ℕ → 𝐴 ∈ ℂ)
93923ad2ant1 1131 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐴 ∈ ℂ)
9493, 86, 11sqdivd 13805 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 / (𝐴 gcd 𝐵))↑2) = ((𝐴↑2) / ((𝐴 gcd 𝐵)↑2)))
95 nncn 11911 . . . . . . . . . 10 (𝐵 ∈ ℕ → 𝐵 ∈ ℂ)
96953ad2ant2 1132 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐵 ∈ ℂ)
9796, 86, 11sqdivd 13805 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐵 / (𝐴 gcd 𝐵))↑2) = ((𝐵↑2) / ((𝐴 gcd 𝐵)↑2)))
9894, 97oveq12d 7273 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (((𝐴 / (𝐴 gcd 𝐵))↑2) + ((𝐵 / (𝐴 gcd 𝐵))↑2)) = (((𝐴↑2) / ((𝐴 gcd 𝐵)↑2)) + ((𝐵↑2) / ((𝐴 gcd 𝐵)↑2))))
99983ad2ant1 1131 . . . . . 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 16187 . . . . . . . 8 (((𝐴 ∈ ℤ ∧ 𝐵 ∈ ℤ ∧ (𝐴 gcd 𝐵) ∈ ℕ) ∧ ((𝐴 gcd 𝐵) ∥ 𝐴 ∧ (𝐴 gcd 𝐵) ∥ 𝐵)) → ((𝐴 gcd 𝐵) / (𝐴 gcd 𝐵)) = ((𝐴 / (𝐴 gcd 𝐵)) gcd (𝐵 / (𝐴 gcd 𝐵))))
10212, 27, 2, 8, 101syl31anc 1371 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) / (𝐴 gcd 𝐵)) = ((𝐴 / (𝐴 gcd 𝐵)) gcd (𝐵 / (𝐴 gcd 𝐵))))
10386, 11dividd 11679 . . . . . . 7 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) / (𝐴 gcd 𝐵)) = 1)
104102, 103eqtr3d 2780 . . . . . 6 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 / (𝐴 gcd 𝐵)) gcd (𝐵 / (𝐴 gcd 𝐵))) = 1)
1051043ad2ant1 1131 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ((𝐴 / (𝐴 gcd 𝐵)) gcd (𝐵 / (𝐴 gcd 𝐵))) = 1)
106 simp3 1136 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵)))
107 pythagtriplem18 16461 . . . . 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 1389 . . . 4 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))))
10993, 86, 11divcan2d 11683 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) = 𝐴)
110109eqcomd 2744 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))))
11196, 86, 11divcan2d 11683 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) = 𝐵)
112111eqcomd 2744 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))))
11385, 86, 11divcan2d 11683 . . . . . . . . . 10 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))) = 𝐶)
114113eqcomd 2744 . . . . . . . . 9 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → 𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))))
115110, 112, 1143jca 1126 . . . . . . . 8 ((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) → (𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵)))))
1161153ad2ant1 1131 . . . . . . 7 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵)))))
117 oveq2 7263 . . . . . . . . . 10 ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) → ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))))
118117eqeq2d 2749 . . . . . . . . 9 ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) → (𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) ↔ 𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2)))))
1191183ad2ant1 1131 . . . . . . . 8 (((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → (𝐴 = ((𝐴 gcd 𝐵) · (𝐴 / (𝐴 gcd 𝐵))) ↔ 𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2)))))
120 oveq2 7263 . . . . . . . . . 10 ((𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) → ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))))
121120eqeq2d 2749 . . . . . . . . 9 ((𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) → (𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) ↔ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛)))))
1221213ad2ant2 1132 . . . . . . . 8 (((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → (𝐵 = ((𝐴 gcd 𝐵) · (𝐵 / (𝐴 gcd 𝐵))) ↔ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛)))))
123 oveq2 7263 . . . . . . . . . 10 ((𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2)) → ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))) = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))
124123eqeq2d 2749 . . . . . . . . 9 ((𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2)) → (𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))) ↔ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2)))))
1251243ad2ant3 1133 . . . . . . . 8 (((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → (𝐶 = ((𝐴 gcd 𝐵) · (𝐶 / (𝐴 gcd 𝐵))) ↔ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2)))))
126119, 122, 1253anbi123d 1434 . . . . . . 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 3201 . . . . 5 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → (∃𝑚 ∈ ℕ ((𝐴 / (𝐴 gcd 𝐵)) = ((𝑚↑2) − (𝑛↑2)) ∧ (𝐵 / (𝐴 gcd 𝐵)) = (2 · (𝑚 · 𝑛)) ∧ (𝐶 / (𝐴 gcd 𝐵)) = ((𝑚↑2) + (𝑛↑2))) → ∃𝑚 ∈ ℕ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))))
129128reximdv 3201 . . . 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 7262 . . . . . . 7 (𝑘 = (𝐴 gcd 𝐵) → (𝑘 · ((𝑚↑2) − (𝑛↑2))) = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))))
132131eqeq2d 2749 . . . . . 6 (𝑘 = (𝐴 gcd 𝐵) → (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ↔ 𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2)))))
133 oveq1 7262 . . . . . . 7 (𝑘 = (𝐴 gcd 𝐵) → (𝑘 · (2 · (𝑚 · 𝑛))) = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))))
134133eqeq2d 2749 . . . . . 6 (𝑘 = (𝐴 gcd 𝐵) → (𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ↔ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛)))))
135 oveq1 7262 . . . . . . 7 (𝑘 = (𝐴 gcd 𝐵) → (𝑘 · ((𝑚↑2) + (𝑛↑2))) = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))
136135eqeq2d 2749 . . . . . 6 (𝑘 = (𝐴 gcd 𝐵) → (𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2))) ↔ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2)))))
137132, 134, 1363anbi123d 1434 . . . . 5 (𝑘 = (𝐴 gcd 𝐵) → ((𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))))
1381372rexbidv 3228 . . . 4 (𝑘 = (𝐴 gcd 𝐵) → (∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))))
139138rspcev 3552 . . 3 (((𝐴 gcd 𝐵) ∈ ℕ ∧ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = ((𝐴 gcd 𝐵) · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = ((𝐴 gcd 𝐵) · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = ((𝐴 gcd 𝐵) · ((𝑚↑2) + (𝑛↑2))))) → ∃𝑘 ∈ ℕ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
1403, 130, 139syl2anc 583 . 2 (((𝐴 ∈ ℕ ∧ 𝐵 ∈ ℕ ∧ 𝐶 ∈ ℕ) ∧ ((𝐴↑2) + (𝐵↑2)) = (𝐶↑2) ∧ ¬ 2 ∥ (𝐴 / (𝐴 gcd 𝐵))) → ∃𝑘 ∈ ℕ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
141 rexcom 3281 . . 3 (∃𝑘 ∈ ℕ ∃𝑛 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ ∃𝑛 ∈ ℕ ∃𝑘 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
142 rexcom 3281 . . . 4 (∃𝑘 ∈ ℕ ∃𝑚 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))) ↔ ∃𝑚 ∈ ℕ ∃𝑘 ∈ ℕ (𝐴 = (𝑘 · ((𝑚↑2) − (𝑛↑2))) ∧ 𝐵 = (𝑘 · (2 · (𝑚 · 𝑛))) ∧ 𝐶 = (𝑘 · ((𝑚↑2) + (𝑛↑2)))))
143142rexbii 3177 . . 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 395  w3a 1085   = wceq 1539  wcel 2108  wne 2942  wrex 3064   class class class wbr 5070  (class class class)co 7255  cc 10800  cr 10801  0cc0 10802  1c1 10803   + caddc 10805   · cmul 10807   < clt 10940  cmin 11135   / cdiv 11562  cn 11903  2c2 11958  cz 12249  cexp 13710  cdvds 15891   gcd cgcd 16129
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1799  ax-4 1813  ax-5 1914  ax-6 1972  ax-7 2012  ax-8 2110  ax-9 2118  ax-10 2139  ax-11 2156  ax-12 2173  ax-ext 2709  ax-sep 5218  ax-nul 5225  ax-pow 5283  ax-pr 5347  ax-un 7566  ax-cnex 10858  ax-resscn 10859  ax-1cn 10860  ax-icn 10861  ax-addcl 10862  ax-addrcl 10863  ax-mulcl 10864  ax-mulrcl 10865  ax-mulcom 10866  ax-addass 10867  ax-mulass 10868  ax-distr 10869  ax-i2m1 10870  ax-1ne0 10871  ax-1rid 10872  ax-rnegex 10873  ax-rrecex 10874  ax-cnre 10875  ax-pre-lttri 10876  ax-pre-lttrn 10877  ax-pre-ltadd 10878  ax-pre-mulgt0 10879  ax-pre-sup 10880
This theorem depends on definitions:  df-bi 206  df-an 396  df-or 844  df-3or 1086  df-3an 1087  df-tru 1542  df-fal 1552  df-ex 1784  df-nf 1788  df-sb 2069  df-mo 2540  df-eu 2569  df-clab 2716  df-cleq 2730  df-clel 2817  df-nfc 2888  df-ne 2943  df-nel 3049  df-ral 3068  df-rex 3069  df-reu 3070  df-rmo 3071  df-rab 3072  df-v 3424  df-sbc 3712  df-csb 3829  df-dif 3886  df-un 3888  df-in 3890  df-ss 3900  df-pss 3902  df-nul 4254  df-if 4457  df-pw 4532  df-sn 4559  df-pr 4561  df-tp 4563  df-op 4565  df-uni 4837  df-iun 4923  df-br 5071  df-opab 5133  df-mpt 5154  df-tr 5188  df-id 5480  df-eprel 5486  df-po 5494  df-so 5495  df-fr 5535  df-we 5537  df-xp 5586  df-rel 5587  df-cnv 5588  df-co 5589  df-dm 5590  df-rn 5591  df-res 5592  df-ima 5593  df-pred 6191  df-ord 6254  df-on 6255  df-lim 6256  df-suc 6257  df-iota 6376  df-fun 6420  df-fn 6421  df-f 6422  df-f1 6423  df-fo 6424  df-f1o 6425  df-fv 6426  df-riota 7212  df-ov 7258  df-oprab 7259  df-mpo 7260  df-om 7688  df-1st 7804  df-2nd 7805  df-frecs 8068  df-wrecs 8099  df-recs 8173  df-rdg 8212  df-1o 8267  df-2o 8268  df-er 8456  df-en 8692  df-dom 8693  df-sdom 8694  df-fin 8695  df-sup 9131  df-inf 9132  df-pnf 10942  df-mnf 10943  df-xr 10944  df-ltxr 10945  df-le 10946  df-sub 11137  df-neg 11138  df-div 11563  df-nn 11904  df-2 11966  df-3 11967  df-n0 12164  df-z 12250  df-uz 12512  df-rp 12660  df-fz 13169  df-fl 13440  df-mod 13518  df-seq 13650  df-exp 13711  df-cj 14738  df-re 14739  df-im 14740  df-sqrt 14874  df-abs 14875  df-dvds 15892  df-gcd 16130  df-prm 16305
This theorem is referenced by:  pythagtrip  16463
  Copyright terms: Public domain W3C validator