Metamath Proof Explorer


Theorem fsumvma

Description: Rewrite a sum over the von Mangoldt function as a sum over prime powers. (Contributed by Mario Carneiro, 15-Apr-2016)

Ref Expression
Hypotheses fsumvma.1 x = p k B = C
fsumvma.2 φ A Fin
fsumvma.3 φ A
fsumvma.4 φ P Fin
fsumvma.5 φ p P k K p k p k A
fsumvma.6 φ x A B
fsumvma.7 φ x A Λ x = 0 B = 0
Assertion fsumvma φ x A B = p P k K C

Proof

Step Hyp Ref Expression
1 fsumvma.1 x = p k B = C
2 fsumvma.2 φ A Fin
3 fsumvma.3 φ A
4 fsumvma.4 φ P Fin
5 fsumvma.5 φ p P k K p k p k A
6 fsumvma.6 φ x A B
7 fsumvma.7 φ x A Λ x = 0 B = 0
8 fvexd z = p k ^ z V
9 fveq2 z = p k ^ z = ^ p k
10 df-ov p k = ^ p k
11 9 10 eqtr4di z = p k ^ z = p k
12 11 eqeq2d z = p k x = ^ z x = p k
13 12 biimpa z = p k x = ^ z x = p k
14 13 1 syl z = p k x = ^ z B = C
15 8 14 csbied z = p k ^ z / x B = C
16 2 adantr φ p P A Fin
17 5 biimpd φ p P k K p k p k A
18 17 impl φ p P k K p k p k A
19 18 simprd φ p P k K p k A
20 19 ex φ p P k K p k A
21 18 simpld φ p P k K p k
22 21 simpld φ p P k K p
23 22 adantrr φ p P k K z K p
24 21 simprd φ p P k K k
25 24 adantrr φ p P k K z K k
26 24 ex φ p P k K k
27 26 ssrdv φ p P K
28 27 sselda φ p P z K z
29 28 adantrl φ p P k K z K z
30 eqid p = p
31 prmexpb p p k z p k = p z p = p k = z
32 31 baibd p p k z p = p p k = p z k = z
33 30 32 mpan2 p p k z p k = p z k = z
34 23 23 25 29 33 syl22anc φ p P k K z K p k = p z k = z
35 34 ex φ p P k K z K p k = p z k = z
36 20 35 dom2lem φ p P k K p k : K 1-1 A
37 f1fi A Fin k K p k : K 1-1 A K Fin
38 16 36 37 syl2anc φ p P K Fin
39 1 eleq1d x = p k B C
40 6 ralrimiva φ x A B
41 40 adantr φ p P k K x A B
42 5 simplbda φ p P k K p k A
43 39 41 42 rspcdva φ p P k K C
44 15 4 38 43 fsum2d φ p P k K C = z p P p × K ^ z / x B
45 nfcv _ y B
46 nfcsb1v _ x y / x B
47 csbeq1a x = y B = y / x B
48 45 46 47 cbvsumi x ran a p P p × K ^ a B = y ran a p P p × K ^ a y / x B
49 csbeq1 y = ^ z y / x B = ^ z / x B
50 snfi p Fin
51 xpfi p Fin K Fin p × K Fin
52 50 38 51 sylancr φ p P p × K Fin
53 52 ralrimiva φ p P p × K Fin
54 iunfi P Fin p P p × K Fin p P p × K Fin
55 4 53 54 syl2anc φ p P p × K Fin
56 fvex ^ a V
57 56 2a1i φ a p P p × K ^ a V
58 eliunxp a p P p × K p k a = p k p P k K
59 5 simprbda φ p P k K p k
60 opelxp p k × p k
61 59 60 sylibr φ p P k K p k ×
62 eleq1 a = p k a × p k ×
63 61 62 syl5ibrcom φ p P k K a = p k a ×
64 63 impancom φ a = p k p P k K a ×
65 64 expimpd φ a = p k p P k K a ×
66 65 exlimdvv φ p k a = p k p P k K a ×
67 58 66 syl5bi φ a p P p × K a ×
68 67 ssrdv φ p P p × K ×
69 68 sseld φ b p P p × K b ×
70 67 69 anim12d φ a p P p × K b p P p × K a × b ×
71 1st2nd2 a × a = 1 st a 2 nd a
72 71 fveq2d a × ^ a = ^ 1 st a 2 nd a
73 df-ov 1 st a 2 nd a = ^ 1 st a 2 nd a
74 72 73 eqtr4di a × ^ a = 1 st a 2 nd a
75 1st2nd2 b × b = 1 st b 2 nd b
76 75 fveq2d b × ^ b = ^ 1 st b 2 nd b
77 df-ov 1 st b 2 nd b = ^ 1 st b 2 nd b
78 76 77 eqtr4di b × ^ b = 1 st b 2 nd b
79 74 78 eqeqan12d a × b × ^ a = ^ b 1 st a 2 nd a = 1 st b 2 nd b
80 xp1st a × 1 st a
81 xp2nd a × 2 nd a
82 80 81 jca a × 1 st a 2 nd a
83 xp1st b × 1 st b
84 xp2nd b × 2 nd b
85 83 84 jca b × 1 st b 2 nd b
86 prmexpb 1 st a 1 st b 2 nd a 2 nd b 1 st a 2 nd a = 1 st b 2 nd b 1 st a = 1 st b 2 nd a = 2 nd b
87 86 an4s 1 st a 2 nd a 1 st b 2 nd b 1 st a 2 nd a = 1 st b 2 nd b 1 st a = 1 st b 2 nd a = 2 nd b
88 82 85 87 syl2an a × b × 1 st a 2 nd a = 1 st b 2 nd b 1 st a = 1 st b 2 nd a = 2 nd b
89 xpopth a × b × 1 st a = 1 st b 2 nd a = 2 nd b a = b
90 79 88 89 3bitrd a × b × ^ a = ^ b a = b
91 70 90 syl6 φ a p P p × K b p P p × K ^ a = ^ b a = b
92 57 91 dom2lem φ a p P p × K ^ a : p P p × K 1-1 V
93 f1f1orn a p P p × K ^ a : p P p × K 1-1 V a p P p × K ^ a : p P p × K 1-1 onto ran a p P p × K ^ a
94 92 93 syl φ a p P p × K ^ a : p P p × K 1-1 onto ran a p P p × K ^ a
95 fveq2 a = z ^ a = ^ z
96 eqid a p P p × K ^ a = a p P p × K ^ a
97 fvex ^ z V
98 95 96 97 fvmpt z p P p × K a p P p × K ^ a z = ^ z
99 98 adantl φ z p P p × K a p P p × K ^ a z = ^ z
100 fveq2 a = p k ^ a = ^ p k
101 100 10 eqtr4di a = p k ^ a = p k
102 101 eleq1d a = p k ^ a A p k A
103 42 102 syl5ibrcom φ p P k K a = p k ^ a A
104 103 impancom φ a = p k p P k K ^ a A
105 104 expimpd φ a = p k p P k K ^ a A
106 105 exlimdvv φ p k a = p k p P k K ^ a A
107 58 106 syl5bi φ a p P p × K ^ a A
108 107 imp φ a p P p × K ^ a A
109 108 fmpttd φ a p P p × K ^ a : p P p × K A
110 109 frnd φ ran a p P p × K ^ a A
111 110 sselda φ y ran a p P p × K ^ a y A
112 46 nfel1 x y / x B
113 47 eleq1d x = y B y / x B
114 112 113 rspc y A x A B y / x B
115 40 114 mpan9 φ y A y / x B
116 111 115 syldan φ y ran a p P p × K ^ a y / x B
117 49 55 94 99 116 fsumf1o φ y ran a p P p × K ^ a y / x B = z p P p × K ^ z / x B
118 48 117 eqtrid φ x ran a p P p × K ^ a B = z p P p × K ^ z / x B
119 110 sselda φ x ran a p P p × K ^ a x A
120 119 6 syldan φ x ran a p P p × K ^ a B
121 eldif x A ran a p P p × K ^ a x A ¬ x ran a p P p × K ^ a
122 96 56 elrnmpti x ran a p P p × K ^ a a p P p × K x = ^ a
123 101 eqeq2d a = p k x = ^ a x = p k
124 123 rexiunxp a p P p × K x = ^ a p P k K x = p k
125 122 124 bitri x ran a p P p × K ^ a p P k K x = p k
126 simpr φ x A x = p k x = p k
127 simplr φ x A x = p k x A
128 126 127 eqeltrrd φ x A x = p k p k A
129 5 rbaibd φ p k A p P k K p k
130 129 adantlr φ x A p k A p P k K p k
131 128 130 syldan φ x A x = p k p P k K p k
132 131 pm5.32da φ x A x = p k p P k K x = p k p k
133 ancom p P k K x = p k x = p k p P k K
134 ancom p k x = p k x = p k p k
135 132 133 134 3bitr4g φ x A p P k K x = p k p k x = p k
136 135 2exbidv φ x A p k p P k K x = p k p k p k x = p k
137 r2ex p P k K x = p k p k p P k K x = p k
138 r2ex p k x = p k p k p k x = p k
139 136 137 138 3bitr4g φ x A p P k K x = p k p k x = p k
140 3 sselda φ x A x
141 isppw2 x Λ x 0 p k x = p k
142 140 141 syl φ x A Λ x 0 p k x = p k
143 139 142 bitr4d φ x A p P k K x = p k Λ x 0
144 125 143 syl5bb φ x A x ran a p P p × K ^ a Λ x 0
145 144 necon2bbid φ x A Λ x = 0 ¬ x ran a p P p × K ^ a
146 145 pm5.32da φ x A Λ x = 0 x A ¬ x ran a p P p × K ^ a
147 7 ex φ x A Λ x = 0 B = 0
148 146 147 sylbird φ x A ¬ x ran a p P p × K ^ a B = 0
149 121 148 syl5bi φ x A ran a p P p × K ^ a B = 0
150 149 imp φ x A ran a p P p × K ^ a B = 0
151 110 120 150 2 fsumss φ x ran a p P p × K ^ a B = x A B
152 44 118 151 3eqtr2rd φ x A B = p P k K C