Users' Mathboxes Mathbox for Thierry Arnoux < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >   Mathboxes  >  ballotlemirc Structured version   Unicode version

Theorem ballotlemirc 24794
Description: Applying  R does not change first ties. (Contributed by Thierry Arnoux, 19-Apr-2017.)
Hypotheses
Ref Expression
ballotth.m  |-  M  e.  NN
ballotth.n  |-  N  e.  NN
ballotth.o  |-  O  =  { c  e.  ~P ( 1 ... ( M  +  N )
)  |  ( # `  c )  =  M }
ballotth.p  |-  P  =  ( x  e.  ~P O  |->  ( ( # `  x )  /  ( # `
 O ) ) )
ballotth.f  |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( ( # `  (
( 1 ... i
)  i^i  c )
)  -  ( # `  ( ( 1 ... i )  \  c
) ) ) ) )
ballotth.e  |-  E  =  { c  e.  O  |  A. i  e.  ( 1 ... ( M  +  N ) ) 0  <  ( ( F `  c ) `
 i ) }
ballotth.mgtn  |-  N  < 
M
ballotth.i  |-  I  =  ( c  e.  ( O  \  E ) 
|->  sup ( { k  e.  ( 1 ... ( M  +  N
) )  |  ( ( F `  c
) `  k )  =  0 } ,  RR ,  `'  <  ) )
ballotth.s  |-  S  =  ( c  e.  ( O  \  E ) 
|->  ( i  e.  ( 1 ... ( M  +  N ) ) 
|->  if ( i  <_ 
( I `  c
) ,  ( ( ( I `  c
)  +  1 )  -  i ) ,  i ) ) )
ballotth.r  |-  R  =  ( c  e.  ( O  \  E ) 
|->  ( ( S `  c ) " c
) )
Assertion
Ref Expression
ballotlemirc  |-  ( C  e.  ( O  \  E )  ->  (
I `  ( R `  C ) )  =  ( I `  C
) )
Distinct variable groups:    M, c    N, c    O, c    i, M   
i, N    i, O    k, M    k, N    k, O    i, c, F, k    C, i, k    i, E, k    C, k    k, I, c    E, c    i, I, c    S, k, i, c    R, i, k    x, k, C    x, F    x, M    x, N
Allowed substitution hints:    C( c)    P( x, i, k, c)    R( x, c)    S( x)    E( x)    I( x)    O( x)

Proof of Theorem ballotlemirc
Dummy variables  y 
v  u are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 ballotth.m . . . 4  |-  M  e.  NN
2 ballotth.n . . . 4  |-  N  e.  NN
3 ballotth.o . . . 4  |-  O  =  { c  e.  ~P ( 1 ... ( M  +  N )
)  |  ( # `  c )  =  M }
4 ballotth.p . . . 4  |-  P  =  ( x  e.  ~P O  |->  ( ( # `  x )  /  ( # `
 O ) ) )
5 ballotth.f . . . 4  |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( ( # `  (
( 1 ... i
)  i^i  c )
)  -  ( # `  ( ( 1 ... i )  \  c
) ) ) ) )
6 ballotth.e . . . 4  |-  E  =  { c  e.  O  |  A. i  e.  ( 1 ... ( M  +  N ) ) 0  <  ( ( F `  c ) `
 i ) }
7 ballotth.mgtn . . . 4  |-  N  < 
M
8 ballotth.i . . . 4  |-  I  =  ( c  e.  ( O  \  E ) 
|->  sup ( { k  e.  ( 1 ... ( M  +  N
) )  |  ( ( F `  c
) `  k )  =  0 } ,  RR ,  `'  <  ) )
9 ballotth.s . . . 4  |-  S  =  ( c  e.  ( O  \  E ) 
|->  ( i  e.  ( 1 ... ( M  +  N ) ) 
|->  if ( i  <_ 
( I `  c
) ,  ( ( ( I `  c
)  +  1 )  -  i ) ,  i ) ) )
10 ballotth.r . . . 4  |-  R  =  ( c  e.  ( O  \  E ) 
|->  ( ( S `  c ) " c
) )
111, 2, 3, 4, 5, 6, 7, 8, 9, 10ballotlemrc 24793 . . 3  |-  ( C  e.  ( O  \  E )  ->  ( R `  C )  e.  ( O  \  E
) )
121, 2, 3, 4, 5, 6, 7, 8ballotlemi 24763 . . 3  |-  ( ( R `  C )  e.  ( O  \  E )  ->  (
I `  ( R `  C ) )  =  sup ( { k  e.  ( 1 ... ( M  +  N
) )  |  ( ( F `  ( R `  C )
) `  k )  =  0 } ,  RR ,  `'  <  ) )
1311, 12syl 16 . 2  |-  ( C  e.  ( O  \  E )  ->  (
I `  ( R `  C ) )  =  sup ( { k  e.  ( 1 ... ( M  +  N
) )  |  ( ( F `  ( R `  C )
) `  k )  =  0 } ,  RR ,  `'  <  ) )
14 ltso 9161 . . . . 5  |-  <  Or  RR
15 cnvso 5414 . . . . 5  |-  (  < 
Or  RR  <->  `'  <  Or  RR )
1614, 15mpbi 201 . . . 4  |-  `'  <  Or  RR
1716a1i 11 . . 3  |-  ( C  e.  ( O  \  E )  ->  `'  <  Or  RR )
181, 2, 3, 4, 5, 6, 7, 8ballotlemiex 24764 . . . . . 6  |-  ( C  e.  ( O  \  E )  ->  (
( I `  C
)  e.  ( 1 ... ( M  +  N ) )  /\  ( ( F `  C ) `  (
I `  C )
)  =  0 ) )
1918simpld 447 . . . . 5  |-  ( C  e.  ( O  \  E )  ->  (
I `  C )  e.  ( 1 ... ( M  +  N )
) )
20 elfzelz 11064 . . . . 5  |-  ( ( I `  C )  e.  ( 1 ... ( M  +  N
) )  ->  (
I `  C )  e.  ZZ )
2119, 20syl 16 . . . 4  |-  ( C  e.  ( O  \  E )  ->  (
I `  C )  e.  ZZ )
2221zred 10380 . . 3  |-  ( C  e.  ( O  \  E )  ->  (
I `  C )  e.  RR )
23 eqid 2438 . . . . 5  |-  ( u  e.  Fin ,  v  e.  Fin  |->  ( (
# `  ( v  i^i  u ) )  -  ( # `  ( v 
\  u ) ) ) )  =  ( u  e.  Fin , 
v  e.  Fin  |->  ( ( # `  (
v  i^i  u )
)  -  ( # `  ( v  \  u
) ) ) )
241, 2, 3, 4, 5, 6, 7, 8, 9, 10, 23ballotlemfrci 24790 . . . 4  |-  ( C  e.  ( O  \  E )  ->  (
( F `  ( R `  C )
) `  ( I `  C ) )  =  0 )
25 fveq2 5731 . . . . . 6  |-  ( k  =  ( I `  C )  ->  (
( F `  ( R `  C )
) `  k )  =  ( ( F `
 ( R `  C ) ) `  ( I `  C
) ) )
2625eqeq1d 2446 . . . . 5  |-  ( k  =  ( I `  C )  ->  (
( ( F `  ( R `  C ) ) `  k )  =  0  <->  ( ( F `  ( R `  C ) ) `  ( I `  C
) )  =  0 ) )
2726elrab 3094 . . . 4  |-  ( ( I `  C )  e.  { k  e.  ( 1 ... ( M  +  N )
)  |  ( ( F `  ( R `
 C ) ) `
 k )  =  0 }  <->  ( (
I `  C )  e.  ( 1 ... ( M  +  N )
)  /\  ( ( F `  ( R `  C ) ) `  ( I `  C
) )  =  0 ) )
2819, 24, 27sylanbrc 647 . . 3  |-  ( C  e.  ( O  \  E )  ->  (
I `  C )  e.  { k  e.  ( 1 ... ( M  +  N ) )  |  ( ( F `
 ( R `  C ) ) `  k )  =  0 } )
29 elrabi 3092 . . . . 5  |-  ( y  e.  { k  e.  ( 1 ... ( M  +  N )
)  |  ( ( F `  ( R `
 C ) ) `
 k )  =  0 }  ->  y  e.  ( 1 ... ( M  +  N )
) )
3029anim2i 554 . . . 4  |-  ( ( C  e.  ( O 
\  E )  /\  y  e.  { k  e.  ( 1 ... ( M  +  N )
)  |  ( ( F `  ( R `
 C ) ) `
 k )  =  0 } )  -> 
( C  e.  ( O  \  E )  /\  y  e.  ( 1 ... ( M  +  N ) ) ) )
3119adantr 453 . . . . . . . . . 10  |-  ( ( C  e.  ( O 
\  E )  /\  y  e.  ( 1 ... ( M  +  N ) ) )  ->  ( I `  C )  e.  ( 1 ... ( M  +  N ) ) )
32 vex 2961 . . . . . . . . . 10  |-  y  e. 
_V
33 brcnvg 5056 . . . . . . . . . 10  |-  ( ( ( I `  C
)  e.  ( 1 ... ( M  +  N ) )  /\  y  e.  _V )  ->  ( ( I `  C ) `'  <  y  <-> 
y  <  ( I `  C ) ) )
3431, 32, 33sylancl 645 . . . . . . . . 9  |-  ( ( C  e.  ( O 
\  E )  /\  y  e.  ( 1 ... ( M  +  N ) ) )  ->  ( ( I `
 C ) `'  <  y  <->  y  <  ( I `  C ) ) )
3534biimpa 472 . . . . . . . 8  |-  ( ( ( C  e.  ( O  \  E )  /\  y  e.  ( 1 ... ( M  +  N ) ) )  /\  ( I `
 C ) `'  <  y )  -> 
y  <  ( I `  C ) )
361, 2, 3, 4, 5, 6, 7, 8, 9, 10ballotlemfrcn0 24792 . . . . . . . . . . 11  |-  ( ( C  e.  ( O 
\  E )  /\  y  e.  ( 1 ... ( M  +  N ) )  /\  y  <  ( I `  C ) )  -> 
( ( F `  ( R `  C ) ) `  y )  =/=  0 )
3736neneqd 2619 . . . . . . . . . 10  |-  ( ( C  e.  ( O 
\  E )  /\  y  e.  ( 1 ... ( M  +  N ) )  /\  y  <  ( I `  C ) )  ->  -.  ( ( F `  ( R `  C ) ) `  y )  =  0 )
38 fveq2 5731 . . . . . . . . . . . . 13  |-  ( k  =  y  ->  (
( F `  ( R `  C )
) `  k )  =  ( ( F `
 ( R `  C ) ) `  y ) )
3938eqeq1d 2446 . . . . . . . . . . . 12  |-  ( k  =  y  ->  (
( ( F `  ( R `  C ) ) `  k )  =  0  <->  ( ( F `  ( R `  C ) ) `  y )  =  0 ) )
4039elrab 3094 . . . . . . . . . . 11  |-  ( y  e.  { k  e.  ( 1 ... ( M  +  N )
)  |  ( ( F `  ( R `
 C ) ) `
 k )  =  0 }  <->  ( y  e.  ( 1 ... ( M  +  N )
)  /\  ( ( F `  ( R `  C ) ) `  y )  =  0 ) )
4140simprbi 452 . . . . . . . . . 10  |-  ( y  e.  { k  e.  ( 1 ... ( M  +  N )
)  |  ( ( F `  ( R `
 C ) ) `
 k )  =  0 }  ->  (
( F `  ( R `  C )
) `  y )  =  0 )
4237, 41nsyl 116 . . . . . . . . 9  |-  ( ( C  e.  ( O 
\  E )  /\  y  e.  ( 1 ... ( M  +  N ) )  /\  y  <  ( I `  C ) )  ->  -.  y  e.  { k  e.  ( 1 ... ( M  +  N
) )  |  ( ( F `  ( R `  C )
) `  k )  =  0 } )
43423expa 1154 . . . . . . . 8  |-  ( ( ( C  e.  ( O  \  E )  /\  y  e.  ( 1 ... ( M  +  N ) ) )  /\  y  < 
( I `  C
) )  ->  -.  y  e.  { k  e.  ( 1 ... ( M  +  N )
)  |  ( ( F `  ( R `
 C ) ) `
 k )  =  0 } )
4435, 43syldan 458 . . . . . . 7  |-  ( ( ( C  e.  ( O  \  E )  /\  y  e.  ( 1 ... ( M  +  N ) ) )  /\  ( I `
 C ) `'  <  y )  ->  -.  y  e.  { k  e.  ( 1 ... ( M  +  N
) )  |  ( ( F `  ( R `  C )
) `  k )  =  0 } )
4544ex 425 . . . . . 6  |-  ( ( C  e.  ( O 
\  E )  /\  y  e.  ( 1 ... ( M  +  N ) ) )  ->  ( ( I `
 C ) `'  <  y  ->  -.  y  e.  { k  e.  ( 1 ... ( M  +  N )
)  |  ( ( F `  ( R `
 C ) ) `
 k )  =  0 } ) )
4645con2d 110 . . . . 5  |-  ( ( C  e.  ( O 
\  E )  /\  y  e.  ( 1 ... ( M  +  N ) ) )  ->  ( y  e. 
{ k  e.  ( 1 ... ( M  +  N ) )  |  ( ( F `
 ( R `  C ) ) `  k )  =  0 }  ->  -.  (
I `  C ) `'  <  y ) )
4746imp 420 . . . 4  |-  ( ( ( C  e.  ( O  \  E )  /\  y  e.  ( 1 ... ( M  +  N ) ) )  /\  y  e. 
{ k  e.  ( 1 ... ( M  +  N ) )  |  ( ( F `
 ( R `  C ) ) `  k )  =  0 } )  ->  -.  ( I `  C
) `'  <  y
)
4830, 47sylancom 650 . . 3  |-  ( ( C  e.  ( O 
\  E )  /\  y  e.  { k  e.  ( 1 ... ( M  +  N )
)  |  ( ( F `  ( R `
 C ) ) `
 k )  =  0 } )  ->  -.  ( I `  C
) `'  <  y
)
4917, 22, 28, 48supmax 7473 . 2  |-  ( C  e.  ( O  \  E )  ->  sup ( { k  e.  ( 1 ... ( M  +  N ) )  |  ( ( F `
 ( R `  C ) ) `  k )  =  0 } ,  RR ,  `'  <  )  =  ( I `  C ) )
5013, 49eqtrd 2470 1  |-  ( C  e.  ( O  \  E )  ->  (
I `  ( R `  C ) )  =  ( I `  C
) )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    <-> wb 178    /\ wa 360    /\ w3a 937    = wceq 1653    e. wcel 1726   A.wral 2707   {crab 2711   _Vcvv 2958    \ cdif 3319    i^i cin 3321   ifcif 3741   ~Pcpw 3801   class class class wbr 4215    e. cmpt 4269    Or wor 4505   `'ccnv 4880   "cima 4884   ` cfv 5457  (class class class)co 6084    e. cmpt2 6086   Fincfn 7112   supcsup 7448   RRcr 8994   0cc0 8995   1c1 8996    + caddc 8998    < clt 9125    <_ cle 9126    - cmin 9296    / cdiv 9682   NNcn 10005   ZZcz 10287   ...cfz 11048   #chash 11623
This theorem is referenced by:  ballotlemrinv0  24795
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1556  ax-5 1567  ax-17 1627  ax-9 1667  ax-8 1688  ax-13 1728  ax-14 1730  ax-6 1745  ax-7 1750  ax-11 1762  ax-12 1951  ax-ext 2419  ax-rep 4323  ax-sep 4333  ax-nul 4341  ax-pow 4380  ax-pr 4406  ax-un 4704  ax-cnex 9051  ax-resscn 9052  ax-1cn 9053  ax-icn 9054  ax-addcl 9055  ax-addrcl 9056  ax-mulcl 9057  ax-mulrcl 9058  ax-mulcom 9059  ax-addass 9060  ax-mulass 9061  ax-distr 9062  ax-i2m1 9063  ax-1ne0 9064  ax-1rid 9065  ax-rnegex 9066  ax-rrecex 9067  ax-cnre 9068  ax-pre-lttri 9069  ax-pre-lttrn 9070  ax-pre-ltadd 9071  ax-pre-mulgt0 9072
This theorem depends on definitions:  df-bi 179  df-or 361  df-an 362  df-3or 938  df-3an 939  df-tru 1329  df-ex 1552  df-nf 1555  df-sb 1660  df-eu 2287  df-mo 2288  df-clab 2425  df-cleq 2431  df-clel 2434  df-nfc 2563  df-ne 2603  df-nel 2604  df-ral 2712  df-rex 2713  df-reu 2714  df-rmo 2715  df-rab 2716  df-v 2960  df-sbc 3164  df-csb 3254  df-dif 3325  df-un 3327  df-in 3329  df-ss 3336  df-pss 3338  df-nul 3631  df-if 3742  df-pw 3803  df-sn 3822  df-pr 3823  df-tp 3824  df-op 3825  df-uni 4018  df-int 4053  df-iun 4097  df-br 4216  df-opab 4270  df-mpt 4271  df-tr 4306  df-eprel 4497  df-id 4501  df-po 4506  df-so 4507  df-fr 4544  df-we 4546  df-ord 4587  df-on 4588  df-lim 4589  df-suc 4590  df-om 4849  df-xp 4887  df-rel 4888  df-cnv 4889  df-co 4890  df-dm 4891  df-rn 4892  df-res 4893  df-ima 4894  df-iota 5421  df-fun 5459  df-fn 5460  df-f 5461  df-f1 5462  df-fo 5463  df-f1o 5464  df-fv 5465  df-ov 6087  df-oprab 6088  df-mpt2 6089  df-1st 6352  df-2nd 6353  df-riota 6552  df-recs 6636  df-rdg 6671  df-1o 6727  df-oadd 6731  df-er 6908  df-en 7113  df-dom 7114  df-sdom 7115  df-fin 7116  df-sup 7449  df-card 7831  df-cda 8053  df-pnf 9127  df-mnf 9128  df-xr 9129  df-ltxr 9130  df-le 9131  df-sub 9298  df-neg 9299  df-nn 10006  df-2 10063  df-n0 10227  df-z 10288  df-uz 10494  df-rp 10618  df-fz 11049  df-hash 11624
  Copyright terms: Public domain W3C validator