Proof of Theorem pcmpt2
Step | Hyp | Ref
| Expression |
1 | | pcmpt.4 |
. . 3
⊢ (𝜑 → 𝑃 ∈ ℙ) |
2 | | pcmpt.1 |
. . . . . . 7
⊢ 𝐹 = (𝑛 ∈ ℕ ↦ if(𝑛 ∈ ℙ, (𝑛↑𝐴), 1)) |
3 | | pcmpt.2 |
. . . . . . 7
⊢ (𝜑 → ∀𝑛 ∈ ℙ 𝐴 ∈
ℕ0) |
4 | 2, 3 | pcmptcl 16520 |
. . . . . 6
⊢ (𝜑 → (𝐹:ℕ⟶ℕ ∧ seq1( ·
, 𝐹):ℕ⟶ℕ)) |
5 | 4 | simprd 495 |
. . . . 5
⊢ (𝜑 → seq1( · , 𝐹):ℕ⟶ℕ) |
6 | | pcmpt.3 |
. . . . . 6
⊢ (𝜑 → 𝑁 ∈ ℕ) |
7 | | pcmpt2.6 |
. . . . . 6
⊢ (𝜑 → 𝑀 ∈ (ℤ≥‘𝑁)) |
8 | | eluznn 12587 |
. . . . . 6
⊢ ((𝑁 ∈ ℕ ∧ 𝑀 ∈
(ℤ≥‘𝑁)) → 𝑀 ∈ ℕ) |
9 | 6, 7, 8 | syl2anc 583 |
. . . . 5
⊢ (𝜑 → 𝑀 ∈ ℕ) |
10 | 5, 9 | ffvelrnd 6944 |
. . . 4
⊢ (𝜑 → (seq1( · , 𝐹)‘𝑀) ∈ ℕ) |
11 | 10 | nnzd 12354 |
. . 3
⊢ (𝜑 → (seq1( · , 𝐹)‘𝑀) ∈ ℤ) |
12 | 10 | nnne0d 11953 |
. . 3
⊢ (𝜑 → (seq1( · , 𝐹)‘𝑀) ≠ 0) |
13 | 5, 6 | ffvelrnd 6944 |
. . 3
⊢ (𝜑 → (seq1( · , 𝐹)‘𝑁) ∈ ℕ) |
14 | | pcdiv 16481 |
. . 3
⊢ ((𝑃 ∈ ℙ ∧ ((seq1(
· , 𝐹)‘𝑀) ∈ ℤ ∧ (seq1(
· , 𝐹)‘𝑀) ≠ 0) ∧ (seq1( ·
, 𝐹)‘𝑁) ∈ ℕ) → (𝑃 pCnt ((seq1( · , 𝐹)‘𝑀) / (seq1( · , 𝐹)‘𝑁))) = ((𝑃 pCnt (seq1( · , 𝐹)‘𝑀)) − (𝑃 pCnt (seq1( · , 𝐹)‘𝑁)))) |
15 | 1, 11, 12, 13, 14 | syl121anc 1373 |
. 2
⊢ (𝜑 → (𝑃 pCnt ((seq1( · , 𝐹)‘𝑀) / (seq1( · , 𝐹)‘𝑁))) = ((𝑃 pCnt (seq1( · , 𝐹)‘𝑀)) − (𝑃 pCnt (seq1( · , 𝐹)‘𝑁)))) |
16 | | pcmpt.5 |
. . . 4
⊢ (𝑛 = 𝑃 → 𝐴 = 𝐵) |
17 | 2, 3, 9, 1, 16 | pcmpt 16521 |
. . 3
⊢ (𝜑 → (𝑃 pCnt (seq1( · , 𝐹)‘𝑀)) = if(𝑃 ≤ 𝑀, 𝐵, 0)) |
18 | 2, 3, 6, 1, 16 | pcmpt 16521 |
. . 3
⊢ (𝜑 → (𝑃 pCnt (seq1( · , 𝐹)‘𝑁)) = if(𝑃 ≤ 𝑁, 𝐵, 0)) |
19 | 17, 18 | oveq12d 7273 |
. 2
⊢ (𝜑 → ((𝑃 pCnt (seq1( · , 𝐹)‘𝑀)) − (𝑃 pCnt (seq1( · , 𝐹)‘𝑁))) = (if(𝑃 ≤ 𝑀, 𝐵, 0) − if(𝑃 ≤ 𝑁, 𝐵, 0))) |
20 | 16 | eleq1d 2823 |
. . . . . . . 8
⊢ (𝑛 = 𝑃 → (𝐴 ∈ ℕ0 ↔ 𝐵 ∈
ℕ0)) |
21 | 20, 3, 1 | rspcdva 3554 |
. . . . . . 7
⊢ (𝜑 → 𝐵 ∈
ℕ0) |
22 | 21 | nn0cnd 12225 |
. . . . . 6
⊢ (𝜑 → 𝐵 ∈ ℂ) |
23 | 22 | subidd 11250 |
. . . . 5
⊢ (𝜑 → (𝐵 − 𝐵) = 0) |
24 | 23 | adantr 480 |
. . . 4
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → (𝐵 − 𝐵) = 0) |
25 | | prmnn 16307 |
. . . . . . . . . 10
⊢ (𝑃 ∈ ℙ → 𝑃 ∈
ℕ) |
26 | 1, 25 | syl 17 |
. . . . . . . . 9
⊢ (𝜑 → 𝑃 ∈ ℕ) |
27 | 26 | nnred 11918 |
. . . . . . . 8
⊢ (𝜑 → 𝑃 ∈ ℝ) |
28 | 27 | adantr 480 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → 𝑃 ∈ ℝ) |
29 | 6 | nnred 11918 |
. . . . . . . 8
⊢ (𝜑 → 𝑁 ∈ ℝ) |
30 | 29 | adantr 480 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → 𝑁 ∈ ℝ) |
31 | 9 | nnred 11918 |
. . . . . . . 8
⊢ (𝜑 → 𝑀 ∈ ℝ) |
32 | 31 | adantr 480 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → 𝑀 ∈ ℝ) |
33 | | simpr 484 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → 𝑃 ≤ 𝑁) |
34 | | eluzle 12524 |
. . . . . . . . 9
⊢ (𝑀 ∈
(ℤ≥‘𝑁) → 𝑁 ≤ 𝑀) |
35 | 7, 34 | syl 17 |
. . . . . . . 8
⊢ (𝜑 → 𝑁 ≤ 𝑀) |
36 | 35 | adantr 480 |
. . . . . . 7
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → 𝑁 ≤ 𝑀) |
37 | 28, 30, 32, 33, 36 | letrd 11062 |
. . . . . 6
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → 𝑃 ≤ 𝑀) |
38 | 37 | iftrued 4464 |
. . . . 5
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → if(𝑃 ≤ 𝑀, 𝐵, 0) = 𝐵) |
39 | | iftrue 4462 |
. . . . . 6
⊢ (𝑃 ≤ 𝑁 → if(𝑃 ≤ 𝑁, 𝐵, 0) = 𝐵) |
40 | 39 | adantl 481 |
. . . . 5
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → if(𝑃 ≤ 𝑁, 𝐵, 0) = 𝐵) |
41 | 38, 40 | oveq12d 7273 |
. . . 4
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → (if(𝑃 ≤ 𝑀, 𝐵, 0) − if(𝑃 ≤ 𝑁, 𝐵, 0)) = (𝐵 − 𝐵)) |
42 | | simpr 484 |
. . . . . 6
⊢ ((𝑃 ≤ 𝑀 ∧ ¬ 𝑃 ≤ 𝑁) → ¬ 𝑃 ≤ 𝑁) |
43 | 42, 33 | nsyl3 138 |
. . . . 5
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → ¬ (𝑃 ≤ 𝑀 ∧ ¬ 𝑃 ≤ 𝑁)) |
44 | 43 | iffalsed 4467 |
. . . 4
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → if((𝑃 ≤ 𝑀 ∧ ¬ 𝑃 ≤ 𝑁), 𝐵, 0) = 0) |
45 | 24, 41, 44 | 3eqtr4d 2788 |
. . 3
⊢ ((𝜑 ∧ 𝑃 ≤ 𝑁) → (if(𝑃 ≤ 𝑀, 𝐵, 0) − if(𝑃 ≤ 𝑁, 𝐵, 0)) = if((𝑃 ≤ 𝑀 ∧ ¬ 𝑃 ≤ 𝑁), 𝐵, 0)) |
46 | | iffalse 4465 |
. . . . . 6
⊢ (¬
𝑃 ≤ 𝑁 → if(𝑃 ≤ 𝑁, 𝐵, 0) = 0) |
47 | 46 | oveq2d 7271 |
. . . . 5
⊢ (¬
𝑃 ≤ 𝑁 → (if(𝑃 ≤ 𝑀, 𝐵, 0) − if(𝑃 ≤ 𝑁, 𝐵, 0)) = (if(𝑃 ≤ 𝑀, 𝐵, 0) − 0)) |
48 | | 0cn 10898 |
. . . . . . 7
⊢ 0 ∈
ℂ |
49 | | ifcl 4501 |
. . . . . . 7
⊢ ((𝐵 ∈ ℂ ∧ 0 ∈
ℂ) → if(𝑃 ≤
𝑀, 𝐵, 0) ∈ ℂ) |
50 | 22, 48, 49 | sylancl 585 |
. . . . . 6
⊢ (𝜑 → if(𝑃 ≤ 𝑀, 𝐵, 0) ∈ ℂ) |
51 | 50 | subid1d 11251 |
. . . . 5
⊢ (𝜑 → (if(𝑃 ≤ 𝑀, 𝐵, 0) − 0) = if(𝑃 ≤ 𝑀, 𝐵, 0)) |
52 | 47, 51 | sylan9eqr 2801 |
. . . 4
⊢ ((𝜑 ∧ ¬ 𝑃 ≤ 𝑁) → (if(𝑃 ≤ 𝑀, 𝐵, 0) − if(𝑃 ≤ 𝑁, 𝐵, 0)) = if(𝑃 ≤ 𝑀, 𝐵, 0)) |
53 | | simpr 484 |
. . . . . 6
⊢ ((𝜑 ∧ ¬ 𝑃 ≤ 𝑁) → ¬ 𝑃 ≤ 𝑁) |
54 | 53 | biantrud 531 |
. . . . 5
⊢ ((𝜑 ∧ ¬ 𝑃 ≤ 𝑁) → (𝑃 ≤ 𝑀 ↔ (𝑃 ≤ 𝑀 ∧ ¬ 𝑃 ≤ 𝑁))) |
55 | 54 | ifbid 4479 |
. . . 4
⊢ ((𝜑 ∧ ¬ 𝑃 ≤ 𝑁) → if(𝑃 ≤ 𝑀, 𝐵, 0) = if((𝑃 ≤ 𝑀 ∧ ¬ 𝑃 ≤ 𝑁), 𝐵, 0)) |
56 | 52, 55 | eqtrd 2778 |
. . 3
⊢ ((𝜑 ∧ ¬ 𝑃 ≤ 𝑁) → (if(𝑃 ≤ 𝑀, 𝐵, 0) − if(𝑃 ≤ 𝑁, 𝐵, 0)) = if((𝑃 ≤ 𝑀 ∧ ¬ 𝑃 ≤ 𝑁), 𝐵, 0)) |
57 | 45, 56 | pm2.61dan 809 |
. 2
⊢ (𝜑 → (if(𝑃 ≤ 𝑀, 𝐵, 0) − if(𝑃 ≤ 𝑁, 𝐵, 0)) = if((𝑃 ≤ 𝑀 ∧ ¬ 𝑃 ≤ 𝑁), 𝐵, 0)) |
58 | 15, 19, 57 | 3eqtrd 2782 |
1
⊢ (𝜑 → (𝑃 pCnt ((seq1( · , 𝐹)‘𝑀) / (seq1( · , 𝐹)‘𝑁))) = if((𝑃 ≤ 𝑀 ∧ ¬ 𝑃 ≤ 𝑁), 𝐵, 0)) |