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

Theorem fzennn 11046
Description: The cardinality of a finite set of sequential integers. (See om2uz0i 11026 for a description of the hypothesis.) (Contributed by Mario Carneiro, 12-Feb-2013.) (Revised by Mario Carneiro, 7-Mar-2014.)
Hypothesis
Ref Expression
fzennn.1  |-  G  =  ( rec ( ( x  e.  _V  |->  ( x  +  1 ) ) ,  0 )  |`  om )
Assertion
Ref Expression
fzennn  |-  ( N  e.  NN0  ->  ( 1 ... N )  ~~  ( `' G `  N ) )

Proof of Theorem fzennn
Dummy variables  m  n are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 oveq2 5882 . . 3  |-  ( n  =  0  ->  (
1 ... n )  =  ( 1 ... 0
) )
2 fveq2 5541 . . 3  |-  ( n  =  0  ->  ( `' G `  n )  =  ( `' G `  0 ) )
31, 2breq12d 4052 . 2  |-  ( n  =  0  ->  (
( 1 ... n
)  ~~  ( `' G `  n )  <->  ( 1 ... 0 ) 
~~  ( `' G `  0 ) ) )
4 oveq2 5882 . . 3  |-  ( n  =  m  ->  (
1 ... n )  =  ( 1 ... m
) )
5 fveq2 5541 . . 3  |-  ( n  =  m  ->  ( `' G `  n )  =  ( `' G `  m ) )
64, 5breq12d 4052 . 2  |-  ( n  =  m  ->  (
( 1 ... n
)  ~~  ( `' G `  n )  <->  ( 1 ... m ) 
~~  ( `' G `  m ) ) )
7 oveq2 5882 . . 3  |-  ( n  =  ( m  + 
1 )  ->  (
1 ... n )  =  ( 1 ... (
m  +  1 ) ) )
8 fveq2 5541 . . 3  |-  ( n  =  ( m  + 
1 )  ->  ( `' G `  n )  =  ( `' G `  ( m  +  1 ) ) )
97, 8breq12d 4052 . 2  |-  ( n  =  ( m  + 
1 )  ->  (
( 1 ... n
)  ~~  ( `' G `  n )  <->  ( 1 ... ( m  +  1 ) ) 
~~  ( `' G `  ( m  +  1 ) ) ) )
10 oveq2 5882 . . 3  |-  ( n  =  N  ->  (
1 ... n )  =  ( 1 ... N
) )
11 fveq2 5541 . . 3  |-  ( n  =  N  ->  ( `' G `  n )  =  ( `' G `  N ) )
1210, 11breq12d 4052 . 2  |-  ( n  =  N  ->  (
( 1 ... n
)  ~~  ( `' G `  n )  <->  ( 1 ... N ) 
~~  ( `' G `  N ) ) )
13 0ex 4166 . . . 4  |-  (/)  e.  _V
1413enref 6910 . . 3  |-  (/)  ~~  (/)
15 fz10 10830 . . 3  |-  ( 1 ... 0 )  =  (/)
16 0z 10051 . . . . . 6  |-  0  e.  ZZ
17 fzennn.1 . . . . . 6  |-  G  =  ( rec ( ( x  e.  _V  |->  ( x  +  1 ) ) ,  0 )  |`  om )
1816, 17om2uzf1oi 11032 . . . . 5  |-  G : om
-1-1-onto-> ( ZZ>= `  0 )
19 peano1 4691 . . . . 5  |-  (/)  e.  om
2018, 19pm3.2i 441 . . . 4  |-  ( G : om -1-1-onto-> ( ZZ>= `  0 )  /\  (/)  e.  om )
2116, 17om2uz0i 11026 . . . 4  |-  ( G `
 (/) )  =  0
22 f1ocnvfv 5810 . . . 4  |-  ( ( G : om -1-1-onto-> ( ZZ>= `  0 )  /\  (/)  e.  om )  ->  ( ( G `  (/) )  =  0  -> 
( `' G ` 
0 )  =  (/) ) )
2320, 21, 22mp2 17 . . 3  |-  ( `' G `  0 )  =  (/)
2414, 15, 233brtr4i 4067 . 2  |-  ( 1 ... 0 )  ~~  ( `' G `  0 )
25 simpr 447 . . . . 5  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  ( 1 ... m )  ~~  ( `' G `  m ) )
26 ovex 5899 . . . . . . 7  |-  ( m  +  1 )  e. 
_V
27 fvex 5555 . . . . . . 7  |-  ( `' G `  m )  e.  _V
28 en2sn 6956 . . . . . . 7  |-  ( ( ( m  +  1 )  e.  _V  /\  ( `' G `  m )  e.  _V )  ->  { ( m  + 
1 ) }  ~~  { ( `' G `  m ) } )
2926, 27, 28mp2an 653 . . . . . 6  |-  { ( m  +  1 ) }  ~~  { ( `' G `  m ) }
3029a1i 10 . . . . 5  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  { (
m  +  1 ) }  ~~  { ( `' G `  m ) } )
31 fzp1disj 10859 . . . . . 6  |-  ( ( 1 ... m )  i^i  { ( m  +  1 ) } )  =  (/)
3231a1i 10 . . . . 5  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  ( (
1 ... m )  i^i 
{ ( m  + 
1 ) } )  =  (/) )
33 f1ocnvdm 5812 . . . . . . . . . 10  |-  ( ( G : om -1-1-onto-> ( ZZ>= `  0 )  /\  m  e.  ( ZZ>=
`  0 ) )  ->  ( `' G `  m )  e.  om )
3418, 33mpan 651 . . . . . . . . 9  |-  ( m  e.  ( ZZ>= `  0
)  ->  ( `' G `  m )  e.  om )
35 nn0uz 10278 . . . . . . . . 9  |-  NN0  =  ( ZZ>= `  0 )
3634, 35eleq2s 2388 . . . . . . . 8  |-  ( m  e.  NN0  ->  ( `' G `  m )  e.  om )
37 nnord 4680 . . . . . . . 8  |-  ( ( `' G `  m )  e.  om  ->  Ord  ( `' G `  m ) )
38 ordirr 4426 . . . . . . . 8  |-  ( Ord  ( `' G `  m )  ->  -.  ( `' G `  m )  e.  ( `' G `  m ) )
3936, 37, 383syl 18 . . . . . . 7  |-  ( m  e.  NN0  ->  -.  ( `' G `  m )  e.  ( `' G `  m ) )
4039adantr 451 . . . . . 6  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  -.  ( `' G `  m )  e.  ( `' G `  m ) )
41 disjsn 3706 . . . . . 6  |-  ( ( ( `' G `  m )  i^i  {
( `' G `  m ) } )  =  (/)  <->  -.  ( `' G `  m )  e.  ( `' G `  m ) )
4240, 41sylibr 203 . . . . 5  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  ( ( `' G `  m )  i^i  { ( `' G `  m ) } )  =  (/) )
43 unen 6959 . . . . 5  |-  ( ( ( ( 1 ... m )  ~~  ( `' G `  m )  /\  { ( m  +  1 ) } 
~~  { ( `' G `  m ) } )  /\  (
( ( 1 ... m )  i^i  {
( m  +  1 ) } )  =  (/)  /\  ( ( `' G `  m )  i^i  { ( `' G `  m ) } )  =  (/) ) )  ->  (
( 1 ... m
)  u.  { ( m  +  1 ) } )  ~~  (
( `' G `  m )  u.  {
( `' G `  m ) } ) )
4425, 30, 32, 42, 43syl22anc 1183 . . . 4  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  ( (
1 ... m )  u. 
{ ( m  + 
1 ) } ) 
~~  ( ( `' G `  m )  u.  { ( `' G `  m ) } ) )
45 1z 10069 . . . . . 6  |-  1  e.  ZZ
46 1m1e0 9830 . . . . . . . . . 10  |-  ( 1  -  1 )  =  0
4746fveq2i 5544 . . . . . . . . 9  |-  ( ZZ>= `  ( 1  -  1 ) )  =  (
ZZ>= `  0 )
4835, 47eqtr4i 2319 . . . . . . . 8  |-  NN0  =  ( ZZ>= `  ( 1  -  1 ) )
4948eleq2i 2360 . . . . . . 7  |-  ( m  e.  NN0  <->  m  e.  ( ZZ>=
`  ( 1  -  1 ) ) )
5049biimpi 186 . . . . . 6  |-  ( m  e.  NN0  ->  m  e.  ( ZZ>= `  ( 1  -  1 ) ) )
51 fzsuc2 10858 . . . . . 6  |-  ( ( 1  e.  ZZ  /\  m  e.  ( ZZ>= `  ( 1  -  1 ) ) )  -> 
( 1 ... (
m  +  1 ) )  =  ( ( 1 ... m )  u.  { ( m  +  1 ) } ) )
5245, 50, 51sylancr 644 . . . . 5  |-  ( m  e.  NN0  ->  ( 1 ... ( m  + 
1 ) )  =  ( ( 1 ... m )  u.  {
( m  +  1 ) } ) )
5352adantr 451 . . . 4  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  ( 1 ... ( m  + 
1 ) )  =  ( ( 1 ... m )  u.  {
( m  +  1 ) } ) )
54 peano2 4692 . . . . . . . . 9  |-  ( ( `' G `  m )  e.  om  ->  suc  ( `' G `  m )  e.  om )
5536, 54syl 15 . . . . . . . 8  |-  ( m  e.  NN0  ->  suc  ( `' G `  m )  e.  om )
5655, 18jctil 523 . . . . . . 7  |-  ( m  e.  NN0  ->  ( G : om -1-1-onto-> ( ZZ>= `  0 )  /\  suc  ( `' G `  m )  e.  om ) )
5716, 17om2uzsuci 11027 . . . . . . . . 9  |-  ( ( `' G `  m )  e.  om  ->  ( G `  suc  ( `' G `  m ) )  =  ( ( G `  ( `' G `  m ) )  +  1 ) )
5836, 57syl 15 . . . . . . . 8  |-  ( m  e.  NN0  ->  ( G `
 suc  ( `' G `  m )
)  =  ( ( G `  ( `' G `  m ) )  +  1 ) )
5935eleq2i 2360 . . . . . . . . . . 11  |-  ( m  e.  NN0  <->  m  e.  ( ZZ>=
`  0 ) )
6059biimpi 186 . . . . . . . . . 10  |-  ( m  e.  NN0  ->  m  e.  ( ZZ>= `  0 )
)
61 f1ocnvfv2 5809 . . . . . . . . . 10  |-  ( ( G : om -1-1-onto-> ( ZZ>= `  0 )  /\  m  e.  ( ZZ>=
`  0 ) )  ->  ( G `  ( `' G `  m ) )  =  m )
6218, 60, 61sylancr 644 . . . . . . . . 9  |-  ( m  e.  NN0  ->  ( G `
 ( `' G `  m ) )  =  m )
6362oveq1d 5889 . . . . . . . 8  |-  ( m  e.  NN0  ->  ( ( G `  ( `' G `  m ) )  +  1 )  =  ( m  + 
1 ) )
6458, 63eqtrd 2328 . . . . . . 7  |-  ( m  e.  NN0  ->  ( G `
 suc  ( `' G `  m )
)  =  ( m  +  1 ) )
65 f1ocnvfv 5810 . . . . . . 7  |-  ( ( G : om -1-1-onto-> ( ZZ>= `  0 )  /\  suc  ( `' G `  m )  e.  om )  ->  ( ( G `
 suc  ( `' G `  m )
)  =  ( m  +  1 )  -> 
( `' G `  ( m  +  1
) )  =  suc  ( `' G `  m ) ) )
6656, 64, 65sylc 56 . . . . . 6  |-  ( m  e.  NN0  ->  ( `' G `  ( m  +  1 ) )  =  suc  ( `' G `  m ) )
6766adantr 451 . . . . 5  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  ( `' G `  ( m  +  1 ) )  =  suc  ( `' G `  m ) )
68 df-suc 4414 . . . . 5  |-  suc  ( `' G `  m )  =  ( ( `' G `  m )  u.  { ( `' G `  m ) } )
6967, 68syl6eq 2344 . . . 4  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  ( `' G `  ( m  +  1 ) )  =  ( ( `' G `  m )  u.  { ( `' G `  m ) } ) )
7044, 53, 693brtr4d 4069 . . 3  |-  ( ( m  e.  NN0  /\  ( 1 ... m
)  ~~  ( `' G `  m )
)  ->  ( 1 ... ( m  + 
1 ) )  ~~  ( `' G `  ( m  +  1 ) ) )
7170ex 423 . 2  |-  ( m  e.  NN0  ->  ( ( 1 ... m ) 
~~  ( `' G `  m )  ->  (
1 ... ( m  + 
1 ) )  ~~  ( `' G `  ( m  +  1 ) ) ) )
723, 6, 9, 12, 24, 71nn0ind 10124 1  |-  ( N  e.  NN0  ->  ( 1 ... N )  ~~  ( `' G `  N ) )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    /\ wa 358    = wceq 1632    e. wcel 1696   _Vcvv 2801    u. cun 3163    i^i cin 3164   (/)c0 3468   {csn 3653   class class class wbr 4039    e. cmpt 4093   Ord word 4407   suc csuc 4410   omcom 4672   `'ccnv 4704    |` cres 4707   -1-1-onto->wf1o 5270   ` cfv 5271  (class class class)co 5874   reccrdg 6438    ~~ cen 6876   0cc0 8753   1c1 8754    + caddc 8756    - cmin 9053   NN0cn0 9981   ZZcz 10040   ZZ>=cuz 10246   ...cfz 10798
This theorem is referenced by:  fzen2  11047  cardfz  11048
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8  ax-gen 1536  ax-5 1547  ax-17 1606  ax-9 1644  ax-8 1661  ax-13 1698  ax-14 1700  ax-6 1715  ax-7 1720  ax-11 1727  ax-12 1878  ax-ext 2277  ax-sep 4157  ax-nul 4165  ax-pow 4204  ax-pr 4230  ax-un 4528  ax-cnex 8809  ax-resscn 8810  ax-1cn 8811  ax-icn 8812  ax-addcl 8813  ax-addrcl 8814  ax-mulcl 8815  ax-mulrcl 8816  ax-mulcom 8817  ax-addass 8818  ax-mulass 8819  ax-distr 8820  ax-i2m1 8821  ax-1ne0 8822  ax-1rid 8823  ax-rnegex 8824  ax-rrecex 8825  ax-cnre 8826  ax-pre-lttri 8827  ax-pre-lttrn 8828  ax-pre-ltadd 8829  ax-pre-mulgt0 8830
This theorem depends on definitions:  df-bi 177  df-or 359  df-an 360  df-3or 935  df-3an 936  df-tru 1310  df-ex 1532  df-nf 1535  df-sb 1639  df-eu 2160  df-mo 2161  df-clab 2283  df-cleq 2289  df-clel 2292  df-nfc 2421  df-ne 2461  df-nel 2462  df-ral 2561  df-rex 2562  df-reu 2563  df-rab 2565  df-v 2803  df-sbc 3005  df-csb 3095  df-dif 3168  df-un 3170  df-in 3172  df-ss 3179  df-pss 3181  df-nul 3469  df-if 3579  df-pw 3640  df-sn 3659  df-pr 3660  df-tp 3661  df-op 3662  df-uni 3844  df-iun 3923  df-br 4040  df-opab 4094  df-mpt 4095  df-tr 4130  df-eprel 4321  df-id 4325  df-po 4330  df-so 4331  df-fr 4368  df-we 4370  df-ord 4411  df-on 4412  df-lim 4413  df-suc 4414  df-om 4673  df-xp 4711  df-rel 4712  df-cnv 4713  df-co 4714  df-dm 4715  df-rn 4716  df-res 4717  df-ima 4718  df-iota 5235  df-fun 5273  df-fn 5274  df-f 5275  df-f1 5276  df-fo 5277  df-f1o 5278  df-fv 5279  df-ov 5877  df-oprab 5878  df-mpt2 5879  df-1st 6138  df-2nd 6139  df-riota 6320  df-recs 6404  df-rdg 6439  df-1o 6495  df-er 6676  df-en 6880  df-dom 6881  df-sdom 6882  df-pnf 8885  df-mnf 8886  df-xr 8887  df-ltxr 8888  df-le 8889  df-sub 9055  df-neg 9056  df-nn 9763  df-n0 9982  df-z 10041  df-uz 10247  df-fz 10799
  Copyright terms: Public domain W3C validator