Proof of Theorem 4sqlem10
Step | Hyp | Ref
| Expression |
1 | | 4sqlem5.3 |
. . . . . 6
⊢ (𝜑 → 𝑀 ∈ ℕ) |
2 | 1 | adantr 274 |
. . . . 5
⊢ ((𝜑 ∧ 𝜓) → 𝑀 ∈ ℕ) |
3 | 2 | nnzd 9333 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → 𝑀 ∈ ℤ) |
4 | | zsqcl 10546 |
. . . 4
⊢ (𝑀 ∈ ℤ → (𝑀↑2) ∈
ℤ) |
5 | 3, 4 | syl 14 |
. . 3
⊢ ((𝜑 ∧ 𝜓) → (𝑀↑2) ∈ ℤ) |
6 | | 4sqlem5.2 |
. . . . . 6
⊢ (𝜑 → 𝐴 ∈ ℤ) |
7 | 6 | adantr 274 |
. . . . 5
⊢ ((𝜑 ∧ 𝜓) → 𝐴 ∈ ℤ) |
8 | 2 | nnred 8891 |
. . . . . . . . 9
⊢ ((𝜑 ∧ 𝜓) → 𝑀 ∈ ℝ) |
9 | 8 | rehalfcld 9124 |
. . . . . . . 8
⊢ ((𝜑 ∧ 𝜓) → (𝑀 / 2) ∈ ℝ) |
10 | 9 | recnd 7948 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝜓) → (𝑀 / 2) ∈ ℂ) |
11 | 10 | negnegd 8221 |
. . . . . 6
⊢ ((𝜑 ∧ 𝜓) → --(𝑀 / 2) = (𝑀 / 2)) |
12 | | 4sqlem5.4 |
. . . . . . . . . . . . . . 15
⊢ 𝐵 = (((𝐴 + (𝑀 / 2)) mod 𝑀) − (𝑀 / 2)) |
13 | 6, 1, 12 | 4sqlem5 12334 |
. . . . . . . . . . . . . 14
⊢ (𝜑 → (𝐵 ∈ ℤ ∧ ((𝐴 − 𝐵) / 𝑀) ∈ ℤ)) |
14 | 13 | adantr 274 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ 𝜓) → (𝐵 ∈ ℤ ∧ ((𝐴 − 𝐵) / 𝑀) ∈ ℤ)) |
15 | 14 | simpld 111 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ 𝜓) → 𝐵 ∈ ℤ) |
16 | 15 | zred 9334 |
. . . . . . . . . . 11
⊢ ((𝜑 ∧ 𝜓) → 𝐵 ∈ ℝ) |
17 | 6, 1, 12 | 4sqlem6 12335 |
. . . . . . . . . . . . 13
⊢ (𝜑 → (-(𝑀 / 2) ≤ 𝐵 ∧ 𝐵 < (𝑀 / 2))) |
18 | 17 | adantr 274 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ 𝜓) → (-(𝑀 / 2) ≤ 𝐵 ∧ 𝐵 < (𝑀 / 2))) |
19 | 18 | simprd 113 |
. . . . . . . . . . 11
⊢ ((𝜑 ∧ 𝜓) → 𝐵 < (𝑀 / 2)) |
20 | 16, 19 | ltned 8033 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ 𝜓) → 𝐵 ≠ (𝑀 / 2)) |
21 | 20 | neneqd 2361 |
. . . . . . . . 9
⊢ ((𝜑 ∧ 𝜓) → ¬ 𝐵 = (𝑀 / 2)) |
22 | | 2cnd 8951 |
. . . . . . . . . . . . . . 15
⊢ ((𝜑 ∧ 𝜓) → 2 ∈ ℂ) |
23 | 22 | sqvald 10606 |
. . . . . . . . . . . . . 14
⊢ ((𝜑 ∧ 𝜓) → (2↑2) = (2 ·
2)) |
24 | 23 | oveq2d 5869 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ 𝜓) → ((𝑀↑2) / (2↑2)) = ((𝑀↑2) / (2 · 2))) |
25 | 2 | nncnd 8892 |
. . . . . . . . . . . . . 14
⊢ ((𝜑 ∧ 𝜓) → 𝑀 ∈ ℂ) |
26 | | 2ap0 8971 |
. . . . . . . . . . . . . . 15
⊢ 2 #
0 |
27 | 26 | a1i 9 |
. . . . . . . . . . . . . 14
⊢ ((𝜑 ∧ 𝜓) → 2 # 0) |
28 | 25, 22, 27 | sqdivapd 10622 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ 𝜓) → ((𝑀 / 2)↑2) = ((𝑀↑2) / (2↑2))) |
29 | 25 | sqcld 10607 |
. . . . . . . . . . . . . 14
⊢ ((𝜑 ∧ 𝜓) → (𝑀↑2) ∈ ℂ) |
30 | 29, 22, 22, 27, 27 | divdivap1d 8739 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ 𝜓) → (((𝑀↑2) / 2) / 2) = ((𝑀↑2) / (2 · 2))) |
31 | 24, 28, 30 | 3eqtr4d 2213 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ 𝜓) → ((𝑀 / 2)↑2) = (((𝑀↑2) / 2) / 2)) |
32 | 29 | halfcld 9122 |
. . . . . . . . . . . . . 14
⊢ ((𝜑 ∧ 𝜓) → ((𝑀↑2) / 2) ∈
ℂ) |
33 | 32 | halfcld 9122 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ 𝜓) → (((𝑀↑2) / 2) / 2) ∈
ℂ) |
34 | 15 | zcnd 9335 |
. . . . . . . . . . . . . 14
⊢ ((𝜑 ∧ 𝜓) → 𝐵 ∈ ℂ) |
35 | 34 | sqcld 10607 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ 𝜓) → (𝐵↑2) ∈ ℂ) |
36 | | 4sqlem10.5 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ 𝜓) → ((((𝑀↑2) / 2) / 2) − (𝐵↑2)) = 0) |
37 | 33, 35, 36 | subeq0d 8238 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ 𝜓) → (((𝑀↑2) / 2) / 2) = (𝐵↑2)) |
38 | 31, 37 | eqtr2d 2204 |
. . . . . . . . . . 11
⊢ ((𝜑 ∧ 𝜓) → (𝐵↑2) = ((𝑀 / 2)↑2)) |
39 | | zq 9585 |
. . . . . . . . . . . . 13
⊢ (𝐵 ∈ ℤ → 𝐵 ∈
ℚ) |
40 | 15, 39 | syl 14 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ 𝜓) → 𝐵 ∈ ℚ) |
41 | | 2nn 9039 |
. . . . . . . . . . . . . 14
⊢ 2 ∈
ℕ |
42 | 41 | a1i 9 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ 𝜓) → 2 ∈ ℕ) |
43 | | znq 9583 |
. . . . . . . . . . . . 13
⊢ ((𝑀 ∈ ℤ ∧ 2 ∈
ℕ) → (𝑀 / 2)
∈ ℚ) |
44 | 3, 42, 43 | syl2anc 409 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ 𝜓) → (𝑀 / 2) ∈ ℚ) |
45 | | qsqeqor 10586 |
. . . . . . . . . . . 12
⊢ ((𝐵 ∈ ℚ ∧ (𝑀 / 2) ∈ ℚ) →
((𝐵↑2) = ((𝑀 / 2)↑2) ↔ (𝐵 = (𝑀 / 2) ∨ 𝐵 = -(𝑀 / 2)))) |
46 | 40, 44, 45 | syl2anc 409 |
. . . . . . . . . . 11
⊢ ((𝜑 ∧ 𝜓) → ((𝐵↑2) = ((𝑀 / 2)↑2) ↔ (𝐵 = (𝑀 / 2) ∨ 𝐵 = -(𝑀 / 2)))) |
47 | 38, 46 | mpbid 146 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ 𝜓) → (𝐵 = (𝑀 / 2) ∨ 𝐵 = -(𝑀 / 2))) |
48 | 47 | ord 719 |
. . . . . . . . 9
⊢ ((𝜑 ∧ 𝜓) → (¬ 𝐵 = (𝑀 / 2) → 𝐵 = -(𝑀 / 2))) |
49 | 21, 48 | mpd 13 |
. . . . . . . 8
⊢ ((𝜑 ∧ 𝜓) → 𝐵 = -(𝑀 / 2)) |
50 | 49, 15 | eqeltrrd 2248 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝜓) → -(𝑀 / 2) ∈ ℤ) |
51 | 50 | znegcld 9336 |
. . . . . 6
⊢ ((𝜑 ∧ 𝜓) → --(𝑀 / 2) ∈ ℤ) |
52 | 11, 51 | eqeltrrd 2248 |
. . . . 5
⊢ ((𝜑 ∧ 𝜓) → (𝑀 / 2) ∈ ℤ) |
53 | 7, 52 | zaddcld 9338 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → (𝐴 + (𝑀 / 2)) ∈ ℤ) |
54 | | zsqcl 10546 |
. . . 4
⊢ ((𝐴 + (𝑀 / 2)) ∈ ℤ → ((𝐴 + (𝑀 / 2))↑2) ∈
ℤ) |
55 | 53, 54 | syl 14 |
. . 3
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2))↑2) ∈
ℤ) |
56 | 53, 3 | zmulcld 9340 |
. . 3
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) · 𝑀) ∈ ℤ) |
57 | | zq 9585 |
. . . . . . . . . 10
⊢ (𝐴 ∈ ℤ → 𝐴 ∈
ℚ) |
58 | 7, 57 | syl 14 |
. . . . . . . . 9
⊢ ((𝜑 ∧ 𝜓) → 𝐴 ∈ ℚ) |
59 | | qaddcl 9594 |
. . . . . . . . 9
⊢ ((𝐴 ∈ ℚ ∧ (𝑀 / 2) ∈ ℚ) →
(𝐴 + (𝑀 / 2)) ∈ ℚ) |
60 | 58, 44, 59 | syl2anc 409 |
. . . . . . . 8
⊢ ((𝜑 ∧ 𝜓) → (𝐴 + (𝑀 / 2)) ∈ ℚ) |
61 | | nnq 9592 |
. . . . . . . . 9
⊢ (𝑀 ∈ ℕ → 𝑀 ∈
ℚ) |
62 | 2, 61 | syl 14 |
. . . . . . . 8
⊢ ((𝜑 ∧ 𝜓) → 𝑀 ∈ ℚ) |
63 | 2 | nngt0d 8922 |
. . . . . . . 8
⊢ ((𝜑 ∧ 𝜓) → 0 < 𝑀) |
64 | 60, 62, 63 | modqcld 10284 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) mod 𝑀) ∈ ℚ) |
65 | | qcn 9593 |
. . . . . . 7
⊢ (((𝐴 + (𝑀 / 2)) mod 𝑀) ∈ ℚ → ((𝐴 + (𝑀 / 2)) mod 𝑀) ∈ ℂ) |
66 | 64, 65 | syl 14 |
. . . . . 6
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) mod 𝑀) ∈ ℂ) |
67 | | 0cnd 7913 |
. . . . . 6
⊢ ((𝜑 ∧ 𝜓) → 0 ∈ ℂ) |
68 | | df-neg 8093 |
. . . . . . 7
⊢ -(𝑀 / 2) = (0 − (𝑀 / 2)) |
69 | 49, 12, 68 | 3eqtr3g 2226 |
. . . . . 6
⊢ ((𝜑 ∧ 𝜓) → (((𝐴 + (𝑀 / 2)) mod 𝑀) − (𝑀 / 2)) = (0 − (𝑀 / 2))) |
70 | 66, 67, 10, 69 | subcan2d 8272 |
. . . . 5
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) mod 𝑀) = 0) |
71 | | dvdsval3 11753 |
. . . . . 6
⊢ ((𝑀 ∈ ℕ ∧ (𝐴 + (𝑀 / 2)) ∈ ℤ) → (𝑀 ∥ (𝐴 + (𝑀 / 2)) ↔ ((𝐴 + (𝑀 / 2)) mod 𝑀) = 0)) |
72 | 2, 53, 71 | syl2anc 409 |
. . . . 5
⊢ ((𝜑 ∧ 𝜓) → (𝑀 ∥ (𝐴 + (𝑀 / 2)) ↔ ((𝐴 + (𝑀 / 2)) mod 𝑀) = 0)) |
73 | 70, 72 | mpbird 166 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → 𝑀 ∥ (𝐴 + (𝑀 / 2))) |
74 | | dvdssq 11986 |
. . . . 5
⊢ ((𝑀 ∈ ℤ ∧ (𝐴 + (𝑀 / 2)) ∈ ℤ) → (𝑀 ∥ (𝐴 + (𝑀 / 2)) ↔ (𝑀↑2) ∥ ((𝐴 + (𝑀 / 2))↑2))) |
75 | 3, 53, 74 | syl2anc 409 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → (𝑀 ∥ (𝐴 + (𝑀 / 2)) ↔ (𝑀↑2) ∥ ((𝐴 + (𝑀 / 2))↑2))) |
76 | 73, 75 | mpbid 146 |
. . 3
⊢ ((𝜑 ∧ 𝜓) → (𝑀↑2) ∥ ((𝐴 + (𝑀 / 2))↑2)) |
77 | 25 | sqvald 10606 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → (𝑀↑2) = (𝑀 · 𝑀)) |
78 | 2 | nnne0d 8923 |
. . . . . 6
⊢ ((𝜑 ∧ 𝜓) → 𝑀 ≠ 0) |
79 | | dvdsmulcr 11783 |
. . . . . 6
⊢ ((𝑀 ∈ ℤ ∧ (𝐴 + (𝑀 / 2)) ∈ ℤ ∧ (𝑀 ∈ ℤ ∧ 𝑀 ≠ 0)) → ((𝑀 · 𝑀) ∥ ((𝐴 + (𝑀 / 2)) · 𝑀) ↔ 𝑀 ∥ (𝐴 + (𝑀 / 2)))) |
80 | 3, 53, 3, 78, 79 | syl112anc 1237 |
. . . . 5
⊢ ((𝜑 ∧ 𝜓) → ((𝑀 · 𝑀) ∥ ((𝐴 + (𝑀 / 2)) · 𝑀) ↔ 𝑀 ∥ (𝐴 + (𝑀 / 2)))) |
81 | 73, 80 | mpbird 166 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → (𝑀 · 𝑀) ∥ ((𝐴 + (𝑀 / 2)) · 𝑀)) |
82 | 77, 81 | eqbrtrd 4011 |
. . 3
⊢ ((𝜑 ∧ 𝜓) → (𝑀↑2) ∥ ((𝐴 + (𝑀 / 2)) · 𝑀)) |
83 | 5, 55, 56, 76, 82 | dvds2subd 11789 |
. 2
⊢ ((𝜑 ∧ 𝜓) → (𝑀↑2) ∥ (((𝐴 + (𝑀 / 2))↑2) − ((𝐴 + (𝑀 / 2)) · 𝑀))) |
84 | 53 | zcnd 9335 |
. . . . 5
⊢ ((𝜑 ∧ 𝜓) → (𝐴 + (𝑀 / 2)) ∈ ℂ) |
85 | 84 | sqvald 10606 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2))↑2) = ((𝐴 + (𝑀 / 2)) · (𝐴 + (𝑀 / 2)))) |
86 | 85 | oveq1d 5868 |
. . 3
⊢ ((𝜑 ∧ 𝜓) → (((𝐴 + (𝑀 / 2))↑2) − ((𝐴 + (𝑀 / 2)) · 𝑀)) = (((𝐴 + (𝑀 / 2)) · (𝐴 + (𝑀 / 2))) − ((𝐴 + (𝑀 / 2)) · 𝑀))) |
87 | 84, 84, 25 | subdid 8333 |
. . 3
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) · ((𝐴 + (𝑀 / 2)) − 𝑀)) = (((𝐴 + (𝑀 / 2)) · (𝐴 + (𝑀 / 2))) − ((𝐴 + (𝑀 / 2)) · 𝑀))) |
88 | 25 | 2halvesd 9123 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝜓) → ((𝑀 / 2) + (𝑀 / 2)) = 𝑀) |
89 | 88 | oveq2d 5869 |
. . . . . 6
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) − ((𝑀 / 2) + (𝑀 / 2))) = ((𝐴 + (𝑀 / 2)) − 𝑀)) |
90 | 7 | zcnd 9335 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝜓) → 𝐴 ∈ ℂ) |
91 | 90, 10, 10 | pnpcan2d 8268 |
. . . . . 6
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) − ((𝑀 / 2) + (𝑀 / 2))) = (𝐴 − (𝑀 / 2))) |
92 | 89, 91 | eqtr3d 2205 |
. . . . 5
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) − 𝑀) = (𝐴 − (𝑀 / 2))) |
93 | 92 | oveq2d 5869 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) · ((𝐴 + (𝑀 / 2)) − 𝑀)) = ((𝐴 + (𝑀 / 2)) · (𝐴 − (𝑀 / 2)))) |
94 | | subsq 10582 |
. . . . 5
⊢ ((𝐴 ∈ ℂ ∧ (𝑀 / 2) ∈ ℂ) →
((𝐴↑2) − ((𝑀 / 2)↑2)) = ((𝐴 + (𝑀 / 2)) · (𝐴 − (𝑀 / 2)))) |
95 | 90, 10, 94 | syl2anc 409 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → ((𝐴↑2) − ((𝑀 / 2)↑2)) = ((𝐴 + (𝑀 / 2)) · (𝐴 − (𝑀 / 2)))) |
96 | 31 | oveq2d 5869 |
. . . 4
⊢ ((𝜑 ∧ 𝜓) → ((𝐴↑2) − ((𝑀 / 2)↑2)) = ((𝐴↑2) − (((𝑀↑2) / 2) / 2))) |
97 | 93, 95, 96 | 3eqtr2d 2209 |
. . 3
⊢ ((𝜑 ∧ 𝜓) → ((𝐴 + (𝑀 / 2)) · ((𝐴 + (𝑀 / 2)) − 𝑀)) = ((𝐴↑2) − (((𝑀↑2) / 2) / 2))) |
98 | 86, 87, 97 | 3eqtr2d 2209 |
. 2
⊢ ((𝜑 ∧ 𝜓) → (((𝐴 + (𝑀 / 2))↑2) − ((𝐴 + (𝑀 / 2)) · 𝑀)) = ((𝐴↑2) − (((𝑀↑2) / 2) / 2))) |
99 | 83, 98 | breqtrd 4015 |
1
⊢ ((𝜑 ∧ 𝜓) → (𝑀↑2) ∥ ((𝐴↑2) − (((𝑀↑2) / 2) / 2))) |