Step | Hyp | Ref
| Expression |
1 | | eulerth.4 |
. . . 4
⊢ (𝜑 → 𝐹:(1...(ϕ‘𝑁))–1-1-onto→𝑆) |
2 | | f1ocnv 5453 |
. . . 4
⊢ (𝐹:(1...(ϕ‘𝑁))–1-1-onto→𝑆 → ◡𝐹:𝑆–1-1-onto→(1...(ϕ‘𝑁))) |
3 | 1, 2 | syl 14 |
. . 3
⊢ (𝜑 → ◡𝐹:𝑆–1-1-onto→(1...(ϕ‘𝑁))) |
4 | | eulerth.1 |
. . . . . . 7
⊢ (𝜑 → (𝑁 ∈ ℕ ∧ 𝐴 ∈ ℤ ∧ (𝐴 gcd 𝑁) = 1)) |
5 | | eulerth.2 |
. . . . . . 7
⊢ 𝑆 = {𝑦 ∈ (0..^𝑁) ∣ (𝑦 gcd 𝑁) = 1} |
6 | | eqid 2170 |
. . . . . . 7
⊢
(1...(ϕ‘𝑁)) = (1...(ϕ‘𝑁)) |
7 | | fveq2 5494 |
. . . . . . . . . 10
⊢ (𝑎 = 𝑏 → (𝐹‘𝑎) = (𝐹‘𝑏)) |
8 | 7 | oveq2d 5866 |
. . . . . . . . 9
⊢ (𝑎 = 𝑏 → (𝐴 · (𝐹‘𝑎)) = (𝐴 · (𝐹‘𝑏))) |
9 | 8 | oveq1d 5865 |
. . . . . . . 8
⊢ (𝑎 = 𝑏 → ((𝐴 · (𝐹‘𝑎)) mod 𝑁) = ((𝐴 · (𝐹‘𝑏)) mod 𝑁)) |
10 | 9 | cbvmptv 4083 |
. . . . . . 7
⊢ (𝑎 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑎)) mod 𝑁)) = (𝑏 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑏)) mod 𝑁)) |
11 | 4, 5, 6, 1, 10 | eulerthlem1 12168 |
. . . . . 6
⊢ (𝜑 → (𝑎 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑎)) mod 𝑁)):(1...(ϕ‘𝑁))⟶𝑆) |
12 | | fveq2 5494 |
. . . . . . . . . 10
⊢ (𝑎 = 𝑦 → (𝐹‘𝑎) = (𝐹‘𝑦)) |
13 | 12 | oveq2d 5866 |
. . . . . . . . 9
⊢ (𝑎 = 𝑦 → (𝐴 · (𝐹‘𝑎)) = (𝐴 · (𝐹‘𝑦))) |
14 | 13 | oveq1d 5865 |
. . . . . . . 8
⊢ (𝑎 = 𝑦 → ((𝐴 · (𝐹‘𝑎)) mod 𝑁) = ((𝐴 · (𝐹‘𝑦)) mod 𝑁)) |
15 | 14 | cbvmptv 4083 |
. . . . . . 7
⊢ (𝑎 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑎)) mod 𝑁)) = (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)) |
16 | 15 | feq1i 5338 |
. . . . . 6
⊢ ((𝑎 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑎)) mod 𝑁)):(1...(ϕ‘𝑁))⟶𝑆 ↔ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))⟶𝑆) |
17 | 11, 16 | sylib 121 |
. . . . 5
⊢ (𝜑 → (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))⟶𝑆) |
18 | 4 | simp1d 1004 |
. . . . . . . . . 10
⊢ (𝜑 → 𝑁 ∈ ℕ) |
19 | 18 | adantr 274 |
. . . . . . . . 9
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 𝑁 ∈ ℕ) |
20 | 4 | simp2d 1005 |
. . . . . . . . . . 11
⊢ (𝜑 → 𝐴 ∈ ℤ) |
21 | 20 | adantr 274 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 𝐴 ∈ ℤ) |
22 | | ssrab2 3232 |
. . . . . . . . . . . . 13
⊢ {𝑦 ∈ (0..^𝑁) ∣ (𝑦 gcd 𝑁) = 1} ⊆ (0..^𝑁) |
23 | 5, 22 | eqsstri 3179 |
. . . . . . . . . . . 12
⊢ 𝑆 ⊆ (0..^𝑁) |
24 | | fzo0ssnn0 10158 |
. . . . . . . . . . . . 13
⊢
(0..^𝑁) ⊆
ℕ0 |
25 | | nn0ssz 9217 |
. . . . . . . . . . . . 13
⊢
ℕ0 ⊆ ℤ |
26 | 24, 25 | sstri 3156 |
. . . . . . . . . . . 12
⊢
(0..^𝑁) ⊆
ℤ |
27 | 23, 26 | sstri 3156 |
. . . . . . . . . . 11
⊢ 𝑆 ⊆
ℤ |
28 | | f1of 5440 |
. . . . . . . . . . . . . 14
⊢ (𝐹:(1...(ϕ‘𝑁))–1-1-onto→𝑆 → 𝐹:(1...(ϕ‘𝑁))⟶𝑆) |
29 | 1, 28 | syl 14 |
. . . . . . . . . . . . 13
⊢ (𝜑 → 𝐹:(1...(ϕ‘𝑁))⟶𝑆) |
30 | 29 | adantr 274 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 𝐹:(1...(ϕ‘𝑁))⟶𝑆) |
31 | | simprl 526 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 𝑢 ∈ (1...(ϕ‘𝑁))) |
32 | 30, 31 | ffvelrnd 5629 |
. . . . . . . . . . 11
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑢) ∈ 𝑆) |
33 | 27, 32 | sselid 3145 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑢) ∈ ℤ) |
34 | 21, 33 | zmulcld 9327 |
. . . . . . . . 9
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐴 · (𝐹‘𝑢)) ∈ ℤ) |
35 | 29 | ffvelrnda 5628 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ 𝑣 ∈ (1...(ϕ‘𝑁))) → (𝐹‘𝑣) ∈ 𝑆) |
36 | 35 | adantrl 475 |
. . . . . . . . . . 11
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑣) ∈ 𝑆) |
37 | 27, 36 | sselid 3145 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑣) ∈ ℤ) |
38 | 21, 37 | zmulcld 9327 |
. . . . . . . . 9
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐴 · (𝐹‘𝑣)) ∈ ℤ) |
39 | | moddvds 11748 |
. . . . . . . . 9
⊢ ((𝑁 ∈ ℕ ∧ (𝐴 · (𝐹‘𝑢)) ∈ ℤ ∧ (𝐴 · (𝐹‘𝑣)) ∈ ℤ) → (((𝐴 · (𝐹‘𝑢)) mod 𝑁) = ((𝐴 · (𝐹‘𝑣)) mod 𝑁) ↔ 𝑁 ∥ ((𝐴 · (𝐹‘𝑢)) − (𝐴 · (𝐹‘𝑣))))) |
40 | 19, 34, 38, 39 | syl3anc 1233 |
. . . . . . . 8
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (((𝐴 · (𝐹‘𝑢)) mod 𝑁) = ((𝐴 · (𝐹‘𝑣)) mod 𝑁) ↔ 𝑁 ∥ ((𝐴 · (𝐹‘𝑢)) − (𝐴 · (𝐹‘𝑣))))) |
41 | | eqid 2170 |
. . . . . . . . . 10
⊢ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)) = (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)) |
42 | | fveq2 5494 |
. . . . . . . . . . . 12
⊢ (𝑦 = 𝑢 → (𝐹‘𝑦) = (𝐹‘𝑢)) |
43 | 42 | oveq2d 5866 |
. . . . . . . . . . 11
⊢ (𝑦 = 𝑢 → (𝐴 · (𝐹‘𝑦)) = (𝐴 · (𝐹‘𝑢))) |
44 | 43 | oveq1d 5865 |
. . . . . . . . . 10
⊢ (𝑦 = 𝑢 → ((𝐴 · (𝐹‘𝑦)) mod 𝑁) = ((𝐴 · (𝐹‘𝑢)) mod 𝑁)) |
45 | | zmodfzo 10290 |
. . . . . . . . . . 11
⊢ (((𝐴 · (𝐹‘𝑢)) ∈ ℤ ∧ 𝑁 ∈ ℕ) → ((𝐴 · (𝐹‘𝑢)) mod 𝑁) ∈ (0..^𝑁)) |
46 | 34, 19, 45 | syl2anc 409 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝐴 · (𝐹‘𝑢)) mod 𝑁) ∈ (0..^𝑁)) |
47 | 41, 44, 31, 46 | fvmptd3 5587 |
. . . . . . . . 9
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑢) = ((𝐴 · (𝐹‘𝑢)) mod 𝑁)) |
48 | | fveq2 5494 |
. . . . . . . . . . . 12
⊢ (𝑦 = 𝑣 → (𝐹‘𝑦) = (𝐹‘𝑣)) |
49 | 48 | oveq2d 5866 |
. . . . . . . . . . 11
⊢ (𝑦 = 𝑣 → (𝐴 · (𝐹‘𝑦)) = (𝐴 · (𝐹‘𝑣))) |
50 | 49 | oveq1d 5865 |
. . . . . . . . . 10
⊢ (𝑦 = 𝑣 → ((𝐴 · (𝐹‘𝑦)) mod 𝑁) = ((𝐴 · (𝐹‘𝑣)) mod 𝑁)) |
51 | | simprr 527 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 𝑣 ∈ (1...(ϕ‘𝑁))) |
52 | | zmodfzo 10290 |
. . . . . . . . . . 11
⊢ (((𝐴 · (𝐹‘𝑣)) ∈ ℤ ∧ 𝑁 ∈ ℕ) → ((𝐴 · (𝐹‘𝑣)) mod 𝑁) ∈ (0..^𝑁)) |
53 | 38, 19, 52 | syl2anc 409 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝐴 · (𝐹‘𝑣)) mod 𝑁) ∈ (0..^𝑁)) |
54 | 41, 50, 51, 53 | fvmptd3 5587 |
. . . . . . . . 9
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑣) = ((𝐴 · (𝐹‘𝑣)) mod 𝑁)) |
55 | 47, 54 | eqeq12d 2185 |
. . . . . . . 8
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑢) = ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑣) ↔ ((𝐴 · (𝐹‘𝑢)) mod 𝑁) = ((𝐴 · (𝐹‘𝑣)) mod 𝑁))) |
56 | 21 | zcnd 9322 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 𝐴 ∈ ℂ) |
57 | 33 | zcnd 9322 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑢) ∈ ℂ) |
58 | 37 | zcnd 9322 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑣) ∈ ℂ) |
59 | 56, 57, 58 | subdid 8320 |
. . . . . . . . 9
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐴 · ((𝐹‘𝑢) − (𝐹‘𝑣))) = ((𝐴 · (𝐹‘𝑢)) − (𝐴 · (𝐹‘𝑣)))) |
60 | 59 | breq2d 3999 |
. . . . . . . 8
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝑁 ∥ (𝐴 · ((𝐹‘𝑢) − (𝐹‘𝑣))) ↔ 𝑁 ∥ ((𝐴 · (𝐹‘𝑢)) − (𝐴 · (𝐹‘𝑣))))) |
61 | 40, 55, 60 | 3bitr4d 219 |
. . . . . . 7
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑢) = ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑣) ↔ 𝑁 ∥ (𝐴 · ((𝐹‘𝑢) − (𝐹‘𝑣))))) |
62 | 18 | nnzd 9320 |
. . . . . . . . . . 11
⊢ (𝜑 → 𝑁 ∈ ℤ) |
63 | 62, 20 | gcdcomd 11916 |
. . . . . . . . . 10
⊢ (𝜑 → (𝑁 gcd 𝐴) = (𝐴 gcd 𝑁)) |
64 | 4 | simp3d 1006 |
. . . . . . . . . 10
⊢ (𝜑 → (𝐴 gcd 𝑁) = 1) |
65 | 63, 64 | eqtrd 2203 |
. . . . . . . . 9
⊢ (𝜑 → (𝑁 gcd 𝐴) = 1) |
66 | 65 | adantr 274 |
. . . . . . . 8
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝑁 gcd 𝐴) = 1) |
67 | 62 | adantr 274 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 𝑁 ∈ ℤ) |
68 | 33, 37 | zsubcld 9326 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝐹‘𝑢) − (𝐹‘𝑣)) ∈ ℤ) |
69 | | coprmdvds 12033 |
. . . . . . . . . 10
⊢ ((𝑁 ∈ ℤ ∧ 𝐴 ∈ ℤ ∧ ((𝐹‘𝑢) − (𝐹‘𝑣)) ∈ ℤ) → ((𝑁 ∥ (𝐴 · ((𝐹‘𝑢) − (𝐹‘𝑣))) ∧ (𝑁 gcd 𝐴) = 1) → 𝑁 ∥ ((𝐹‘𝑢) − (𝐹‘𝑣)))) |
70 | 67, 21, 68, 69 | syl3anc 1233 |
. . . . . . . . 9
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝑁 ∥ (𝐴 · ((𝐹‘𝑢) − (𝐹‘𝑣))) ∧ (𝑁 gcd 𝐴) = 1) → 𝑁 ∥ ((𝐹‘𝑢) − (𝐹‘𝑣)))) |
71 | | zq 9572 |
. . . . . . . . . . . . 13
⊢ ((𝐹‘𝑢) ∈ ℤ → (𝐹‘𝑢) ∈ ℚ) |
72 | 33, 71 | syl 14 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑢) ∈ ℚ) |
73 | | zq 9572 |
. . . . . . . . . . . . . 14
⊢ (𝑁 ∈ ℤ → 𝑁 ∈
ℚ) |
74 | 62, 73 | syl 14 |
. . . . . . . . . . . . 13
⊢ (𝜑 → 𝑁 ∈ ℚ) |
75 | 74 | adantr 274 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 𝑁 ∈ ℚ) |
76 | 23, 32 | sselid 3145 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑢) ∈ (0..^𝑁)) |
77 | | elfzole1 10098 |
. . . . . . . . . . . . 13
⊢ ((𝐹‘𝑢) ∈ (0..^𝑁) → 0 ≤ (𝐹‘𝑢)) |
78 | 76, 77 | syl 14 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 0 ≤ (𝐹‘𝑢)) |
79 | | elfzolt2 10099 |
. . . . . . . . . . . . 13
⊢ ((𝐹‘𝑢) ∈ (0..^𝑁) → (𝐹‘𝑢) < 𝑁) |
80 | 76, 79 | syl 14 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑢) < 𝑁) |
81 | | modqid 10292 |
. . . . . . . . . . . 12
⊢ ((((𝐹‘𝑢) ∈ ℚ ∧ 𝑁 ∈ ℚ) ∧ (0 ≤ (𝐹‘𝑢) ∧ (𝐹‘𝑢) < 𝑁)) → ((𝐹‘𝑢) mod 𝑁) = (𝐹‘𝑢)) |
82 | 72, 75, 78, 80, 81 | syl22anc 1234 |
. . . . . . . . . . 11
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝐹‘𝑢) mod 𝑁) = (𝐹‘𝑢)) |
83 | 27, 35 | sselid 3145 |
. . . . . . . . . . . . . 14
⊢ ((𝜑 ∧ 𝑣 ∈ (1...(ϕ‘𝑁))) → (𝐹‘𝑣) ∈ ℤ) |
84 | 83 | adantrl 475 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑣) ∈ ℤ) |
85 | | zq 9572 |
. . . . . . . . . . . . 13
⊢ ((𝐹‘𝑣) ∈ ℤ → (𝐹‘𝑣) ∈ ℚ) |
86 | 84, 85 | syl 14 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑣) ∈ ℚ) |
87 | 23, 35 | sselid 3145 |
. . . . . . . . . . . . . 14
⊢ ((𝜑 ∧ 𝑣 ∈ (1...(ϕ‘𝑁))) → (𝐹‘𝑣) ∈ (0..^𝑁)) |
88 | | elfzole1 10098 |
. . . . . . . . . . . . . 14
⊢ ((𝐹‘𝑣) ∈ (0..^𝑁) → 0 ≤ (𝐹‘𝑣)) |
89 | 87, 88 | syl 14 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ 𝑣 ∈ (1...(ϕ‘𝑁))) → 0 ≤ (𝐹‘𝑣)) |
90 | 89 | adantrl 475 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → 0 ≤ (𝐹‘𝑣)) |
91 | 87 | adantrl 475 |
. . . . . . . . . . . . 13
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑣) ∈ (0..^𝑁)) |
92 | | elfzolt2 10099 |
. . . . . . . . . . . . 13
⊢ ((𝐹‘𝑣) ∈ (0..^𝑁) → (𝐹‘𝑣) < 𝑁) |
93 | 91, 92 | syl 14 |
. . . . . . . . . . . 12
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝐹‘𝑣) < 𝑁) |
94 | | modqid 10292 |
. . . . . . . . . . . 12
⊢ ((((𝐹‘𝑣) ∈ ℚ ∧ 𝑁 ∈ ℚ) ∧ (0 ≤ (𝐹‘𝑣) ∧ (𝐹‘𝑣) < 𝑁)) → ((𝐹‘𝑣) mod 𝑁) = (𝐹‘𝑣)) |
95 | 86, 75, 90, 93, 94 | syl22anc 1234 |
. . . . . . . . . . 11
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝐹‘𝑣) mod 𝑁) = (𝐹‘𝑣)) |
96 | 82, 95 | eqeq12d 2185 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (((𝐹‘𝑢) mod 𝑁) = ((𝐹‘𝑣) mod 𝑁) ↔ (𝐹‘𝑢) = (𝐹‘𝑣))) |
97 | | moddvds 11748 |
. . . . . . . . . . 11
⊢ ((𝑁 ∈ ℕ ∧ (𝐹‘𝑢) ∈ ℤ ∧ (𝐹‘𝑣) ∈ ℤ) → (((𝐹‘𝑢) mod 𝑁) = ((𝐹‘𝑣) mod 𝑁) ↔ 𝑁 ∥ ((𝐹‘𝑢) − (𝐹‘𝑣)))) |
98 | 19, 33, 37, 97 | syl3anc 1233 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (((𝐹‘𝑢) mod 𝑁) = ((𝐹‘𝑣) mod 𝑁) ↔ 𝑁 ∥ ((𝐹‘𝑢) − (𝐹‘𝑣)))) |
99 | | f1of1 5439 |
. . . . . . . . . . . 12
⊢ (𝐹:(1...(ϕ‘𝑁))–1-1-onto→𝑆 → 𝐹:(1...(ϕ‘𝑁))–1-1→𝑆) |
100 | 1, 99 | syl 14 |
. . . . . . . . . . 11
⊢ (𝜑 → 𝐹:(1...(ϕ‘𝑁))–1-1→𝑆) |
101 | | f1fveq 5748 |
. . . . . . . . . . 11
⊢ ((𝐹:(1...(ϕ‘𝑁))–1-1→𝑆 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝐹‘𝑢) = (𝐹‘𝑣) ↔ 𝑢 = 𝑣)) |
102 | 100, 101 | sylan 281 |
. . . . . . . . . 10
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝐹‘𝑢) = (𝐹‘𝑣) ↔ 𝑢 = 𝑣)) |
103 | 96, 98, 102 | 3bitr3d 217 |
. . . . . . . . 9
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝑁 ∥ ((𝐹‘𝑢) − (𝐹‘𝑣)) ↔ 𝑢 = 𝑣)) |
104 | 70, 103 | sylibd 148 |
. . . . . . . 8
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → ((𝑁 ∥ (𝐴 · ((𝐹‘𝑢) − (𝐹‘𝑣))) ∧ (𝑁 gcd 𝐴) = 1) → 𝑢 = 𝑣)) |
105 | 66, 104 | mpan2d 426 |
. . . . . . 7
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (𝑁 ∥ (𝐴 · ((𝐹‘𝑢) − (𝐹‘𝑣))) → 𝑢 = 𝑣)) |
106 | 61, 105 | sylbid 149 |
. . . . . 6
⊢ ((𝜑 ∧ (𝑢 ∈ (1...(ϕ‘𝑁)) ∧ 𝑣 ∈ (1...(ϕ‘𝑁)))) → (((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑢) = ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑣) → 𝑢 = 𝑣)) |
107 | 106 | ralrimivva 2552 |
. . . . 5
⊢ (𝜑 → ∀𝑢 ∈ (1...(ϕ‘𝑁))∀𝑣 ∈ (1...(ϕ‘𝑁))(((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑢) = ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑣) → 𝑢 = 𝑣)) |
108 | | dff13 5744 |
. . . . 5
⊢ ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))–1-1→𝑆 ↔ ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))⟶𝑆 ∧ ∀𝑢 ∈ (1...(ϕ‘𝑁))∀𝑣 ∈ (1...(ϕ‘𝑁))(((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑢) = ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))‘𝑣) → 𝑢 = 𝑣))) |
109 | 17, 107, 108 | sylanbrc 415 |
. . . 4
⊢ (𝜑 → (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))–1-1→𝑆) |
110 | | 1zzd 9226 |
. . . . . . 7
⊢ (𝜑 → 1 ∈
ℤ) |
111 | 18 | phicld 12159 |
. . . . . . . 8
⊢ (𝜑 → (ϕ‘𝑁) ∈
ℕ) |
112 | 111 | nnzd 9320 |
. . . . . . 7
⊢ (𝜑 → (ϕ‘𝑁) ∈
ℤ) |
113 | 110, 112 | fzfigd 10374 |
. . . . . 6
⊢ (𝜑 → (1...(ϕ‘𝑁)) ∈ Fin) |
114 | | f1oeng 6731 |
. . . . . 6
⊢
(((1...(ϕ‘𝑁)) ∈ Fin ∧ 𝐹:(1...(ϕ‘𝑁))–1-1-onto→𝑆) →
(1...(ϕ‘𝑁))
≈ 𝑆) |
115 | 113, 1, 114 | syl2anc 409 |
. . . . 5
⊢ (𝜑 → (1...(ϕ‘𝑁)) ≈ 𝑆) |
116 | 4, 5 | eulerthlemfi 12169 |
. . . . 5
⊢ (𝜑 → 𝑆 ∈ Fin) |
117 | | f1finf1o 6920 |
. . . . 5
⊢
(((1...(ϕ‘𝑁)) ≈ 𝑆 ∧ 𝑆 ∈ Fin) → ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))–1-1→𝑆 ↔ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))–1-1-onto→𝑆)) |
118 | 115, 116,
117 | syl2anc 409 |
. . . 4
⊢ (𝜑 → ((𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))–1-1→𝑆 ↔ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))–1-1-onto→𝑆)) |
119 | 109, 118 | mpbid 146 |
. . 3
⊢ (𝜑 → (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))–1-1-onto→𝑆) |
120 | | f1oco 5463 |
. . 3
⊢ ((◡𝐹:𝑆–1-1-onto→(1...(ϕ‘𝑁)) ∧ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁)):(1...(ϕ‘𝑁))–1-1-onto→𝑆) → (◡𝐹 ∘ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))):(1...(ϕ‘𝑁))–1-1-onto→(1...(ϕ‘𝑁))) |
121 | 3, 119, 120 | syl2anc 409 |
. 2
⊢ (𝜑 → (◡𝐹 ∘ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))):(1...(ϕ‘𝑁))–1-1-onto→(1...(ϕ‘𝑁))) |
122 | | eulerth.h |
. . 3
⊢ 𝐻 = (◡𝐹 ∘ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))) |
123 | | f1oeq1 5429 |
. . 3
⊢ (𝐻 = (◡𝐹 ∘ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))) → (𝐻:(1...(ϕ‘𝑁))–1-1-onto→(1...(ϕ‘𝑁)) ↔ (◡𝐹 ∘ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))):(1...(ϕ‘𝑁))–1-1-onto→(1...(ϕ‘𝑁)))) |
124 | 122, 123 | ax-mp 5 |
. 2
⊢ (𝐻:(1...(ϕ‘𝑁))–1-1-onto→(1...(ϕ‘𝑁)) ↔ (◡𝐹 ∘ (𝑦 ∈ (1...(ϕ‘𝑁)) ↦ ((𝐴 · (𝐹‘𝑦)) mod 𝑁))):(1...(ϕ‘𝑁))–1-1-onto→(1...(ϕ‘𝑁))) |
125 | 121, 124 | sylibr 133 |
1
⊢ (𝜑 → 𝐻:(1...(ϕ‘𝑁))–1-1-onto→(1...(ϕ‘𝑁))) |