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

Theorem pockthlem 16241
Description: Lemma for pockthg 16242. (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 . . . . . . 7 (𝜑𝑄 ∈ ℙ)
2 pockthg.1 . . . . . . 7 (𝜑𝐴 ∈ ℕ)
3 pcdvds 16200 . . . . . . 7 ((𝑄 ∈ ℙ ∧ 𝐴 ∈ ℕ) → (𝑄↑(𝑄 pCnt 𝐴)) ∥ 𝐴)
41, 2, 3syl2anc 586 . . . . . 6 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∥ 𝐴)
52nnzd 12087 . . . . . . . 8 (𝜑𝐴 ∈ ℤ)
6 pockthg.2 . . . . . . . . 9 (𝜑𝐵 ∈ ℕ)
76nnzd 12087 . . . . . . . 8 (𝜑𝐵 ∈ ℤ)
8 dvdsmul1 15631 . . . . . . . 8 ((𝐴 ∈ ℤ ∧ 𝐵 ∈ ℤ) → 𝐴 ∥ (𝐴 · 𝐵))
95, 7, 8syl2anc 586 . . . . . . 7 (𝜑𝐴 ∥ (𝐴 · 𝐵))
10 pockthg.4 . . . . . . . . 9 (𝜑𝑁 = ((𝐴 · 𝐵) + 1))
1110oveq1d 7171 . . . . . . . 8 (𝜑 → (𝑁 − 1) = (((𝐴 · 𝐵) + 1) − 1))
122, 6nnmulcld 11691 . . . . . . . . . 10 (𝜑 → (𝐴 · 𝐵) ∈ ℕ)
1312nncnd 11654 . . . . . . . . 9 (𝜑 → (𝐴 · 𝐵) ∈ ℂ)
14 ax-1cn 10595 . . . . . . . . 9 1 ∈ ℂ
15 pncan 10892 . . . . . . . . 9 (((𝐴 · 𝐵) ∈ ℂ ∧ 1 ∈ ℂ) → (((𝐴 · 𝐵) + 1) − 1) = (𝐴 · 𝐵))
1613, 14, 15sylancl 588 . . . . . . . 8 (𝜑 → (((𝐴 · 𝐵) + 1) − 1) = (𝐴 · 𝐵))
1711, 16eqtrd 2856 . . . . . . 7 (𝜑 → (𝑁 − 1) = (𝐴 · 𝐵))
189, 17breqtrrd 5094 . . . . . 6 (𝜑𝐴 ∥ (𝑁 − 1))
19 prmnn 16018 . . . . . . . . . 10 (𝑄 ∈ ℙ → 𝑄 ∈ ℕ)
201, 19syl 17 . . . . . . . . 9 (𝜑𝑄 ∈ ℕ)
21 pockthlem.8 . . . . . . . . . 10 (𝜑 → (𝑄 pCnt 𝐴) ∈ ℕ)
2221nnnn0d 11956 . . . . . . . . 9 (𝜑 → (𝑄 pCnt 𝐴) ∈ ℕ0)
2320, 22nnexpcld 13607 . . . . . . . 8 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∈ ℕ)
2423nnzd 12087 . . . . . . 7 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∈ ℤ)
25 1z 12013 . . . . . . . . . 10 1 ∈ ℤ
26 nnuz 12282 . . . . . . . . . . . . 13 ℕ = (ℤ‘1)
2712, 26eleqtrdi 2923 . . . . . . . . . . . 12 (𝜑 → (𝐴 · 𝐵) ∈ (ℤ‘1))
28 eluzp1p1 12271 . . . . . . . . . . . 12 ((𝐴 · 𝐵) ∈ (ℤ‘1) → ((𝐴 · 𝐵) + 1) ∈ (ℤ‘(1 + 1)))
2927, 28syl 17 . . . . . . . . . . 11 (𝜑 → ((𝐴 · 𝐵) + 1) ∈ (ℤ‘(1 + 1)))
3010, 29eqeltrd 2913 . . . . . . . . . 10 (𝜑𝑁 ∈ (ℤ‘(1 + 1)))
31 eluzp1m1 12269 . . . . . . . . . 10 ((1 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘(1 + 1))) → (𝑁 − 1) ∈ (ℤ‘1))
3225, 30, 31sylancr 589 . . . . . . . . 9 (𝜑 → (𝑁 − 1) ∈ (ℤ‘1))
3332, 26eleqtrrdi 2924 . . . . . . . 8 (𝜑 → (𝑁 − 1) ∈ ℕ)
3433nnzd 12087 . . . . . . 7 (𝜑 → (𝑁 − 1) ∈ ℤ)
35 dvdstr 15646 . . . . . . 7 (((𝑄↑(𝑄 pCnt 𝐴)) ∈ ℤ ∧ 𝐴 ∈ ℤ ∧ (𝑁 − 1) ∈ ℤ) → (((𝑄↑(𝑄 pCnt 𝐴)) ∥ 𝐴𝐴 ∥ (𝑁 − 1)) → (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1)))
3624, 5, 34, 35syl3anc 1367 . . . . . 6 (𝜑 → (((𝑄↑(𝑄 pCnt 𝐴)) ∥ 𝐴𝐴 ∥ (𝑁 − 1)) → (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1)))
374, 18, 36mp2and 697 . . . . 5 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1))
3823nnne0d 11688 . . . . . 6 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ≠ 0)
39 dvdsval2 15610 . . . . . 6 (((𝑄↑(𝑄 pCnt 𝐴)) ∈ ℤ ∧ (𝑄↑(𝑄 pCnt 𝐴)) ≠ 0 ∧ (𝑁 − 1) ∈ ℤ) → ((𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1) ↔ ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℤ))
4024, 38, 34, 39syl3anc 1367 . . . . 5 (𝜑 → ((𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1) ↔ ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℤ))
4137, 40mpbid 234 . . . 4 (𝜑 → ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℤ)
42 pockthlem.5 . . . . . . 7 (𝜑𝑃 ∈ ℙ)
43 prmnn 16018 . . . . . . 7 (𝑃 ∈ ℙ → 𝑃 ∈ ℕ)
4442, 43syl 17 . . . . . 6 (𝜑𝑃 ∈ ℕ)
45 pockthlem.9 . . . . . 6 (𝜑𝐶 ∈ ℤ)
4644nnzd 12087 . . . . . . . . . . 11 (𝜑𝑃 ∈ ℤ)
47 gcddvds 15852 . . . . . . . . . . 11 ((𝐶 ∈ ℤ ∧ 𝑃 ∈ ℤ) → ((𝐶 gcd 𝑃) ∥ 𝐶 ∧ (𝐶 gcd 𝑃) ∥ 𝑃))
4845, 46, 47syl2anc 586 . . . . . . . . . 10 (𝜑 → ((𝐶 gcd 𝑃) ∥ 𝐶 ∧ (𝐶 gcd 𝑃) ∥ 𝑃))
4948simpld 497 . . . . . . . . 9 (𝜑 → (𝐶 gcd 𝑃) ∥ 𝐶)
5048simprd 498 . . . . . . . . . 10 (𝜑 → (𝐶 gcd 𝑃) ∥ 𝑃)
51 pockthlem.6 . . . . . . . . . 10 (𝜑𝑃𝑁)
5245, 46gcdcld 15857 . . . . . . . . . . . 12 (𝜑 → (𝐶 gcd 𝑃) ∈ ℕ0)
5352nn0zd 12086 . . . . . . . . . . 11 (𝜑 → (𝐶 gcd 𝑃) ∈ ℤ)
54 df-2 11701 . . . . . . . . . . . . . . . 16 2 = (1 + 1)
5554fveq2i 6673 . . . . . . . . . . . . . . 15 (ℤ‘2) = (ℤ‘(1 + 1))
5630, 55eleqtrrdi 2924 . . . . . . . . . . . . . 14 (𝜑𝑁 ∈ (ℤ‘2))
57 eluz2b2 12322 . . . . . . . . . . . . . 14 (𝑁 ∈ (ℤ‘2) ↔ (𝑁 ∈ ℕ ∧ 1 < 𝑁))
5856, 57sylib 220 . . . . . . . . . . . . 13 (𝜑 → (𝑁 ∈ ℕ ∧ 1 < 𝑁))
5958simpld 497 . . . . . . . . . . . 12 (𝜑𝑁 ∈ ℕ)
6059nnzd 12087 . . . . . . . . . . 11 (𝜑𝑁 ∈ ℤ)
61 dvdstr 15646 . . . . . . . . . . 11 (((𝐶 gcd 𝑃) ∈ ℤ ∧ 𝑃 ∈ ℤ ∧ 𝑁 ∈ ℤ) → (((𝐶 gcd 𝑃) ∥ 𝑃𝑃𝑁) → (𝐶 gcd 𝑃) ∥ 𝑁))
6253, 46, 60, 61syl3anc 1367 . . . . . . . . . 10 (𝜑 → (((𝐶 gcd 𝑃) ∥ 𝑃𝑃𝑁) → (𝐶 gcd 𝑃) ∥ 𝑁))
6350, 51, 62mp2and 697 . . . . . . . . 9 (𝜑 → (𝐶 gcd 𝑃) ∥ 𝑁)
6459nnne0d 11688 . . . . . . . . . . 11 (𝜑𝑁 ≠ 0)
65 simpr 487 . . . . . . . . . . . 12 ((𝐶 = 0 ∧ 𝑁 = 0) → 𝑁 = 0)
6665necon3ai 3041 . . . . . . . . . . 11 (𝑁 ≠ 0 → ¬ (𝐶 = 0 ∧ 𝑁 = 0))
6764, 66syl 17 . . . . . . . . . 10 (𝜑 → ¬ (𝐶 = 0 ∧ 𝑁 = 0))
68 dvdslegcd 15853 . . . . . . . . . 10 ((((𝐶 gcd 𝑃) ∈ ℤ ∧ 𝐶 ∈ ℤ ∧ 𝑁 ∈ ℤ) ∧ ¬ (𝐶 = 0 ∧ 𝑁 = 0)) → (((𝐶 gcd 𝑃) ∥ 𝐶 ∧ (𝐶 gcd 𝑃) ∥ 𝑁) → (𝐶 gcd 𝑃) ≤ (𝐶 gcd 𝑁)))
6953, 45, 60, 67, 68syl31anc 1369 . . . . . . . . 9 (𝜑 → (((𝐶 gcd 𝑃) ∥ 𝐶 ∧ (𝐶 gcd 𝑃) ∥ 𝑁) → (𝐶 gcd 𝑃) ≤ (𝐶 gcd 𝑁)))
7049, 63, 69mp2and 697 . . . . . . . 8 (𝜑 → (𝐶 gcd 𝑃) ≤ (𝐶 gcd 𝑁))
71 pockthlem.10 . . . . . . . . . . 11 (𝜑 → ((𝐶↑(𝑁 − 1)) mod 𝑁) = 1)
7271oveq1d 7171 . . . . . . . . . 10 (𝜑 → (((𝐶↑(𝑁 − 1)) mod 𝑁) gcd 𝑁) = (1 gcd 𝑁))
7333nnnn0d 11956 . . . . . . . . . . . 12 (𝜑 → (𝑁 − 1) ∈ ℕ0)
74 zexpcl 13445 . . . . . . . . . . . 12 ((𝐶 ∈ ℤ ∧ (𝑁 − 1) ∈ ℕ0) → (𝐶↑(𝑁 − 1)) ∈ ℤ)
7545, 73, 74syl2anc 586 . . . . . . . . . . 11 (𝜑 → (𝐶↑(𝑁 − 1)) ∈ ℤ)
76 modgcd 15880 . . . . . . . . . . 11 (((𝐶↑(𝑁 − 1)) ∈ ℤ ∧ 𝑁 ∈ ℕ) → (((𝐶↑(𝑁 − 1)) mod 𝑁) gcd 𝑁) = ((𝐶↑(𝑁 − 1)) gcd 𝑁))
7775, 59, 76syl2anc 586 . . . . . . . . . 10 (𝜑 → (((𝐶↑(𝑁 − 1)) mod 𝑁) gcd 𝑁) = ((𝐶↑(𝑁 − 1)) gcd 𝑁))
78 gcdcom 15862 . . . . . . . . . . . 12 ((1 ∈ ℤ ∧ 𝑁 ∈ ℤ) → (1 gcd 𝑁) = (𝑁 gcd 1))
7925, 60, 78sylancr 589 . . . . . . . . . . 11 (𝜑 → (1 gcd 𝑁) = (𝑁 gcd 1))
80 gcd1 15876 . . . . . . . . . . . 12 (𝑁 ∈ ℤ → (𝑁 gcd 1) = 1)
8160, 80syl 17 . . . . . . . . . . 11 (𝜑 → (𝑁 gcd 1) = 1)
8279, 81eqtrd 2856 . . . . . . . . . 10 (𝜑 → (1 gcd 𝑁) = 1)
8372, 77, 823eqtr3d 2864 . . . . . . . . 9 (𝜑 → ((𝐶↑(𝑁 − 1)) gcd 𝑁) = 1)
84 rpexp 16064 . . . . . . . . . 10 ((𝐶 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ (𝑁 − 1) ∈ ℕ) → (((𝐶↑(𝑁 − 1)) gcd 𝑁) = 1 ↔ (𝐶 gcd 𝑁) = 1))
8545, 60, 33, 84syl3anc 1367 . . . . . . . . 9 (𝜑 → (((𝐶↑(𝑁 − 1)) gcd 𝑁) = 1 ↔ (𝐶 gcd 𝑁) = 1))
8683, 85mpbid 234 . . . . . . . 8 (𝜑 → (𝐶 gcd 𝑁) = 1)
8770, 86breqtrd 5092 . . . . . . 7 (𝜑 → (𝐶 gcd 𝑃) ≤ 1)
8844nnne0d 11688 . . . . . . . . . 10 (𝜑𝑃 ≠ 0)
89 simpr 487 . . . . . . . . . . 11 ((𝐶 = 0 ∧ 𝑃 = 0) → 𝑃 = 0)
9089necon3ai 3041 . . . . . . . . . 10 (𝑃 ≠ 0 → ¬ (𝐶 = 0 ∧ 𝑃 = 0))
9188, 90syl 17 . . . . . . . . 9 (𝜑 → ¬ (𝐶 = 0 ∧ 𝑃 = 0))
92 gcdn0cl 15851 . . . . . . . . 9 (((𝐶 ∈ ℤ ∧ 𝑃 ∈ ℤ) ∧ ¬ (𝐶 = 0 ∧ 𝑃 = 0)) → (𝐶 gcd 𝑃) ∈ ℕ)
9345, 46, 91, 92syl21anc 835 . . . . . . . 8 (𝜑 → (𝐶 gcd 𝑃) ∈ ℕ)
94 nnle1eq1 11668 . . . . . . . 8 ((𝐶 gcd 𝑃) ∈ ℕ → ((𝐶 gcd 𝑃) ≤ 1 ↔ (𝐶 gcd 𝑃) = 1))
9593, 94syl 17 . . . . . . 7 (𝜑 → ((𝐶 gcd 𝑃) ≤ 1 ↔ (𝐶 gcd 𝑃) = 1))
9687, 95mpbid 234 . . . . . 6 (𝜑 → (𝐶 gcd 𝑃) = 1)
97 odzcl 16130 . . . . . 6 ((𝑃 ∈ ℕ ∧ 𝐶 ∈ ℤ ∧ (𝐶 gcd 𝑃) = 1) → ((od𝑃)‘𝐶) ∈ ℕ)
9844, 45, 96, 97syl3anc 1367 . . . . 5 (𝜑 → ((od𝑃)‘𝐶) ∈ ℕ)
9998nnzd 12087 . . . 4 (𝜑 → ((od𝑃)‘𝐶) ∈ ℤ)
10059nnred 11653 . . . . . . . . . 10 (𝜑𝑁 ∈ ℝ)
10158simprd 498 . . . . . . . . . 10 (𝜑 → 1 < 𝑁)
102 1mod 13272 . . . . . . . . . 10 ((𝑁 ∈ ℝ ∧ 1 < 𝑁) → (1 mod 𝑁) = 1)
103100, 101, 102syl2anc 586 . . . . . . . . 9 (𝜑 → (1 mod 𝑁) = 1)
10471, 103eqtr4d 2859 . . . . . . . 8 (𝜑 → ((𝐶↑(𝑁 − 1)) mod 𝑁) = (1 mod 𝑁))
105 1zzd 12014 . . . . . . . . 9 (𝜑 → 1 ∈ ℤ)
106 moddvds 15618 . . . . . . . . 9 ((𝑁 ∈ ℕ ∧ (𝐶↑(𝑁 − 1)) ∈ ℤ ∧ 1 ∈ ℤ) → (((𝐶↑(𝑁 − 1)) mod 𝑁) = (1 mod 𝑁) ↔ 𝑁 ∥ ((𝐶↑(𝑁 − 1)) − 1)))
10759, 75, 105, 106syl3anc 1367 . . . . . . . 8 (𝜑 → (((𝐶↑(𝑁 − 1)) mod 𝑁) = (1 mod 𝑁) ↔ 𝑁 ∥ ((𝐶↑(𝑁 − 1)) − 1)))
108104, 107mpbid 234 . . . . . . 7 (𝜑𝑁 ∥ ((𝐶↑(𝑁 − 1)) − 1))
109 peano2zm 12026 . . . . . . . . 9 ((𝐶↑(𝑁 − 1)) ∈ ℤ → ((𝐶↑(𝑁 − 1)) − 1) ∈ ℤ)
11075, 109syl 17 . . . . . . . 8 (𝜑 → ((𝐶↑(𝑁 − 1)) − 1) ∈ ℤ)
111 dvdstr 15646 . . . . . . . 8 ((𝑃 ∈ ℤ ∧ 𝑁 ∈ ℤ ∧ ((𝐶↑(𝑁 − 1)) − 1) ∈ ℤ) → ((𝑃𝑁𝑁 ∥ ((𝐶↑(𝑁 − 1)) − 1)) → 𝑃 ∥ ((𝐶↑(𝑁 − 1)) − 1)))
11246, 60, 110, 111syl3anc 1367 . . . . . . 7 (𝜑 → ((𝑃𝑁𝑁 ∥ ((𝐶↑(𝑁 − 1)) − 1)) → 𝑃 ∥ ((𝐶↑(𝑁 − 1)) − 1)))
11351, 108, 112mp2and 697 . . . . . 6 (𝜑𝑃 ∥ ((𝐶↑(𝑁 − 1)) − 1))
114 odzdvds 16132 . . . . . . 7 (((𝑃 ∈ ℕ ∧ 𝐶 ∈ ℤ ∧ (𝐶 gcd 𝑃) = 1) ∧ (𝑁 − 1) ∈ ℕ0) → (𝑃 ∥ ((𝐶↑(𝑁 − 1)) − 1) ↔ ((od𝑃)‘𝐶) ∥ (𝑁 − 1)))
11544, 45, 96, 73, 114syl31anc 1369 . . . . . 6 (𝜑 → (𝑃 ∥ ((𝐶↑(𝑁 − 1)) − 1) ↔ ((od𝑃)‘𝐶) ∥ (𝑁 − 1)))
116113, 115mpbid 234 . . . . 5 (𝜑 → ((od𝑃)‘𝐶) ∥ (𝑁 − 1))
11733nncnd 11654 . . . . . 6 (𝜑 → (𝑁 − 1) ∈ ℂ)
11823nncnd 11654 . . . . . 6 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∈ ℂ)
119117, 118, 38divcan1d 11417 . . . . 5 (𝜑 → (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))) = (𝑁 − 1))
120116, 119breqtrrd 5094 . . . 4 (𝜑 → ((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))))
121 nprmdvds1 16050 . . . . . 6 (𝑃 ∈ ℙ → ¬ 𝑃 ∥ 1)
12242, 121syl 17 . . . . 5 (𝜑 → ¬ 𝑃 ∥ 1)
12320nnzd 12087 . . . . . . . . . . . . . 14 (𝜑𝑄 ∈ ℤ)
124 iddvdsexp 15633 . . . . . . . . . . . . . 14 ((𝑄 ∈ ℤ ∧ (𝑄 pCnt 𝐴) ∈ ℕ) → 𝑄 ∥ (𝑄↑(𝑄 pCnt 𝐴)))
125123, 21, 124syl2anc 586 . . . . . . . . . . . . 13 (𝜑𝑄 ∥ (𝑄↑(𝑄 pCnt 𝐴)))
126 dvdstr 15646 . . . . . . . . . . . . . 14 ((𝑄 ∈ ℤ ∧ (𝑄↑(𝑄 pCnt 𝐴)) ∈ ℤ ∧ (𝑁 − 1) ∈ ℤ) → ((𝑄 ∥ (𝑄↑(𝑄 pCnt 𝐴)) ∧ (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1)) → 𝑄 ∥ (𝑁 − 1)))
127123, 24, 34, 126syl3anc 1367 . . . . . . . . . . . . 13 (𝜑 → ((𝑄 ∥ (𝑄↑(𝑄 pCnt 𝐴)) ∧ (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑁 − 1)) → 𝑄 ∥ (𝑁 − 1)))
128125, 37, 127mp2and 697 . . . . . . . . . . . 12 (𝜑𝑄 ∥ (𝑁 − 1))
12920nnne0d 11688 . . . . . . . . . . . . 13 (𝜑𝑄 ≠ 0)
130 dvdsval2 15610 . . . . . . . . . . . . 13 ((𝑄 ∈ ℤ ∧ 𝑄 ≠ 0 ∧ (𝑁 − 1) ∈ ℤ) → (𝑄 ∥ (𝑁 − 1) ↔ ((𝑁 − 1) / 𝑄) ∈ ℤ))
131123, 129, 34, 130syl3anc 1367 . . . . . . . . . . . 12 (𝜑 → (𝑄 ∥ (𝑁 − 1) ↔ ((𝑁 − 1) / 𝑄) ∈ ℤ))
132128, 131mpbid 234 . . . . . . . . . . 11 (𝜑 → ((𝑁 − 1) / 𝑄) ∈ ℤ)
13373nn0ge0d 11959 . . . . . . . . . . . 12 (𝜑 → 0 ≤ (𝑁 − 1))
13433nnred 11653 . . . . . . . . . . . . 13 (𝜑 → (𝑁 − 1) ∈ ℝ)
13520nnred 11653 . . . . . . . . . . . . 13 (𝜑𝑄 ∈ ℝ)
13620nngt0d 11687 . . . . . . . . . . . . 13 (𝜑 → 0 < 𝑄)
137 ge0div 11507 . . . . . . . . . . . . 13 (((𝑁 − 1) ∈ ℝ ∧ 𝑄 ∈ ℝ ∧ 0 < 𝑄) → (0 ≤ (𝑁 − 1) ↔ 0 ≤ ((𝑁 − 1) / 𝑄)))
138134, 135, 136, 137syl3anc 1367 . . . . . . . . . . . 12 (𝜑 → (0 ≤ (𝑁 − 1) ↔ 0 ≤ ((𝑁 − 1) / 𝑄)))
139133, 138mpbid 234 . . . . . . . . . . 11 (𝜑 → 0 ≤ ((𝑁 − 1) / 𝑄))
140 elnn0z 11995 . . . . . . . . . . 11 (((𝑁 − 1) / 𝑄) ∈ ℕ0 ↔ (((𝑁 − 1) / 𝑄) ∈ ℤ ∧ 0 ≤ ((𝑁 − 1) / 𝑄)))
141132, 139, 140sylanbrc 585 . . . . . . . . . 10 (𝜑 → ((𝑁 − 1) / 𝑄) ∈ ℕ0)
142 zexpcl 13445 . . . . . . . . . 10 ((𝐶 ∈ ℤ ∧ ((𝑁 − 1) / 𝑄) ∈ ℕ0) → (𝐶↑((𝑁 − 1) / 𝑄)) ∈ ℤ)
14345, 141, 142syl2anc 586 . . . . . . . . 9 (𝜑 → (𝐶↑((𝑁 − 1) / 𝑄)) ∈ ℤ)
144 peano2zm 12026 . . . . . . . . 9 ((𝐶↑((𝑁 − 1) / 𝑄)) ∈ ℤ → ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∈ ℤ)
145143, 144syl 17 . . . . . . . 8 (𝜑 → ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∈ ℤ)
146 dvdsgcd 15892 . . . . . . . 8 ((𝑃 ∈ ℤ ∧ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∈ ℤ ∧ 𝑁 ∈ ℤ) → ((𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∧ 𝑃𝑁) → 𝑃 ∥ (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁)))
14746, 145, 60, 146syl3anc 1367 . . . . . . 7 (𝜑 → ((𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ∧ 𝑃𝑁) → 𝑃 ∥ (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁)))
14851, 147mpan2d 692 . . . . . 6 (𝜑 → (𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) → 𝑃 ∥ (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁)))
149 odzdvds 16132 . . . . . . . 8 (((𝑃 ∈ ℕ ∧ 𝐶 ∈ ℤ ∧ (𝐶 gcd 𝑃) = 1) ∧ ((𝑁 − 1) / 𝑄) ∈ ℕ0) → (𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ↔ ((od𝑃)‘𝐶) ∥ ((𝑁 − 1) / 𝑄)))
15044, 45, 96, 141, 149syl31anc 1369 . . . . . . 7 (𝜑 → (𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ↔ ((od𝑃)‘𝐶) ∥ ((𝑁 − 1) / 𝑄)))
15120nncnd 11654 . . . . . . . . . . 11 (𝜑𝑄 ∈ ℂ)
15221nnzd 12087 . . . . . . . . . . 11 (𝜑 → (𝑄 pCnt 𝐴) ∈ ℤ)
153151, 129, 152expm1d 13521 . . . . . . . . . 10 (𝜑 → (𝑄↑((𝑄 pCnt 𝐴) − 1)) = ((𝑄↑(𝑄 pCnt 𝐴)) / 𝑄))
154153oveq2d 7172 . . . . . . . . 9 (𝜑 → (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))) = (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · ((𝑄↑(𝑄 pCnt 𝐴)) / 𝑄)))
155134, 23nndivred 11692 . . . . . . . . . . 11 (𝜑 → ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℝ)
156155recnd 10669 . . . . . . . . . 10 (𝜑 → ((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℂ)
157156, 118, 151, 129divassd 11451 . . . . . . . . 9 (𝜑 → ((((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))) / 𝑄) = (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · ((𝑄↑(𝑄 pCnt 𝐴)) / 𝑄)))
158119oveq1d 7171 . . . . . . . . 9 (𝜑 → ((((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))) / 𝑄) = ((𝑁 − 1) / 𝑄))
159154, 157, 1583eqtr2d 2862 . . . . . . . 8 (𝜑 → (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))) = ((𝑁 − 1) / 𝑄))
160159breq2d 5078 . . . . . . 7 (𝜑 → (((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))) ↔ ((od𝑃)‘𝐶) ∥ ((𝑁 − 1) / 𝑄)))
161150, 160bitr4d 284 . . . . . 6 (𝜑 → (𝑃 ∥ ((𝐶↑((𝑁 − 1) / 𝑄)) − 1) ↔ ((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1)))))
162 pockthlem.11 . . . . . . 7 (𝜑 → (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁) = 1)
163162breq2d 5078 . . . . . 6 (𝜑 → (𝑃 ∥ (((𝐶↑((𝑁 − 1) / 𝑄)) − 1) gcd 𝑁) ↔ 𝑃 ∥ 1))
164148, 161, 1633imtr3d 295 . . . . 5 (𝜑 → (((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))) → 𝑃 ∥ 1))
165122, 164mtod 200 . . . 4 (𝜑 → ¬ ((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))))
166 prmpwdvds 16240 . . . 4 (((((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) ∈ ℤ ∧ ((od𝑃)‘𝐶) ∈ ℤ) ∧ (𝑄 ∈ ℙ ∧ (𝑄 pCnt 𝐴) ∈ ℕ) ∧ (((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑(𝑄 pCnt 𝐴))) ∧ ¬ ((od𝑃)‘𝐶) ∥ (((𝑁 − 1) / (𝑄↑(𝑄 pCnt 𝐴))) · (𝑄↑((𝑄 pCnt 𝐴) − 1))))) → (𝑄↑(𝑄 pCnt 𝐴)) ∥ ((od𝑃)‘𝐶))
16741, 99, 1, 21, 120, 165, 166syl222anc 1382 . . 3 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∥ ((od𝑃)‘𝐶))
168 odzphi 16133 . . . . 5 ((𝑃 ∈ ℕ ∧ 𝐶 ∈ ℤ ∧ (𝐶 gcd 𝑃) = 1) → ((od𝑃)‘𝐶) ∥ (ϕ‘𝑃))
16944, 45, 96, 168syl3anc 1367 . . . 4 (𝜑 → ((od𝑃)‘𝐶) ∥ (ϕ‘𝑃))
170 phiprm 16114 . . . . 5 (𝑃 ∈ ℙ → (ϕ‘𝑃) = (𝑃 − 1))
17142, 170syl 17 . . . 4 (𝜑 → (ϕ‘𝑃) = (𝑃 − 1))
172169, 171breqtrd 5092 . . 3 (𝜑 → ((od𝑃)‘𝐶) ∥ (𝑃 − 1))
173 prmuz2 16040 . . . . . . . . 9 (𝑃 ∈ ℙ → 𝑃 ∈ (ℤ‘2))
17442, 173syl 17 . . . . . . . 8 (𝜑𝑃 ∈ (ℤ‘2))
175174, 55eleqtrdi 2923 . . . . . . 7 (𝜑𝑃 ∈ (ℤ‘(1 + 1)))
176 eluzp1m1 12269 . . . . . . 7 ((1 ∈ ℤ ∧ 𝑃 ∈ (ℤ‘(1 + 1))) → (𝑃 − 1) ∈ (ℤ‘1))
17725, 175, 176sylancr 589 . . . . . 6 (𝜑 → (𝑃 − 1) ∈ (ℤ‘1))
178177, 26eleqtrrdi 2924 . . . . 5 (𝜑 → (𝑃 − 1) ∈ ℕ)
179178nnzd 12087 . . . 4 (𝜑 → (𝑃 − 1) ∈ ℤ)
180 dvdstr 15646 . . . 4 (((𝑄↑(𝑄 pCnt 𝐴)) ∈ ℤ ∧ ((od𝑃)‘𝐶) ∈ ℤ ∧ (𝑃 − 1) ∈ ℤ) → (((𝑄↑(𝑄 pCnt 𝐴)) ∥ ((od𝑃)‘𝐶) ∧ ((od𝑃)‘𝐶) ∥ (𝑃 − 1)) → (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑃 − 1)))
18124, 99, 179, 180syl3anc 1367 . . 3 (𝜑 → (((𝑄↑(𝑄 pCnt 𝐴)) ∥ ((od𝑃)‘𝐶) ∧ ((od𝑃)‘𝐶) ∥ (𝑃 − 1)) → (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑃 − 1)))
182167, 172, 181mp2and 697 . 2 (𝜑 → (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑃 − 1))
183 pcdvdsb 16205 . . 3 ((𝑄 ∈ ℙ ∧ (𝑃 − 1) ∈ ℤ ∧ (𝑄 pCnt 𝐴) ∈ ℕ0) → ((𝑄 pCnt 𝐴) ≤ (𝑄 pCnt (𝑃 − 1)) ↔ (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑃 − 1)))
1841, 179, 22, 183syl3anc 1367 . 2 (𝜑 → ((𝑄 pCnt 𝐴) ≤ (𝑄 pCnt (𝑃 − 1)) ↔ (𝑄↑(𝑄 pCnt 𝐴)) ∥ (𝑃 − 1)))
185182, 184mpbird 259 1 (𝜑 → (𝑄 pCnt 𝐴) ≤ (𝑄 pCnt (𝑃 − 1)))
Colors of variables: wff setvar class
Syntax hints:  ¬ wn 3  wi 4  wb 208  wa 398   = wceq 1537  wcel 2114  wne 3016   class class class wbr 5066  cfv 6355  (class class class)co 7156  cc 10535  cr 10536  0cc0 10537  1c1 10538   + caddc 10540   · cmul 10542   < clt 10675  cle 10676  cmin 10870   / cdiv 11297  cn 11638  2c2 11693  0cn0 11898  cz 11982  cuz 12244   mod cmo 13238  cexp 13430  cdvds 15607   gcd cgcd 15843  cprime 16015  odcodz 16100  ϕcphi 16101   pCnt cpc 16173
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1796  ax-4 1810  ax-5 1911  ax-6 1970  ax-7 2015  ax-8 2116  ax-9 2124  ax-10 2145  ax-11 2161  ax-12 2177  ax-ext 2793  ax-rep 5190  ax-sep 5203  ax-nul 5210  ax-pow 5266  ax-pr 5330  ax-un 7461  ax-cnex 10593  ax-resscn 10594  ax-1cn 10595  ax-icn 10596  ax-addcl 10597  ax-addrcl 10598  ax-mulcl 10599  ax-mulrcl 10600  ax-mulcom 10601  ax-addass 10602  ax-mulass 10603  ax-distr 10604  ax-i2m1 10605  ax-1ne0 10606  ax-1rid 10607  ax-rnegex 10608  ax-rrecex 10609  ax-cnre 10610  ax-pre-lttri 10611  ax-pre-lttrn 10612  ax-pre-ltadd 10613  ax-pre-mulgt0 10614  ax-pre-sup 10615
This theorem depends on definitions:  df-bi 209  df-an 399  df-or 844  df-3or 1084  df-3an 1085  df-tru 1540  df-ex 1781  df-nf 1785  df-sb 2070  df-mo 2622  df-eu 2654  df-clab 2800  df-cleq 2814  df-clel 2893  df-nfc 2963  df-ne 3017  df-nel 3124  df-ral 3143  df-rex 3144  df-reu 3145  df-rmo 3146  df-rab 3147  df-v 3496  df-sbc 3773  df-csb 3884  df-dif 3939  df-un 3941  df-in 3943  df-ss 3952  df-pss 3954  df-nul 4292  df-if 4468  df-pw 4541  df-sn 4568  df-pr 4570  df-tp 4572  df-op 4574  df-uni 4839  df-int 4877  df-iun 4921  df-br 5067  df-opab 5129  df-mpt 5147  df-tr 5173  df-id 5460  df-eprel 5465  df-po 5474  df-so 5475  df-fr 5514  df-we 5516  df-xp 5561  df-rel 5562  df-cnv 5563  df-co 5564  df-dm 5565  df-rn 5566  df-res 5567  df-ima 5568  df-pred 6148  df-ord 6194  df-on 6195  df-lim 6196  df-suc 6197  df-iota 6314  df-fun 6357  df-fn 6358  df-f 6359  df-f1 6360  df-fo 6361  df-f1o 6362  df-fv 6363  df-riota 7114  df-ov 7159  df-oprab 7160  df-mpo 7161  df-om 7581  df-1st 7689  df-2nd 7690  df-wrecs 7947  df-recs 8008  df-rdg 8046  df-1o 8102  df-2o 8103  df-oadd 8106  df-er 8289  df-map 8408  df-en 8510  df-dom 8511  df-sdom 8512  df-fin 8513  df-sup 8906  df-inf 8907  df-dju 9330  df-card 9368  df-pnf 10677  df-mnf 10678  df-xr 10679  df-ltxr 10680  df-le 10681  df-sub 10872  df-neg 10873  df-div 11298  df-nn 11639  df-2 11701  df-3 11702  df-n0 11899  df-xnn0 11969  df-z 11983  df-uz 12245  df-q 12350  df-rp 12391  df-fz 12894  df-fzo 13035  df-fl 13163  df-mod 13239  df-seq 13371  df-exp 13431  df-hash 13692  df-cj 14458  df-re 14459  df-im 14460  df-sqrt 14594  df-abs 14595  df-dvds 15608  df-gcd 15844  df-prm 16016  df-odz 16102  df-phi 16103  df-pc 16174
This theorem is referenced by:  pockthg  16242
  Copyright terms: Public domain W3C validator