MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  prmrec Structured version   Unicode version

Theorem prmrec 14647
Description: The sum of the reciprocals of the primes diverges. This is the "second" proof at http://en.wikipedia.org/wiki/Prime_harmonic_series, attributed to Paul Erdős. This is Metamath 100 proof #81. (Contributed by Mario Carneiro, 6-Aug-2014.)
Hypothesis
Ref Expression
prmrec.f  |-  F  =  ( n  e.  NN  |->  sum_ k  e.  ( Prime  i^i  ( 1 ... n
) ) ( 1  /  k ) )
Assertion
Ref Expression
prmrec  |-  -.  F  e.  dom  ~~>
Distinct variable group:    k, n
Allowed substitution hints:    F( k, n)

Proof of Theorem prmrec
Dummy variable  m is distinct from all other variables.
StepHypRef Expression
1 eleq1 2474 . . . . 5  |-  ( m  =  k  ->  (
m  e.  Prime  <->  k  e.  Prime ) )
2 oveq2 6285 . . . . 5  |-  ( m  =  k  ->  (
1  /  m )  =  ( 1  / 
k ) )
31, 2ifbieq1d 3907 . . . 4  |-  ( m  =  k  ->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 )  =  if ( k  e.  Prime ,  ( 1  /  k ) ,  0 ) )
43cbvmptv 4486 . . 3  |-  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m ) ,  0 ) )  =  ( k  e.  NN  |->  if ( k  e.  Prime ,  ( 1  /  k ) ,  0 ) )
54prmreclem6 14646 . 2  |-  -.  seq 1 (  +  , 
( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  e.  dom  ~~>
6 inss2 3659 . . . . . . . . 9  |-  ( Prime  i^i  ( 1 ... n
) )  C_  (
1 ... n )
76sseli 3437 . . . . . . . . . . 11  |-  ( k  e.  ( Prime  i^i  ( 1 ... n
) )  ->  k  e.  ( 1 ... n
) )
8 elfznn 11766 . . . . . . . . . . 11  |-  ( k  e.  ( 1 ... n )  ->  k  e.  NN )
9 nnrecre 10612 . . . . . . . . . . . 12  |-  ( k  e.  NN  ->  (
1  /  k )  e.  RR )
109recnd 9651 . . . . . . . . . . 11  |-  ( k  e.  NN  ->  (
1  /  k )  e.  CC )
117, 8, 103syl 20 . . . . . . . . . 10  |-  ( k  e.  ( Prime  i^i  ( 1 ... n
) )  ->  (
1  /  k )  e.  CC )
1211rgen 2763 . . . . . . . . 9  |-  A. k  e.  ( Prime  i^i  (
1 ... n ) ) ( 1  /  k
)  e.  CC
136, 12pm3.2i 453 . . . . . . . 8  |-  ( ( Prime  i^i  ( 1 ... n ) ) 
C_  ( 1 ... n )  /\  A. k  e.  ( Prime  i^i  ( 1 ... n
) ) ( 1  /  k )  e.  CC )
14 fzfi 12121 . . . . . . . . 9  |-  ( 1 ... n )  e. 
Fin
1514olci 389 . . . . . . . 8  |-  ( ( 1 ... n ) 
C_  ( ZZ>= `  1
)  \/  ( 1 ... n )  e. 
Fin )
16 sumss2 13695 . . . . . . . 8  |-  ( ( ( ( Prime  i^i  ( 1 ... n
) )  C_  (
1 ... n )  /\  A. k  e.  ( Prime  i^i  ( 1 ... n
) ) ( 1  /  k )  e.  CC )  /\  (
( 1 ... n
)  C_  ( ZZ>= ` 
1 )  \/  (
1 ... n )  e. 
Fin ) )  ->  sum_ k  e.  ( Prime  i^i  ( 1 ... n
) ) ( 1  /  k )  = 
sum_ k  e.  ( 1 ... n ) if ( k  e.  ( Prime  i^i  (
1 ... n ) ) ,  ( 1  / 
k ) ,  0 ) )
1713, 15, 16mp2an 670 . . . . . . 7  |-  sum_ k  e.  ( Prime  i^i  (
1 ... n ) ) ( 1  /  k
)  =  sum_ k  e.  ( 1 ... n
) if ( k  e.  ( Prime  i^i  ( 1 ... n
) ) ,  ( 1  /  k ) ,  0 )
18 elin 3625 . . . . . . . . . 10  |-  ( k  e.  ( Prime  i^i  ( 1 ... n
) )  <->  ( k  e.  Prime  /\  k  e.  ( 1 ... n
) ) )
1918rbaib 907 . . . . . . . . 9  |-  ( k  e.  ( 1 ... n )  ->  (
k  e.  ( Prime  i^i  ( 1 ... n
) )  <->  k  e.  Prime ) )
2019ifbid 3906 . . . . . . . 8  |-  ( k  e.  ( 1 ... n )  ->  if ( k  e.  ( Prime  i^i  ( 1 ... n ) ) ,  ( 1  / 
k ) ,  0 )  =  if ( k  e.  Prime ,  ( 1  /  k ) ,  0 ) )
2120sumeq2i 13668 . . . . . . 7  |-  sum_ k  e.  ( 1 ... n
) if ( k  e.  ( Prime  i^i  ( 1 ... n
) ) ,  ( 1  /  k ) ,  0 )  = 
sum_ k  e.  ( 1 ... n ) if ( k  e. 
Prime ,  ( 1  /  k ) ,  0 )
2217, 21eqtri 2431 . . . . . 6  |-  sum_ k  e.  ( Prime  i^i  (
1 ... n ) ) ( 1  /  k
)  =  sum_ k  e.  ( 1 ... n
) if ( k  e.  Prime ,  ( 1  /  k ) ,  0 )
238adantl 464 . . . . . . . 8  |-  ( ( n  e.  NN  /\  k  e.  ( 1 ... n ) )  ->  k  e.  NN )
24 prmnn 14427 . . . . . . . . . . . 12  |-  ( k  e.  Prime  ->  k  e.  NN )
2524, 10syl 17 . . . . . . . . . . 11  |-  ( k  e.  Prime  ->  ( 1  /  k )  e.  CC )
2625adantl 464 . . . . . . . . . 10  |-  ( ( T.  /\  k  e. 
Prime )  ->  ( 1  /  k )  e.  CC )
27 0cnd 9618 . . . . . . . . . 10  |-  ( ( T.  /\  -.  k  e.  Prime )  ->  0  e.  CC )
2826, 27ifclda 3916 . . . . . . . . 9  |-  ( T. 
->  if ( k  e. 
Prime ,  ( 1  /  k ) ,  0 )  e.  CC )
2928trud 1414 . . . . . . . 8  |-  if ( k  e.  Prime ,  ( 1  /  k ) ,  0 )  e.  CC
304fvmpt2 5940 . . . . . . . 8  |-  ( ( k  e.  NN  /\  if ( k  e.  Prime ,  ( 1  /  k
) ,  0 )  e.  CC )  -> 
( ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m ) ,  0 ) ) `  k )  =  if ( k  e.  Prime ,  ( 1  /  k
) ,  0 ) )
3123, 29, 30sylancl 660 . . . . . . 7  |-  ( ( n  e.  NN  /\  k  e.  ( 1 ... n ) )  ->  ( ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m ) ,  0 ) ) `
 k )  =  if ( k  e. 
Prime ,  ( 1  /  k ) ,  0 ) )
32 id 22 . . . . . . . 8  |-  ( n  e.  NN  ->  n  e.  NN )
33 nnuz 11161 . . . . . . . 8  |-  NN  =  ( ZZ>= `  1 )
3432, 33syl6eleq 2500 . . . . . . 7  |-  ( n  e.  NN  ->  n  e.  ( ZZ>= `  1 )
)
3529a1i 11 . . . . . . 7  |-  ( ( n  e.  NN  /\  k  e.  ( 1 ... n ) )  ->  if ( k  e.  Prime ,  ( 1  /  k ) ,  0 )  e.  CC )
3631, 34, 35fsumser 13699 . . . . . 6  |-  ( n  e.  NN  ->  sum_ k  e.  ( 1 ... n
) if ( k  e.  Prime ,  ( 1  /  k ) ,  0 )  =  (  seq 1 (  +  ,  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m ) ,  0 ) ) ) `
 n ) )
3722, 36syl5eq 2455 . . . . 5  |-  ( n  e.  NN  ->  sum_ k  e.  ( Prime  i^i  (
1 ... n ) ) ( 1  /  k
)  =  (  seq 1 (  +  , 
( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) ) `  n
) )
3837mpteq2ia 4476 . . . 4  |-  ( n  e.  NN  |->  sum_ k  e.  ( Prime  i^i  (
1 ... n ) ) ( 1  /  k
) )  =  ( n  e.  NN  |->  (  seq 1 (  +  ,  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m ) ,  0 ) ) ) `
 n ) )
39 prmrec.f . . . 4  |-  F  =  ( n  e.  NN  |->  sum_ k  e.  ( Prime  i^i  ( 1 ... n
) ) ( 1  /  k ) )
40 1z 10934 . . . . . . 7  |-  1  e.  ZZ
41 seqfn 12161 . . . . . . 7  |-  ( 1  e.  ZZ  ->  seq 1 (  +  , 
( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  Fn  ( ZZ>=
`  1 ) )
4240, 41ax-mp 5 . . . . . 6  |-  seq 1
(  +  ,  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  Fn  ( ZZ>=
`  1 )
4333fneq2i 5656 . . . . . 6  |-  (  seq 1 (  +  , 
( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  Fn  NN  <->  seq 1 (  +  , 
( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  Fn  ( ZZ>=
`  1 ) )
4442, 43mpbir 209 . . . . 5  |-  seq 1
(  +  ,  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  Fn  NN
45 dffn5 5893 . . . . 5  |-  (  seq 1 (  +  , 
( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  Fn  NN  <->  seq 1 (  +  , 
( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  =  ( n  e.  NN  |->  (  seq 1 (  +  ,  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m ) ,  0 ) ) ) `
 n ) ) )
4644, 45mpbi 208 . . . 4  |-  seq 1
(  +  ,  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  =  ( n  e.  NN  |->  (  seq 1 (  +  ,  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m ) ,  0 ) ) ) `
 n ) )
4738, 39, 463eqtr4i 2441 . . 3  |-  F  =  seq 1 (  +  ,  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m ) ,  0 ) ) )
4847eleq1i 2479 . 2  |-  ( F  e.  dom  ~~>  <->  seq 1
(  +  ,  ( m  e.  NN  |->  if ( m  e.  Prime ,  ( 1  /  m
) ,  0 ) ) )  e.  dom  ~~>  )
495, 48mtbir 297 1  |-  -.  F  e.  dom  ~~>
Colors of variables: wff setvar class
Syntax hints:   -. wn 3    \/ wo 366    /\ wa 367    = wceq 1405   T. wtru 1406    e. wcel 1842   A.wral 2753    i^i cin 3412    C_ wss 3413   ifcif 3884    |-> cmpt 4452   dom cdm 4822    Fn wfn 5563   ` cfv 5568  (class class class)co 6277   Fincfn 7553   CCcc 9519   0cc0 9521   1c1 9522    + caddc 9524    / cdiv 10246   NNcn 10575   ZZcz 10904   ZZ>=cuz 11126   ...cfz 11724    seqcseq 12149    ~~> cli 13454   sum_csu 13655   Primecprime 14424
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1639  ax-4 1652  ax-5 1725  ax-6 1771  ax-7 1814  ax-8 1844  ax-9 1846  ax-10 1861  ax-11 1866  ax-12 1878  ax-13 2026  ax-ext 2380  ax-rep 4506  ax-sep 4516  ax-nul 4524  ax-pow 4571  ax-pr 4629  ax-un 6573  ax-inf2 8090  ax-cnex 9577  ax-resscn 9578  ax-1cn 9579  ax-icn 9580  ax-addcl 9581  ax-addrcl 9582  ax-mulcl 9583  ax-mulrcl 9584  ax-mulcom 9585  ax-addass 9586  ax-mulass 9587  ax-distr 9588  ax-i2m1 9589  ax-1ne0 9590  ax-1rid 9591  ax-rnegex 9592  ax-rrecex 9593  ax-cnre 9594  ax-pre-lttri 9595  ax-pre-lttrn 9596  ax-pre-ltadd 9597  ax-pre-mulgt0 9598  ax-pre-sup 9599
This theorem depends on definitions:  df-bi 185  df-or 368  df-an 369  df-3or 975  df-3an 976  df-tru 1408  df-fal 1411  df-ex 1634  df-nf 1638  df-sb 1764  df-eu 2242  df-mo 2243  df-clab 2388  df-cleq 2394  df-clel 2397  df-nfc 2552  df-ne 2600  df-nel 2601  df-ral 2758  df-rex 2759  df-reu 2760  df-rmo 2761  df-rab 2762  df-v 3060  df-sbc 3277  df-csb 3373  df-dif 3416  df-un 3418  df-in 3420  df-ss 3427  df-pss 3429  df-nul 3738  df-if 3885  df-pw 3956  df-sn 3972  df-pr 3974  df-tp 3976  df-op 3978  df-uni 4191  df-int 4227  df-iun 4272  df-br 4395  df-opab 4453  df-mpt 4454  df-tr 4489  df-eprel 4733  df-id 4737  df-po 4743  df-so 4744  df-fr 4781  df-se 4782  df-we 4783  df-xp 4828  df-rel 4829  df-cnv 4830  df-co 4831  df-dm 4832  df-rn 4833  df-res 4834  df-ima 4835  df-pred 5366  df-ord 5412  df-on 5413  df-lim 5414  df-suc 5415  df-iota 5532  df-fun 5570  df-fn 5571  df-f 5572  df-f1 5573  df-fo 5574  df-f1o 5575  df-fv 5576  df-isom 5577  df-riota 6239  df-ov 6280  df-oprab 6281  df-mpt2 6282  df-om 6683  df-1st 6783  df-2nd 6784  df-wrecs 7012  df-recs 7074  df-rdg 7112  df-1o 7166  df-2o 7167  df-oadd 7170  df-er 7347  df-map 7458  df-pm 7459  df-en 7554  df-dom 7555  df-sdom 7556  df-fin 7557  df-sup 7934  df-oi 7968  df-card 8351  df-cda 8579  df-pnf 9659  df-mnf 9660  df-xr 9661  df-ltxr 9662  df-le 9663  df-sub 9842  df-neg 9843  df-div 10247  df-nn 10576  df-2 10634  df-3 10635  df-n0 10836  df-z 10905  df-uz 11127  df-q 11227  df-rp 11265  df-fz 11725  df-fzo 11853  df-fl 11964  df-mod 12033  df-seq 12150  df-exp 12209  df-hash 12451  df-cj 13079  df-re 13080  df-im 13081  df-sqrt 13215  df-abs 13216  df-clim 13458  df-rlim 13459  df-sum 13656  df-dvds 14194  df-gcd 14352  df-prm 14425  df-pc 14568
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator