ILE Home Intuitionistic Logic Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  ILE Home  >  Th. List  >  pockthlem GIF version

Theorem pockthlem 12337
Description: Lemma for pockthg 12338. (Contributed by Mario Carneiro, 2-Mar-2014.)
Hypotheses
Ref Expression
pockthg.1 (𝜑𝐴 ∈ ℕ)
pockthg.2 (𝜑𝐵 ∈ ℕ)
pockthg.3 (𝜑𝐵 < 𝐴)
pockthg.4 (𝜑𝑁 = ((𝐴 · 𝐵) + 1))
pockthlem.5 (𝜑𝑃 ∈ ℙ)
pockthlem.6 (𝜑𝑃𝑁)
pockthlem.7 (𝜑𝑄 ∈ ℙ)
pockthlem.8 (𝜑 → (𝑄 pCnt 𝐴) ∈ ℕ)
pockthlem.9 (𝜑𝐶 ∈ ℤ)
pockthlem.10 (𝜑 → ((𝐶↑(𝑁 − 1)) mod 𝑁) = 1)
pockthlem.11 (𝜑 → (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁) = 1)
Assertion
Ref Expression
pockthlem (𝜑 → (𝑄 pCnt 𝐴) ≤ (𝑄 pCnt (𝑃 − 1)))

Proof of Theorem pockthlem
StepHypRef Expression
1 pockthlem.7 . . . . . 6 (𝜑𝑄 ∈ ℙ)
2 prmnn 12093 . . . . . 6 (𝑄 ∈ ℙ → 𝑄 ∈ ℕ)
31, 2syl 14 . . . . 5 (𝜑𝑄 ∈ ℕ)
4 pockthlem.8 . . . . . 6 (𝜑 → (𝑄 pCnt 𝐴) ∈ ℕ)
54nnnn0d 9218 . . . . 5 (𝜑 → (𝑄 pCnt 𝐴) ∈ ℕ0)
63, 5nnexpcld 10661 . . . 4 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∈ ℕ)
76nnzd 9363 . . 3 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∈ ℤ)
8 pockthlem.5 . . . . . 6 (𝜑𝑃 ∈ ℙ)
9 prmnn 12093 . . . . . 6 (𝑃 ∈ ℙ → 𝑃 ∈ ℕ)
108, 9syl 14 . . . . 5 (𝜑𝑃 ∈ ℕ)
11 pockthlem.9 . . . . 5 (𝜑𝐶 ∈ ℤ)
1210nnzd 9363 . . . . . . . . . 10 (𝜑𝑃 ∈ ℤ)
13 gcddvds 11947 . . . . . . . . . 10 ((𝐶 ∈ ℤ ∧ 𝑃 ∈ ℤ) → ((𝐶 gcd 𝑃) ∥ 𝐶 ∧ (𝐶 gcd 𝑃) ∥ 𝑃))
1411, 12, 13syl2anc 411 . . . . . . . . 9 (𝜑 → ((𝐶 gcd 𝑃) ∥ 𝐶 ∧ (𝐶 gcd 𝑃) ∥ 𝑃))
1514simpld 112 . . . . . . . 8 (𝜑 → (𝐶 gcd 𝑃) ∥ 𝐶)
1611, 12gcdcld 11952 . . . . . . . . . 10 (𝜑 → (𝐶 gcd 𝑃) ∈ ℕ0)
1716nn0zd 9362 . . . . . . . . 9 (𝜑 → (𝐶 gcd 𝑃) ∈ ℤ)
18 pockthg.4 . . . . . . . . . . . . . 14 (𝜑𝑁 = ((𝐴 · 𝐵) + 1))
19 pockthg.1 . . . . . . . . . . . . . . . . 17 (𝜑𝐴 ∈ ℕ)
20 pockthg.2 . . . . . . . . . . . . . . . . 17 (𝜑𝐵 ∈ ℕ)
2119, 20nnmulcld 8957 . . . . . . . . . . . . . . . 16 (𝜑 → (𝐴 · 𝐵) ∈ ℕ)
22 nnuz 9552 . . . . . . . . . . . . . . . 16 ℕ = (ℤ‘1)
2321, 22eleqtrdi 2270 . . . . . . . . . . . . . . 15 (𝜑 → (𝐴 · 𝐵) ∈ (ℤ‘1))
24 eluzp1p1 9542 . . . . . . . . . . . . . . 15 ((𝐴 · 𝐵) ∈ (ℤ‘1) → ((𝐴 · 𝐵) + 1) ∈ (ℤ‘(1 + 1)))
2523, 24syl 14 . . . . . . . . . . . . . 14 (𝜑 → ((𝐴 · 𝐵) + 1) ∈ (ℤ‘(1 + 1)))
2618, 25eqeltrd 2254 . . . . . . . . . . . . 13 (𝜑𝑁 ∈ (ℤ‘(1 + 1)))
27 df-2 8967 . . . . . . . . . . . . . 14 2 = (1 + 1)
2827fveq2i 5514 . . . . . . . . . . . . 13 (ℤ‘2) = (ℤ‘(1 + 1))
2926, 28eleqtrrdi 2271 . . . . . . . . . . . 12 (𝜑𝑁 ∈ (ℤ‘2))
30 eluz2b2 9592 . . . . . . . . . . . 12 (𝑁 ∈ (ℤ‘2) ↔ (𝑁 ∈ ℕ ∧ 1 < 𝑁))
3129, 30sylib 122 . . . . . . . . . . 11 (𝜑 → (𝑁 ∈ ℕ ∧ 1 < 𝑁))
3231simpld 112 . . . . . . . . . 10 (𝜑𝑁 ∈ ℕ)
3332nnzd 9363 . . . . . . . . 9 (𝜑𝑁 ∈ ℤ)
3414simprd 114 . . . . . . . . 9 (𝜑 → (𝐶 gcd 𝑃) ∥ 𝑃)
35 pockthlem.6 . . . . . . . . 9 (𝜑𝑃𝑁)
3617, 12, 33, 34, 35dvdstrd 11821 . . . . . . . 8 (𝜑 → (𝐶 gcd 𝑃) ∥ 𝑁)
3732nnne0d 8953 . . . . . . . . . 10 (𝜑𝑁 ≠ 0)
38 simpr 110 . . . . . . . . . . 11 ((𝐶 = 0 ∧ 𝑁 = 0) → 𝑁 = 0)
3938necon3ai 2396 . . . . . . . . . 10 (𝑁 ≠ 0 → ¬ (𝐶 = 0 ∧ 𝑁 = 0))
4037, 39syl 14 . . . . . . . . 9 (𝜑 → ¬ (𝐶 = 0 ∧ 𝑁 = 0))
41 dvdslegcd 11948 . . . . . . . . 9 ((((𝐶 gcd 𝑃) ∈ ℤ ∧ 𝐶 ∈ ℤ ∧ 𝑁 ∈ ℤ) ∧ ¬ (𝐶 = 0 ∧ 𝑁 = 0)) → (((𝐶 gcd 𝑃) ∥ 𝐶 ∧ (𝐶 gcd 𝑃) ∥ 𝑁) → (𝐶 gcd 𝑃) ≤ (𝐶 gcd 𝑁)))
4217, 11, 33, 40, 41syl31anc 1241 . . . . . . . 8 (𝜑 → (((𝐶 gcd 𝑃) ∥ 𝐶 ∧ (𝐶 gcd 𝑃) ∥ 𝑁) → (𝐶 gcd 𝑃) ≤ (𝐶 gcd 𝑁)))
4315, 36, 42mp2and 433 . . . . . . 7 (𝜑 → (𝐶 gcd 𝑃) ≤ (𝐶 gcd 𝑁))
44 pockthlem.10 . . . . . . . . . 10 (𝜑 → ((𝐶↑(𝑁 − 1)) mod 𝑁) = 1)
4544oveq1d 5884 . . . . . . . . 9 (𝜑 → (((𝐶↑(𝑁 − 1)) mod 𝑁) gcd 𝑁) = (1 gcd 𝑁))
46 1z 9268 . . . . . . . . . . . . . 14 1 ∈ ℤ
47 eluzp1m1 9540 . . . . . . . . . . . . . 14 ((1 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘(1 + 1))) → (𝑁 − 1) ∈ (ℤ‘1))
4846, 26, 47sylancr 414 . . . . . . . . . . . . 13 (𝜑 → (𝑁 − 1) ∈ (ℤ‘1))
4948, 22eleqtrrdi 2271 . . . . . . . . . . . 12 (𝜑 → (𝑁 − 1) ∈ ℕ)
5049nnnn0d 9218 . . . . . . . . . . 11 (𝜑 → (𝑁 − 1) ∈ ℕ0)
51 zexpcl 10521 . . . . . . . . . . 11 ((𝐶 ∈ ℤ ∧ (𝑁 − 1) ∈ ℕ0) → (𝐶↑(𝑁 − 1)) ∈ ℤ)
5211, 50, 51syl2anc 411 . . . . . . . . . 10 (𝜑 → (𝐶↑(𝑁 − 1)) ∈ ℤ)
53 modgcd 11975 . . . . . . . . . 10 (((𝐶↑(𝑁 − 1)) ∈ ℤ ∧ 𝑁 ∈ ℕ) → (((𝐶↑(𝑁 − 1)) mod 𝑁) gcd 𝑁) = ((𝐶↑(𝑁 − 1)) gcd 𝑁))
5452, 32, 53syl2anc 411 . . . . . . . . 9 (𝜑 → (((𝐶↑(𝑁 − 1)) mod 𝑁) gcd 𝑁) = ((𝐶↑(𝑁 − 1)) gcd 𝑁))
55 gcdcom 11957 . . . . . . . . . . 11 ((1 ∈ ℤ ∧ 𝑁 ∈ ℤ) → (1 gcd 𝑁) = (𝑁 gcd 1))
5646, 33, 55sylancr 414 . . . . . . . . . 10 (𝜑 → (1 gcd 𝑁) = (𝑁 gcd 1))
57 gcd1 11971 . . . . . . . . . . 11 (𝑁 ∈ ℤ → (𝑁 gcd 1) = 1)
5833, 57syl 14 . . . . . . . . . 10 (𝜑 → (𝑁 gcd 1) = 1)
5956, 58eqtrd 2210 . . . . . . . . 9 (𝜑 → (1 gcd 𝑁) = 1)
6045, 54, 593eqtr3d 2218 . . . . . . . 8 (𝜑 → ((𝐶↑(𝑁 − 1)) gcd 𝑁) = 1)
61 rpexp 12136 . . . . . . . . 9 ((𝐶 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ (𝑁 − 1) ∈ ℕ) → (((𝐶↑(𝑁 − 1)) gcd 𝑁) = 1 ↔ (𝐶 gcd 𝑁) = 1))
6211, 33, 49, 61syl3anc 1238 . . . . . . . 8 (𝜑 → (((𝐶↑(𝑁 − 1)) gcd 𝑁) = 1 ↔ (𝐶 gcd 𝑁) = 1))
6360, 62mpbid 147 . . . . . . 7 (𝜑 → (𝐶 gcd 𝑁) = 1)
6443, 63breqtrd 4026 . . . . . 6 (𝜑 → (𝐶 gcd 𝑃) ≤ 1)
6510nnne0d 8953 . . . . . . . . 9 (𝜑𝑃 ≠ 0)
66 simpr 110 . . . . . . . . . 10 ((𝐶 = 0 ∧ 𝑃 = 0) → 𝑃 = 0)
6766necon3ai 2396 . . . . . . . . 9 (𝑃 ≠ 0 → ¬ (𝐶 = 0 ∧ 𝑃 = 0))
6865, 67syl 14 . . . . . . . 8 (𝜑 → ¬ (𝐶 = 0 ∧ 𝑃 = 0))
69 gcdn0cl 11946 . . . . . . . 8 (((𝐶 ∈ ℤ ∧ 𝑃 ∈ ℤ) ∧ ¬ (𝐶 = 0 ∧ 𝑃 = 0)) → (𝐶 gcd 𝑃) ∈ ℕ)
7011, 12, 68, 69syl21anc 1237 . . . . . . 7 (𝜑 → (𝐶 gcd 𝑃) ∈ ℕ)
71 nnle1eq1 8932 . . . . . . 7 ((𝐶 gcd 𝑃) ∈ ℕ → ((𝐶 gcd 𝑃) ≤ 1 ↔ (𝐶 gcd 𝑃) = 1))
7270, 71syl 14 . . . . . 6 (𝜑 → ((𝐶 gcd 𝑃) ≤ 1 ↔ (𝐶 gcd 𝑃) = 1))
7364, 72mpbid 147 . . . . 5 (𝜑 → (𝐶 gcd 𝑃) = 1)
74 odzcl 12226 . . . . 5 ((𝑃 ∈ ℕ ∧ 𝐶 ∈ ℤ ∧ (𝐶 gcd 𝑃) = 1) → ((od𝑃)‘𝐶) ∈ ℕ)
7510, 11, 73, 74syl3anc 1238 . . . 4 (𝜑 → ((od𝑃)‘𝐶) ∈ ℕ)
7675nnzd 9363 . . 3 (𝜑 → ((od𝑃)‘𝐶) ∈ ℤ)
77 prmuz2 12114 . . . . . . . 8 (𝑃 ∈ ℙ → 𝑃 ∈ (ℤ‘2))
788, 77syl 14 . . . . . . 7 (𝜑𝑃 ∈ (ℤ‘2))
7978, 28eleqtrdi 2270 . . . . . 6 (𝜑𝑃 ∈ (ℤ‘(1 + 1)))
80 eluzp1m1 9540 . . . . . 6 ((1 ∈ ℤ ∧ 𝑃 ∈ (ℤ‘(1 + 1))) → (𝑃 − 1) ∈ (ℤ‘1))
8146, 79, 80sylancr 414 . . . . 5 (𝜑 → (𝑃 − 1) ∈ (ℤ‘1))
8281, 22eleqtrrdi 2271 . . . 4 (𝜑 → (𝑃 − 1) ∈ ℕ)
8382nnzd 9363 . . 3 (𝜑 → (𝑃 − 1) ∈ ℤ)
8419nnzd 9363 . . . . . 6 (𝜑𝐴 ∈ ℤ)
8549nnzd 9363 . . . . . 6 (𝜑 → (𝑁 − 1) ∈ ℤ)
86 pcdvds 12297 . . . . . . 7 ((𝑄 ∈ ℙ ∧ 𝐴 ∈ ℕ) → (𝑄↑(𝑄 pCnt 𝐴)) ∥ 𝐴)
871, 19, 86syl2anc 411 . . . . . 6 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∥ 𝐴)
8820nnzd 9363 . . . . . . . 8 (𝜑𝐵 ∈ ℤ)
89 dvdsmul1 11804 . . . . . . . 8 ((𝐴 ∈ ℤ ∧ 𝐵 ∈ ℤ) → 𝐴 ∥ (𝐴 · 𝐵))
9084, 88, 89syl2anc 411 . . . . . . 7 (𝜑𝐴 ∥ (𝐴 · 𝐵))
9118oveq1d 5884 . . . . . . . 8 (𝜑 → (𝑁 − 1) = (((𝐴 · 𝐵) + 1) − 1))
9221nncnd 8922 . . . . . . . . 9 (𝜑 → (𝐴 · 𝐵) ∈ ℂ)
93 ax-1cn 7895 . . . . . . . . 9 1 ∈ ℂ
94 pncan 8153 . . . . . . . . 9 (((𝐴 · 𝐵) ∈ ℂ ∧ 1 ∈ ℂ) → (((𝐴 · 𝐵) + 1) − 1) = (𝐴 · 𝐵))
9592, 93, 94sylancl 413 . . . . . . . 8 (𝜑 → (((𝐴 · 𝐵) + 1) − 1) = (𝐴 · 𝐵))
9691, 95eqtrd 2210 . . . . . . 7 (𝜑 → (𝑁 − 1) = (𝐴 · 𝐵))
9790, 96breqtrrd 4028 . . . . . 6 (𝜑𝐴 ∥ (𝑁 − 1))
987, 84, 85, 87, 97dvdstrd 11821 . . . . 5 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1))
996nnne0d 8953 . . . . . 6 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ≠ 0)
100 dvdsval2 11781 . . . . . 6 (((𝑄↑(𝑄 pCnt 𝐴)) ∈ ℤ ∧ (𝑄↑(𝑄 pCnt 𝐴)) ≠ 0 ∧ (𝑁 − 1) ∈ ℤ) → ((𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1) ↔ ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℤ))
1017, 99, 85, 100syl3anc 1238 . . . . 5 (𝜑 → ((𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1) ↔ ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℤ))
10298, 101mpbid 147 . . . 4 (𝜑 → ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℤ)
103 peano2zm 9280 . . . . . . . 8 ((𝐶↑(𝑁 − 1)) ∈ ℤ → ((𝐶↑(𝑁 − 1)) − 1) ∈ ℤ)
10452, 103syl 14 . . . . . . 7 (𝜑 → ((𝐶↑(𝑁 − 1)) − 1) ∈ ℤ)
105 nnq 9622 . . . . . . . . . . 11 (𝑁 ∈ ℕ → 𝑁 ∈ ℚ)
10632, 105syl 14 . . . . . . . . . 10 (𝜑𝑁 ∈ ℚ)
10731simprd 114 . . . . . . . . . 10 (𝜑 → 1 < 𝑁)
108 q1mod 10342 . . . . . . . . . 10 ((𝑁 ∈ ℚ ∧ 1 < 𝑁) → (1 mod 𝑁) = 1)
109106, 107, 108syl2anc 411 . . . . . . . . 9 (𝜑 → (1 mod 𝑁) = 1)
11044, 109eqtr4d 2213 . . . . . . . 8 (𝜑 → ((𝐶↑(𝑁 − 1)) mod 𝑁) = (1 mod 𝑁))
111 1zzd 9269 . . . . . . . . 9 (𝜑 → 1 ∈ ℤ)
112 moddvds 11790 . . . . . . . . 9 ((𝑁 ∈ ℕ ∧ (𝐶↑(𝑁 − 1)) ∈ ℤ ∧ 1 ∈ ℤ) → (((𝐶↑(𝑁 − 1)) mod 𝑁) = (1 mod 𝑁) ↔ 𝑁 ∥ ((𝐶↑(𝑁 − 1)) − 1)))
11332, 52, 111, 112syl3anc 1238 . . . . . . . 8 (𝜑 → (((𝐶↑(𝑁 − 1)) mod 𝑁) = (1 mod 𝑁) ↔ 𝑁 ∥ ((𝐶↑(𝑁 − 1)) − 1)))
114110, 113mpbid 147 . . . . . . 7 (𝜑𝑁 ∥ ((𝐶↑(𝑁 − 1)) − 1))
11512, 33, 104, 35, 114dvdstrd 11821 . . . . . 6 (𝜑𝑃 ∥ ((𝐶↑(𝑁 − 1)) − 1))
116 odzdvds 12228 . . . . . . 7 (((𝑃 ∈ ℕ ∧ 𝐶 ∈ ℤ ∧ (𝐶 gcd 𝑃) = 1) ∧ (𝑁 − 1) ∈ ℕ0) → (𝑃 ∥ ((𝐶↑(𝑁 − 1)) − 1) ↔ ((od𝑃)‘𝐶) ∥ (𝑁 − 1)))
11710, 11, 73, 50, 116syl31anc 1241 . . . . . 6 (𝜑 → (𝑃 ∥ ((𝐶↑(𝑁 − 1)) − 1) ↔ ((od𝑃)‘𝐶) ∥ (𝑁 − 1)))
118115, 117mpbid 147 . . . . 5 (𝜑 → ((od𝑃)‘𝐶) ∥ (𝑁 − 1))
11949nncnd 8922 . . . . . 6 (𝜑 → (𝑁 − 1) ∈ ℂ)
1206nncnd 8922 . . . . . 6 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∈ ℂ)
1216nnap0d 8954 . . . . . 6 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) # 0)
122119, 120, 121divcanap1d 8737 . . . . 5 (𝜑 → (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))) = (𝑁 − 1))
123118, 122breqtrrd 4028 . . . 4 (𝜑 → ((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))))
124 nprmdvds1 12123 . . . . . 6 (𝑃 ∈ ℙ → ¬ 𝑃 ∥ 1)
1258, 124syl 14 . . . . 5 (𝜑 → ¬ 𝑃 ∥ 1)
1263nnzd 9363 . . . . . . . . . . . . 13 (𝜑𝑄 ∈ ℤ)
127 iddvdsexp 11806 . . . . . . . . . . . . . 14 ((𝑄 ∈ ℤ ∧ (𝑄 pCnt 𝐴) ∈ ℕ) → 𝑄 ∥ (𝑄↑(𝑄 pCnt 𝐴)))
128126, 4, 127syl2anc 411 . . . . . . . . . . . . 13 (𝜑𝑄 ∥ (𝑄↑(𝑄 pCnt 𝐴)))
129126, 7, 85, 128, 98dvdstrd 11821 . . . . . . . . . . . 12 (𝜑𝑄 ∥ (𝑁 − 1))
1303nnne0d 8953 . . . . . . . . . . . . 13 (𝜑𝑄 ≠ 0)
131 dvdsval2 11781 . . . . . . . . . . . . 13 ((𝑄 ∈ ℤ ∧ 𝑄 ≠ 0 ∧ (𝑁 − 1) ∈ ℤ) → (𝑄 ∥ (𝑁 − 1) ↔ ((𝑁 − 1) / 𝑄) ∈ ℤ))
132126, 130, 85, 131syl3anc 1238 . . . . . . . . . . . 12 (𝜑 → (𝑄 ∥ (𝑁 − 1) ↔ ((𝑁 − 1) / 𝑄) ∈ ℤ))
133129, 132mpbid 147 . . . . . . . . . . 11 (𝜑 → ((𝑁 − 1) / 𝑄) ∈ ℤ)
13450nn0ge0d 9221 . . . . . . . . . . . 12 (𝜑 → 0 ≤ (𝑁 − 1))
13549nnred 8921 . . . . . . . . . . . . 13 (𝜑 → (𝑁 − 1) ∈ ℝ)
1363nnred 8921 . . . . . . . . . . . . 13 (𝜑𝑄 ∈ ℝ)
1373nngt0d 8952 . . . . . . . . . . . . 13 (𝜑 → 0 < 𝑄)
138 ge0div 8817 . . . . . . . . . . . . 13 (((𝑁 − 1) ∈ ℝ ∧ 𝑄 ∈ ℝ ∧ 0 < 𝑄) → (0 ≤ (𝑁 − 1) ↔ 0 ≤ ((𝑁 − 1) / 𝑄)))
139135, 136, 137, 138syl3anc 1238 . . . . . . . . . . . 12 (𝜑 → (0 ≤ (𝑁 − 1) ↔ 0 ≤ ((𝑁 − 1) / 𝑄)))
140134, 139mpbid 147 . . . . . . . . . . 11 (𝜑 → 0 ≤ ((𝑁 − 1) / 𝑄))
141 elnn0z 9255 . . . . . . . . . . 11 (((𝑁 − 1) / 𝑄) ∈ ℕ0 ↔ (((𝑁 − 1) / 𝑄) ∈ ℤ ∧ 0 ≤ ((𝑁 − 1) / 𝑄)))
142133, 140, 141sylanbrc 417 . . . . . . . . . 10 (𝜑 → ((𝑁 − 1) / 𝑄) ∈ ℕ0)
143 zexpcl 10521 . . . . . . . . . 10 ((𝐶 ∈ ℤ ∧ ((𝑁 − 1) / 𝑄) ∈ ℕ0) → (𝐶↑((𝑁 − 1) / 𝑄)) ∈ ℤ)
14411, 142, 143syl2anc 411 . . . . . . . . 9 (𝜑 → (𝐶↑((𝑁 − 1) / 𝑄)) ∈ ℤ)
145 peano2zm 9280 . . . . . . . . 9 ((𝐶↑((𝑁 − 1) / 𝑄)) ∈ ℤ → ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∈ ℤ)
146144, 145syl 14 . . . . . . . 8 (𝜑 → ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∈ ℤ)
147 dvdsgcd 11996 . . . . . . . 8 ((𝑃 ∈ ℤ ∧ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∈ ℤ ∧ 𝑁 ∈ ℤ) → ((𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∧ 𝑃𝑁) → 𝑃 ∥ (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁)))
14812, 146, 33, 147syl3anc 1238 . . . . . . 7 (𝜑 → ((𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∧ 𝑃𝑁) → 𝑃 ∥ (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁)))
14935, 148mpan2d 428 . . . . . 6 (𝜑 → (𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) → 𝑃 ∥ (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁)))
150 odzdvds 12228 . . . . . . . 8 (((𝑃 ∈ ℕ ∧ 𝐶 ∈ ℤ ∧ (𝐶 gcd 𝑃) = 1) ∧ ((𝑁 − 1) / 𝑄) ∈ ℕ0) → (𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ↔ ((od𝑃)‘𝐶) ∥ ((𝑁 − 1) / 𝑄)))
15110, 11, 73, 142, 150syl31anc 1241 . . . . . . 7 (𝜑 → (𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ↔ ((od𝑃)‘𝐶) ∥ ((𝑁 − 1) / 𝑄)))
1523nncnd 8922 . . . . . . . . . . 11 (𝜑𝑄 ∈ ℂ)
1533nnap0d 8954 . . . . . . . . . . 11 (𝜑𝑄 # 0)
1544nnzd 9363 . . . . . . . . . . 11 (𝜑 → (𝑄 pCnt 𝐴) ∈ ℤ)
155152, 153, 154expm1apd 10649 . . . . . . . . . 10 (𝜑 → (𝑄↑((𝑄 pCnt 𝐴) − 1)) = ((𝑄↑(𝑄 pCnt 𝐴)) / 𝑄))
156155oveq2d 5885 . . . . . . . . 9 (𝜑 → (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))) = (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · ((𝑄↑(𝑄 pCnt 𝐴)) / 𝑄)))
157135, 6nndivred 8958 . . . . . . . . . . 11 (𝜑 → ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℝ)
158157recnd 7976 . . . . . . . . . 10 (𝜑 → ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℂ)
159158, 120, 152, 153divassapd 8772 . . . . . . . . 9 (𝜑 → ((((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))) / 𝑄) = (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · ((𝑄↑(𝑄 pCnt 𝐴)) / 𝑄)))
160122oveq1d 5884 . . . . . . . . 9 (𝜑 → ((((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))) / 𝑄) = ((𝑁 − 1) / 𝑄))
161156, 159, 1603eqtr2d 2216 . . . . . . . 8 (𝜑 → (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))) = ((𝑁 − 1) / 𝑄))
162161breq2d 4012 . . . . . . 7 (𝜑 → (((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))) ↔ ((od𝑃)‘𝐶) ∥ ((𝑁 − 1) / 𝑄)))
163151, 162bitr4d 191 . . . . . 6 (𝜑 → (𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ↔ ((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1)))))
164 pockthlem.11 . . . . . . 7 (𝜑 → (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁) = 1)
165164breq2d 4012 . . . . . 6 (𝜑 → (𝑃 ∥ (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁) ↔ 𝑃 ∥ 1))
166149, 163, 1653imtr3d 202 . . . . 5 (𝜑 → (((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))) → 𝑃 ∥ 1))
167125, 166mtod 663 . . . 4 (𝜑 → ¬ ((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))))
168 prmpwdvds 12336 . . . 4 (((((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℤ ∧ ((od𝑃)‘𝐶) ∈ ℤ) ∧ (𝑄 ∈ ℙ ∧ (𝑄 pCnt 𝐴) ∈ ℕ) ∧ (((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))) ∧ ¬ ((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))))) → (𝑄↑(𝑄 pCnt 𝐴)) ∥ ((od𝑃)‘𝐶))
169102, 76, 1, 4, 123, 167, 168syl222anc 1254 . . 3 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∥ ((od𝑃)‘𝐶))
170 odzphi 12229 . . . . 5 ((𝑃 ∈ ℕ ∧ 𝐶 ∈ ℤ ∧ (𝐶 gcd 𝑃) = 1) → ((od𝑃)‘𝐶) ∥ (ϕ‘𝑃))
17110, 11, 73, 170syl3anc 1238 . . . 4 (𝜑 → ((od𝑃)‘𝐶) ∥ (ϕ‘𝑃))
172 phiprm 12206 . . . . 5 (𝑃 ∈ ℙ → (ϕ‘𝑃) = (𝑃 − 1))
1738, 172syl 14 . . . 4 (𝜑 → (ϕ‘𝑃) = (𝑃 − 1))
174171, 173breqtrd 4026 . . 3 (𝜑 → ((od𝑃)‘𝐶) ∥ (𝑃 − 1))
1757, 76, 83, 169, 174dvdstrd 11821 . 2 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑃 − 1))
176 pcdvdsb 12302 . . 3 ((𝑄 ∈ ℙ ∧ (𝑃 − 1) ∈ ℤ ∧ (𝑄 pCnt 𝐴) ∈ ℕ0) → ((𝑄 pCnt 𝐴) ≤ (𝑄 pCnt (𝑃 − 1)) ↔ (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑃 − 1)))
1771, 83, 5, 176syl3anc 1238 . 2 (𝜑 → ((𝑄 pCnt 𝐴) ≤ (𝑄 pCnt (𝑃 − 1)) ↔ (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑃 − 1)))
178175, 177mpbird 167 1 (𝜑 → (𝑄 pCnt 𝐴) ≤ (𝑄 pCnt (𝑃 − 1)))
Colors of variables: wff set class
Syntax hints:  ¬ wn 3  wi 4  wa 104  wb 105   = wceq 1353  wcel 2148  wne 2347   class class class wbr 4000  cfv 5212  (class class class)co 5869  cc 7800  cr 7801  0cc0 7802  1c1 7803   + caddc 7805   · cmul 7807   < clt 7982  cle 7983  cmin 8118   / cdiv 8618  cn 8908  2c2 8959  0cn0 9165  cz 9242  cuz 9517  cq 9608   mod cmo 10308  cexp 10505  cdvds 11778   gcd cgcd 11926  cprime 12090  odcodz 12191  ϕcphi 12192   pCnt cpc 12267
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-ia1 106  ax-ia2 107  ax-ia3 108  ax-in1 614  ax-in2 615  ax-io 709  ax-5 1447  ax-7 1448  ax-gen 1449  ax-ie1 1493  ax-ie2 1494  ax-8 1504  ax-10 1505  ax-11 1506  ax-i12 1507  ax-bndl 1509  ax-4 1510  ax-17 1526  ax-i9 1530  ax-ial 1534  ax-i5r 1535  ax-13 2150  ax-14 2151  ax-ext 2159  ax-coll 4115  ax-sep 4118  ax-nul 4126  ax-pow 4171  ax-pr 4206  ax-un 4430  ax-setind 4533  ax-iinf 4584  ax-cnex 7893  ax-resscn 7894  ax-1cn 7895  ax-1re 7896  ax-icn 7897  ax-addcl 7898  ax-addrcl 7899  ax-mulcl 7900  ax-mulrcl 7901  ax-addcom 7902  ax-mulcom 7903  ax-addass 7904  ax-mulass 7905  ax-distr 7906  ax-i2m1 7907  ax-0lt1 7908  ax-1rid 7909  ax-0id 7910  ax-rnegex 7911  ax-precex 7912  ax-cnre 7913  ax-pre-ltirr 7914  ax-pre-ltwlin 7915  ax-pre-lttrn 7916  ax-pre-apti 7917  ax-pre-ltadd 7918  ax-pre-mulgt0 7919  ax-pre-mulext 7920  ax-arch 7921  ax-caucvg 7922
This theorem depends on definitions:  df-bi 117  df-stab 831  df-dc 835  df-3or 979  df-3an 980  df-tru 1356  df-fal 1359  df-nf 1461  df-sb 1763  df-eu 2029  df-mo 2030  df-clab 2164  df-cleq 2170  df-clel 2173  df-nfc 2308  df-ne 2348  df-nel 2443  df-ral 2460  df-rex 2461  df-reu 2462  df-rmo 2463  df-rab 2464  df-v 2739  df-sbc 2963  df-csb 3058  df-dif 3131  df-un 3133  df-in 3135  df-ss 3142  df-nul 3423  df-if 3535  df-pw 3576  df-sn 3597  df-pr 3598  df-op 3600  df-uni 3808  df-int 3843  df-iun 3886  df-br 4001  df-opab 4062  df-mpt 4063  df-tr 4099  df-id 4290  df-po 4293  df-iso 4294  df-iord 4363  df-on 4365  df-ilim 4366  df-suc 4368  df-iom 4587  df-xp 4629  df-rel 4630  df-cnv 4631  df-co 4632  df-dm 4633  df-rn 4634  df-res 4635  df-ima 4636  df-iota 5174  df-fun 5214  df-fn 5215  df-f 5216  df-f1 5217  df-fo 5218  df-f1o 5219  df-fv 5220  df-isom 5221  df-riota 5825  df-ov 5872  df-oprab 5873  df-mpo 5874  df-1st 6135  df-2nd 6136  df-recs 6300  df-irdg 6365  df-frec 6386  df-1o 6411  df-2o 6412  df-oadd 6415  df-er 6529  df-en 6735  df-dom 6736  df-fin 6737  df-sup 6977  df-inf 6978  df-pnf 7984  df-mnf 7985  df-xr 7986  df-ltxr 7987  df-le 7988  df-sub 8120  df-neg 8121  df-reap 8522  df-ap 8529  df-div 8619  df-inn 8909  df-2 8967  df-3 8968  df-4 8969  df-n0 9166  df-z 9243  df-uz 9518  df-q 9609  df-rp 9641  df-fz 9996  df-fzo 10129  df-fl 10256  df-mod 10309  df-seqfrec 10432  df-exp 10506  df-ihash 10740  df-cj 10835  df-re 10836  df-im 10837  df-rsqrt 10991  df-abs 10992  df-clim 11271  df-proddc 11543  df-dvds 11779  df-gcd 11927  df-prm 12091  df-odz 12193  df-phi 12194  df-pc 12268
This theorem is referenced by:  pockthg  12338
  Copyright terms: Public domain W3C validator