Metamath Proof Explorer


Theorem fsumdvdscom

Description: A double commutation of divisor sums based on fsumdvdsdiag . Note that A depends on both j and k . (Contributed by Mario Carneiro, 13-May-2016)

Ref Expression
Hypotheses fsumdvdscom.1 φ N
fsumdvdscom.2 j = k m A = B
fsumdvdscom.3 φ j x | x N k x | x j A
Assertion fsumdvdscom φ j x | x N k x | x j A = k x | x N m x | x N k B

Proof

Step Hyp Ref Expression
1 fsumdvdscom.1 φ N
2 fsumdvdscom.2 j = k m A = B
3 fsumdvdscom.3 φ j x | x N k x | x j A
4 nfcv _ u k x | x j A
5 nfcv _ j x | x u
6 nfcsb1v _ j u / j A
7 5 6 nfsum _ j k x | x u u / j A
8 breq2 j = u x j x u
9 8 rabbidv j = u x | x j = x | x u
10 csbeq1a j = u A = u / j A
11 10 adantr j = u k x | x j A = u / j A
12 9 11 sumeq12dv j = u k x | x j A = k x | x u u / j A
13 4 7 12 cbvsumi j x | x N k x | x j A = u x | x N k x | x u u / j A
14 breq2 u = N v x u x N v
15 14 rabbidv u = N v x | x u = x | x N v
16 csbeq1 u = N v u / j A = N v / j A
17 16 adantr u = N v k x | x u u / j A = N v / j A
18 15 17 sumeq12dv u = N v k x | x u u / j A = k x | x N v N v / j A
19 fzfid φ 1 N Fin
20 dvdsssfz1 N x | x N 1 N
21 1 20 syl φ x | x N 1 N
22 19 21 ssfid φ x | x N Fin
23 eqid x | x N = x | x N
24 eqid z x | x N N z = z x | x N N z
25 23 24 dvdsflip N z x | x N N z : x | x N 1-1 onto x | x N
26 1 25 syl φ z x | x N N z : x | x N 1-1 onto x | x N
27 oveq2 z = v N z = N v
28 ovex N z V
29 27 24 28 fvmpt3i v x | x N z x | x N N z v = N v
30 29 adantl φ v x | x N z x | x N N z v = N v
31 fzfid φ u x | x N 1 u Fin
32 ssrab2 x | x N
33 simpr φ u x | x N u x | x N
34 32 33 sselid φ u x | x N u
35 dvdsssfz1 u x | x u 1 u
36 34 35 syl φ u x | x N x | x u 1 u
37 31 36 ssfid φ u x | x N x | x u Fin
38 3 ralrimivva φ j x | x N k x | x j A
39 nfv u k x | x j A
40 6 nfel1 j u / j A
41 5 40 nfralw j k x | x u u / j A
42 10 eleq1d j = u A u / j A
43 9 42 raleqbidv j = u k x | x j A k x | x u u / j A
44 39 41 43 cbvralw j x | x N k x | x j A u x | x N k x | x u u / j A
45 38 44 sylib φ u x | x N k x | x u u / j A
46 45 r19.21bi φ u x | x N k x | x u u / j A
47 46 r19.21bi φ u x | x N k x | x u u / j A
48 37 47 fsumcl φ u x | x N k x | x u u / j A
49 18 22 26 30 48 fsumf1o φ u x | x N k x | x u u / j A = v x | x N k x | x N v N v / j A
50 16 eleq1d u = N v u / j A N v / j A
51 15 50 raleqbidv u = N v k x | x u u / j A k x | x N v N v / j A
52 45 adantr φ v x | x N u x | x N k x | x u u / j A
53 dvdsdivcl N v x | x N N v x | x N
54 1 53 sylan φ v x | x N N v x | x N
55 51 52 54 rspcdva φ v x | x N k x | x N v N v / j A
56 55 r19.21bi φ v x | x N k x | x N v N v / j A
57 56 anasss φ v x | x N k x | x N v N v / j A
58 1 57 fsumdvdsdiag φ v x | x N k x | x N v N v / j A = k x | x N v x | x N k N v / j A
59 oveq2 v = N k m N v = N N k m
60 59 csbeq1d v = N k m N v / j A = N N k m / j A
61 fzfid φ k x | x N 1 N k Fin
62 dvdsdivcl N k x | x N N k x | x N
63 32 62 sselid N k x | x N N k
64 1 63 sylan φ k x | x N N k
65 dvdsssfz1 N k x | x N k 1 N k
66 64 65 syl φ k x | x N x | x N k 1 N k
67 61 66 ssfid φ k x | x N x | x N k Fin
68 eqid x | x N k = x | x N k
69 eqid z x | x N k N k z = z x | x N k N k z
70 68 69 dvdsflip N k z x | x N k N k z : x | x N k 1-1 onto x | x N k
71 64 70 syl φ k x | x N z x | x N k N k z : x | x N k 1-1 onto x | x N k
72 oveq2 z = m N k z = N k m
73 ovex N k z V
74 72 69 73 fvmpt3i m x | x N k z x | x N k N k z m = N k m
75 74 adantl φ k x | x N m x | x N k z x | x N k N k z m = N k m
76 1 fsumdvdsdiaglem φ k x | x N v x | x N k v x | x N k x | x N v
77 57 ex φ v x | x N k x | x N v N v / j A
78 76 77 syld φ k x | x N v x | x N k N v / j A
79 78 impl φ k x | x N v x | x N k N v / j A
80 60 67 71 75 79 fsumf1o φ k x | x N v x | x N k N v / j A = m x | x N k N N k m / j A
81 ovexd φ k x | x N m x | x N k N N k m V
82 nncn N N
83 nnne0 N N 0
84 82 83 jca N N N 0
85 1 84 syl φ N N 0
86 85 ad2antrr φ k x | x N m x | x N k N N 0
87 86 simpld φ k x | x N m x | x N k N
88 elrabi k x | x N k
89 88 adantl φ k x | x N k
90 89 adantr φ k x | x N m x | x N k k
91 nncn k k
92 nnne0 k k 0
93 91 92 jca k k k 0
94 90 93 syl φ k x | x N m x | x N k k k 0
95 elrabi m x | x N k m
96 95 adantl φ k x | x N m x | x N k m
97 nncn m m
98 nnne0 m m 0
99 97 98 jca m m m 0
100 96 99 syl φ k x | x N m x | x N k m m 0
101 divdiv1 N k k 0 m m 0 N k m = N k m
102 87 94 100 101 syl3anc φ k x | x N m x | x N k N k m = N k m
103 102 oveq2d φ k x | x N m x | x N k N N k m = N N k m
104 nnmulcl k m k m
105 89 95 104 syl2an φ k x | x N m x | x N k k m
106 nncn k m k m
107 nnne0 k m k m 0
108 106 107 jca k m k m k m 0
109 105 108 syl φ k x | x N m x | x N k k m k m 0
110 ddcan N N 0 k m k m 0 N N k m = k m
111 86 109 110 syl2anc φ k x | x N m x | x N k N N k m = k m
112 103 111 eqtrd φ k x | x N m x | x N k N N k m = k m
113 112 eqeq2d φ k x | x N m x | x N k j = N N k m j = k m
114 113 biimpa φ k x | x N m x | x N k j = N N k m j = k m
115 114 2 syl φ k x | x N m x | x N k j = N N k m A = B
116 81 115 csbied φ k x | x N m x | x N k N N k m / j A = B
117 116 sumeq2dv φ k x | x N m x | x N k N N k m / j A = m x | x N k B
118 80 117 eqtrd φ k x | x N v x | x N k N v / j A = m x | x N k B
119 118 sumeq2dv φ k x | x N v x | x N k N v / j A = k x | x N m x | x N k B
120 49 58 119 3eqtrd φ u x | x N k x | x u u / j A = k x | x N m x | x N k B
121 13 120 eqtrid φ j x | x N k x | x j A = k x | x N m x | x N k B