HomeHome Intuitionistic Logic Explorer
Theorem List (p. 134 of 175)
< Previous  Next >
Browser slow? Try the
Unicode version.

Mirrors  >  Metamath Home Page  >  ILE Home Page  >  Theorem List Contents  >  Recent Proofs       This page: Page List

Theorem List for Intuitionistic Logic Explorer - 13301-13400   *Has distinct variable group(s)
TypeLabelDescription
Statement
 
Theoremballotfilemiex 13301* Properties of  ( I `  C ). (Contributed by Thierry Arnoux, 12-Dec-2016.) (Revised by AV, 6-Oct-2020.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( ( I `  C )  e.  (
 1 ... ( M  +  N ) )  /\  ( ( F `  C ) `  ( I `  C ) )  =  0 ) )
 
Theoremballotfilemi1 13302* The first tie cannot be reached at the first pick. (Contributed by Thierry Arnoux, 12-Mar-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  -.  1  e.  C )  ->  ( I `
  C )  =/=  1 )
 
Theoremballotfilemii 13303* The first tie cannot be reached at the first pick. (Contributed by Thierry Arnoux, 4-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  1  e.  C )  ->  ( I `  C )  =/=  1
 )
 
Theoremballotfilemscl 13304* The set of zeroes of  F has an infimum. (Contributed by Jim Kingdon, 12-Jun-2026.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  {
 k  e.  ( 1
 ... ( M  +  N ) )  |  ( ( F `  C ) `  k
 )  =  0 }   =>    |-  ( C  e.  ( O  \  E )  -> inf ( S ,  RR ,  <  )  e.  S )
 
Theoremballotfilemsle 13305* The infimum of the set of zeroes of 
F is a lower bound. (Contributed by Jim Kingdon, 12-Jun-2026.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  {
 k  e.  ( 1
 ... ( M  +  N ) )  |  ( ( F `  C ) `  k
 )  =  0 }   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  X  e.  S )  -> inf ( S ,  RR ,  <  )  <_  X )
 
Theoremballotfilemimin 13306*  ( I `  C ) is the first tie. (Contributed by Thierry Arnoux, 1-Dec-2016.) (Revised by AV, 6-Oct-2020.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   =>    |-  ( C  e.  ( O  \  E )  ->  -.  E. k  e.  (
 1 ... ( ( I `
  C )  -  1 ) ) ( ( F `  C ) `  k )  =  0 )
 
Theoremballotfilemic 13307* If the first vote is for B, the vote on the first tie is for A. (Contributed by Thierry Arnoux, 1-Dec-2016.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  -.  1  e.  C )  ->  ( I `
  C )  e.  C )
 
Theoremballotfilem1c 13308* If the first vote is for A, the vote on the first tie is for B. (Contributed by Thierry Arnoux, 4-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  1  e.  C )  ->  -.  ( I `  C )  e.  C )
 
Theoremballotfilemsval 13309* Value of  S. (Contributed by Thierry Arnoux, 12-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( S `  C )  =  ( i  e.  ( 1 ... ( M  +  N )
 )  |->  if ( i  <_  ( I `  C ) ,  ( ( ( I `  C )  +  1 )  -  i ) ,  i
 ) ) )
 
Theoremballotfilemsv 13310* Value of  S evaluated at  J for a given counting  C. (Contributed by Thierry Arnoux, 12-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  J  e.  (
 1 ... ( M  +  N ) ) ) 
 ->  ( ( S `  C ) `  J )  =  if ( J  <_  ( I `  C ) ,  (
 ( ( I `  C )  +  1
 )  -  J ) ,  J ) )
 
Theoremballotfilemsgt1 13311*  S maps values less than  ( I `  C ) to values greater than 1. (Contributed by Thierry Arnoux, 28-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  J  e.  (
 1 ... ( M  +  N ) )  /\  J  <  ( I `  C ) )  -> 
 1  <  ( ( S `  C ) `  J ) )
 
Theoremballotfilemsdom 13312* Domain of  S for a given counting  C. (Contributed by Thierry Arnoux, 12-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  J  e.  (
 1 ... ( M  +  N ) ) ) 
 ->  ( ( S `  C ) `  J )  e.  ( 1 ... ( M  +  N ) ) )
 
Theoremballotfilemsel1i 13313* The range  ( 1 ... ( I `  C
) ) is invariant under  ( S `  C ). (Contributed by Thierry Arnoux, 28-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  J  e.  (
 1 ... ( I `  C ) ) ) 
 ->  ( ( S `  C ) `  J )  e.  ( 1 ... ( I `  C ) ) )
 
Theoremballotfilemsf1o 13314* The defined  S is a bijection, and an involution. (Contributed by Thierry Arnoux, 14-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( ( S `  C ) : ( 1 ... ( M  +  N ) ) -1-1-onto-> ( 1 ... ( M  +  N ) ) 
 /\  `' ( S `  C )  =  ( S `  C ) ) )
 
Theoremballotfilemsi 13315* The image by  S of the first tie pick is the first pick. (Contributed by Thierry Arnoux, 14-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( ( S `  C ) `  ( I `  C ) )  =  1 )
 
Theoremballotfilemsima 13316* The image by  S of an interval before the first pick. (Contributed by Thierry Arnoux, 5-May-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  J  e.  (
 1 ... ( I `  C ) ) ) 
 ->  ( ( S `  C ) " (
 1 ... J ) )  =  ( ( ( S `  C ) `
  J ) ... ( I `  C ) ) )
 
Theoremballotfilemieq 13317* If two countings share the same first tie, they also have the same swap function. (Contributed by Thierry Arnoux, 18-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  D  e.  ( O  \  E )  /\  ( I `  C )  =  ( I `  D ) )  ->  ( S `  C )  =  ( S `  D ) )
 
Theoremballotfilemrval 13318* Value of  R. (Contributed by Thierry Arnoux, 14-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( R `  C )  =  ( ( S `
  C ) " C ) )
 
Theoremballotfilemscr 13319* The image of  ( R `  C ) by  ( S `  C ). (Contributed by Thierry Arnoux, 21-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( ( S `  C ) " ( R `  C ) )  =  C )
 
Theoremballotfilemrv 13320* Value of  R evaluated at  J. (Contributed by Thierry Arnoux, 17-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  J  e.  (
 1 ... ( M  +  N ) ) ) 
 ->  ( J  e.  ( R `  C )  <->  if ( J  <_  ( I `  C ) ,  ( ( ( I `  C )  +  1 )  -  J ) ,  J )  e.  C )
 )
 
Theoremballotfilemrv1 13321* Value of  R before the tie. (Contributed by Thierry Arnoux, 11-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  J  e.  (
 1 ... ( M  +  N ) )  /\  J  <_  ( I `  C ) )  ->  ( J  e.  ( R `  C )  <->  ( ( ( I `  C )  +  1 )  -  J )  e.  C ) )
 
Theoremballotfilemrv2 13322* Value of  R after the tie. (Contributed by Thierry Arnoux, 11-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  J  e.  (
 1 ... ( M  +  N ) )  /\  ( I `  C )  <  J )  ->  ( J  e.  ( R `  C )  <->  J  e.  C ) )
 
Theoremballotfilemro 13323* Range of  R is included in  O. (Contributed by Thierry Arnoux, 17-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( R `  C )  e.  O )
 
Theoremballotfilemgval 13324* Expand the value of  .^. (Contributed by Thierry Arnoux, 21-Apr-2017.) (Revised by Jim Kingdon, 15-Jun-2026.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   &    |-  .^  =  ( u  e.  O ,  v  e. 
 Fin  |->  ( (♯ `  (
 v  i^i  u )
 )  -  (♯ `  (
 v  \  u )
 ) ) )   &    |-  ( ph  ->  U  e.  O )   &    |-  ( ph  ->  J  e.  ZZ )   &    |-  ( ph  ->  K  e.  ZZ )   &    |-  ( ph  ->  V  =  ( J ... K ) )   =>    |-  ( ph  ->  ( U  .^  V )  =  ( (♯ `  ( V  i^i  U ) )  -  (♯ `  ( V  \  U ) ) ) )
 
Theoremballotfilemgun 13325* A property of the defined  .^ operator. (Contributed by Thierry Arnoux, 26-Apr-2017.) (Revised by Jim Kingdon, 15-Jun-2026.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   &    |-  .^  =  ( u  e.  O ,  v  e. 
 Fin  |->  ( (♯ `  (
 v  i^i  u )
 )  -  (♯ `  (
 v  \  u )
 ) ) )   &    |-  ( ph  ->  U  e.  O )   &    |-  ( ph  ->  L  e.  ( J ... K ) )   =>    |-  ( ph  ->  ( U  .^  ( J ... K ) )  =  ( ( U  .^  ( J ... ( L  -  1 ) ) )  +  ( U  .^  ( L ... K ) ) ) )
 
Theoremballotfilemfg 13326* Express the value of  ( F `  C
) in terms of  .^. (Contributed by Thierry Arnoux, 21-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   &    |-  .^  =  ( u  e.  O ,  v  e. 
 Fin  |->  ( (♯ `  (
 v  i^i  u )
 )  -  (♯ `  (
 v  \  u )
 ) ) )   =>    |-  ( ( C  e.  ( O  \  E )  /\  J  e.  ( 0 ... ( M  +  N )
 ) )  ->  (
 ( F `  C ) `  J )  =  ( C  .^  (
 1 ... J ) ) )
 
Theoremballotfilemfrc 13327* Express the value of  ( F `  ( R `  C )
) in terms of the newly defined  .^. (Contributed by Thierry Arnoux, 21-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   &    |-  .^  =  ( u  e.  O ,  v  e. 
 Fin  |->  ( (♯ `  (
 v  i^i  u )
 )  -  (♯ `  (
 v  \  u )
 ) ) )   =>    |-  ( ( C  e.  ( O  \  E )  /\  J  e.  ( 1 ... ( I `  C ) ) )  ->  ( ( F `  ( R `  C ) ) `  J )  =  ( C  .^  ( ( ( S `  C ) `
  J ) ... ( I `  C ) ) ) )
 
Theoremballotfilemfrci 13328* Reverse counting preserves a tie at the first tie. (Contributed by Thierry Arnoux, 21-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   &    |-  .^  =  ( u  e.  O ,  v  e. 
 Fin  |->  ( (♯ `  (
 v  i^i  u )
 )  -  (♯ `  (
 v  \  u )
 ) ) )   =>    |-  ( C  e.  ( O  \  E ) 
 ->  ( ( F `  ( R `  C ) ) `  ( I `
  C ) )  =  0 )
 
Theoremballotfilemfrceq 13329* Value of  F for a reverse counting  ( R `  C ). (Contributed by Thierry Arnoux, 27-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   &    |-  .^  =  ( u  e.  O ,  v  e. 
 Fin  |->  ( (♯ `  (
 v  i^i  u )
 )  -  (♯ `  (
 v  \  u )
 ) ) )   =>    |-  ( ( C  e.  ( O  \  E )  /\  J  e.  ( 1 ... ( I `  C ) ) )  ->  ( ( F `  C ) `  ( ( ( S `
  C ) `  J )  -  1
 ) )  =  -u ( ( F `  ( R `  C ) ) `  J ) )
 
Theoremballotfilemfrcn0 13330* Value of  F for a reversed counting  ( R `  C ), before the first tie, cannot be zero. (Contributed by Thierry Arnoux, 25-Apr-2017.) (Revised by AV, 6-Oct-2020.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  J  e.  (
 1 ... ( M  +  N ) )  /\  J  <  ( I `  C ) )  ->  ( ( F `  ( R `  C ) ) `  J )  =/=  0 )
 
Theoremballotfilemrc 13331* Range of  R. (Contributed by Thierry Arnoux, 19-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( R `  C )  e.  ( O  \  E ) )
 
Theoremballotfilemirc 13332* Applying  R does not change first ties. (Contributed by Thierry Arnoux, 19-Apr-2017.) (Revised by AV, 6-Oct-2020.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( I `  ( R `
  C ) )  =  ( I `  C ) )
 
Theoremballotfilemrinv0 13333* Lemma for ballotfilemrinv 13334. (Contributed by Thierry Arnoux, 18-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( ( C  e.  ( O  \  E ) 
 /\  D  =  ( ( S `  C ) " C ) ) 
 ->  ( D  e.  ( O  \  E )  /\  C  =  ( ( S `  D ) " D ) ) )
 
Theoremballotfilemrinv 13334*  R is its own inverse : it is an involution. (Contributed by Thierry Arnoux, 10-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  `' R  =  R
 
Theoremballotfilem1ri 13335* When the vote on the first tie is for A, the first vote is also for A on the reverse counting. (Contributed by Thierry Arnoux, 18-Apr-2017.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( C  e.  ( O  \  E )  ->  ( 1  e.  ( R `  C )  <->  ( I `  C )  e.  C ) )
 
Theoremballotfilem7 13336*  R is a bijection between two subsets of  ( O  \  E
): one where a vote for A is picked first, and one where a vote for B is picked first. (Contributed by Thierry Arnoux, 12-Dec-2016.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( R  |`  { c  e.  ( O  \  E )  |  1  e.  c } ) : {
 c  e.  ( O 
 \  E )  |  1  e.  c } -1-1-onto-> {
 c  e.  ( O 
 \  E )  |  -.  1  e.  c }
 
Theoremballotfilem8 13337* There are as many countings with ties starting with a ballot for  A as there are starting with a ballot for  B. (Contributed by Thierry Arnoux, 7-Dec-2016.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  (♯ `  { c  e.  ( O  \  E )  |  1  e.  c } )  =  (♯ `  { c  e.  ( O  \  E )  |  -.  1  e.  c } )
 
Theoremballotfilemth 13338* Lemma for ballotfi 13339. The result, with several additional hypotheses which are for use during the proof. (Contributed by Thierry Arnoux, 7-Dec-2016.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   &    |-  I  =  ( c  e.  ( O 
 \  E )  |-> inf ( { k  e.  (
 1 ... ( M  +  N ) )  |  ( ( F `  c ) `  k
 )  =  0 } ,  RR ,  <  ) )   &    |-  S  =  ( c  e.  ( O 
 \  E )  |->  ( i  e.  ( 1
 ... ( M  +  N ) )  |->  if ( i  <_  ( I `  c ) ,  ( ( ( I `
  c )  +  1 )  -  i
 ) ,  i ) ) )   &    |-  R  =  ( c  e.  ( O 
 \  E )  |->  ( ( S `  c
 ) " c ) )   =>    |-  ( P `  E )  =  ( ( M  -  N )  /  ( M  +  N ) )
 
Theoremballotfi 13339* Bertrand's ballot problem : the probability that A is ahead throughout the counting. The proof formalized here is a proof "by reflection", as opposed to other known proofs "by induction" or "by permutation". This is Metamath 100 proof #30. (Contributed by Thierry Arnoux, 7-Dec-2016.) (Revised by Jim Kingdon, 17-Jun-2026.)
 |-  M  e.  NN   &    |-  N  e.  NN   &    |-  O  =  {
 c  e.  ( ~P ( 1 ... ( M  +  N )
 )  i^i  Fin )  |  (♯ `  c )  =  M }   &    |-  P  =  ( x  e.  ( ~P O  i^i  Fin )  |->  ( (♯ `  x )  /  (♯ `  O ) ) )   &    |-  F  =  ( c  e.  O  |->  ( i  e.  ZZ  |->  ( (♯ `  ( (
 1 ... i )  i^i  c ) )  -  (♯ `  ( ( 1
 ... i )  \  c ) ) ) ) )   &    |-  E  =  {
 c  e.  O  |  A. i  e.  (
 1 ... ( M  +  N ) ) 0  <  ( ( F `
  c ) `  i ) }   &    |-  N  <  M   =>    |-  ( P `  E )  =  ( ( M  -  N )  /  ( M  +  N ) )
 
5.3  Cardinality of real and complex number subsets
 
5.3.1  Countability of integers and rationals
 
Theoremoddennn 13340 There are as many odd positive integers as there are positive integers. (Contributed by Jim Kingdon, 11-May-2022.)
 |- 
 { z  e.  NN  |  -.  2  ||  z }  ~~  NN
 
Theoremevenennn 13341 There are as many even positive integers as there are positive integers. (Contributed by Jim Kingdon, 12-May-2022.)
 |- 
 { z  e.  NN  |  2  ||  z }  ~~  NN
 
Theoremxpnnen 13342 The Cartesian product of the set of positive integers with itself is equinumerous to the set of positive integers. (Contributed by NM, 1-Aug-2004.)
 |-  ( NN  X.  NN )  ~~  NN
 
Theoremxpomen 13343 The Cartesian product of omega (the set of ordinal natural numbers) with itself is equinumerous to omega. Exercise 1 of [Enderton] p. 133. (Contributed by NM, 23-Jul-2004.)
 |-  ( om  X.  om )  ~~  om
 
Theoremxpct 13344 The cartesian product of two sets dominated by  om is dominated by  om. (Contributed by Thierry Arnoux, 24-Sep-2017.)
 |-  ( ( A  ~<_  om  /\  B 
 ~<_  om )  ->  ( A  X.  B )  ~<_  om )
 
Theoremunennn 13345 The union of two disjoint countably infinite sets is countably infinite. (Contributed by Jim Kingdon, 13-May-2022.)
 |-  ( ( A  ~~  NN  /\  B  ~~  NN  /\  ( A  i^i  B )  =  (/) )  ->  ( A  u.  B )  ~~  NN )
 
Theoremznnen 13346 The set of integers and the set of positive integers are equinumerous. Corollary 8.1.23 of [AczelRathjen], p. 75. (Contributed by NM, 31-Jul-2004.)
 |- 
 ZZ  ~~  NN
 
Theoremennnfonelemdc 13347* Lemma for ennnfone 13373. A direct consequence of fidcenumlemrk 7278. (Contributed by Jim Kingdon, 15-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  P  e.  om )   =>    |-  ( ph  -> DECID  ( F `
  P )  e.  ( F " P ) )
 
Theoremennnfonelemk 13348* Lemma for ennnfone 13373. (Contributed by Jim Kingdon, 15-Jul-2023.)
 |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  K  e.  om )   &    |-  ( ph  ->  N  e.  om )   &    |-  ( ph  ->  A. j  e.  suc  N ( F `
  K )  =/=  ( F `  j
 ) )   =>    |-  ( ph  ->  N  e.  K )
 
Theoremennnfonelemj0 13349* Lemma for ennnfone 13373. Initial state for  J. (Contributed by Jim Kingdon, 20-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   =>    |-  ( ph  ->  ( J `  0 )  e. 
 { g  e.  ( A  ^pm  om )  | 
 dom  g  e.  om } )
 
Theoremennnfonelemjn 13350* Lemma for ennnfone 13373. Non-initial state for  J. (Contributed by Jim Kingdon, 20-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   =>    |-  ( ( ph  /\  f  e.  ( ZZ>= `  ( 0  +  1 ) ) )  ->  ( J `  f )  e.  om )
 
Theoremennnfonelemg 13351* Lemma for ennnfone 13373. Closure for  G. (Contributed by Jim Kingdon, 20-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   =>    |-  ( ( ph  /\  (
 f  e.  { g  e.  ( A  ^pm  om )  |  dom  g  e.  om } 
 /\  j  e.  om ) )  ->  ( f G j )  e. 
 { g  e.  ( A  ^pm  om )  | 
 dom  g  e.  om } )
 
Theoremennnfonelemh 13352* Lemma for ennnfone 13373. (Contributed by Jim Kingdon, 8-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   =>    |-  ( ph  ->  H : NN0 --> ( A  ^pm  om ) )
 
Theoremennnfonelem0 13353* Lemma for ennnfone 13373. Initial value. (Contributed by Jim Kingdon, 15-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   =>    |-  ( ph  ->  ( H `  0 )  =  (/) )
 
Theoremennnfonelemp1 13354* Lemma for ennnfone 13373. Value of  H at a successor. (Contributed by Jim Kingdon, 23-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  P  e.  NN0 )   =>    |-  ( ph  ->  ( H `  ( P  +  1 ) )  =  if ( ( F `
  ( `' N `  P ) )  e.  ( F " ( `' N `  P ) ) ,  ( H `
  P ) ,  ( ( H `  P )  u.  { <. dom  ( H `  P ) ,  ( F `  ( `' N `  P ) ) >. } ) ) )
 
Theoremennnfonelem1 13355* Lemma for ennnfone 13373. Second value. (Contributed by Jim Kingdon, 19-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   =>    |-  ( ph  ->  ( H `  1 )  =  { <. (/) ,  ( F `
  (/) ) >. } )
 
Theoremennnfonelemom 13356* Lemma for ennnfone 13373. 
H yields finite sequences. (Contributed by Jim Kingdon, 19-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  P  e.  NN0 )   =>    |-  ( ph  ->  dom  ( H `  P )  e. 
 om )
 
Theoremennnfonelemhdmp1 13357* Lemma for ennnfone 13373. Domain at a successor where we need to add an element to the sequence. (Contributed by Jim Kingdon, 23-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  P  e.  NN0 )   &    |-  ( ph  ->  -.  ( F `  ( `' N `  P ) )  e.  ( F
 " ( `' N `  P ) ) )   =>    |-  ( ph  ->  dom  ( H `
  ( P  +  1 ) )  = 
 suc  dom  ( H `  P ) )
 
Theoremennnfonelemss 13358* Lemma for ennnfone 13373. We only add elements to  H as the index increases. (Contributed by Jim Kingdon, 15-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  P  e.  NN0 )   =>    |-  ( ph  ->  ( H `  P )  C_  ( H `  ( P  +  1 ) ) )
 
Theoremennnfoneleminc 13359* Lemma for ennnfone 13373. We only add elements to  H as the index increases. (Contributed by Jim Kingdon, 21-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  P  e.  NN0 )   &    |-  ( ph  ->  Q  e.  NN0 )   &    |-  ( ph  ->  P 
 <_  Q )   =>    |-  ( ph  ->  ( H `  P )  C_  ( H `  Q ) )
 
Theoremennnfonelemkh 13360* Lemma for ennnfone 13373. Because we add zero or one entries for each new index, the length of each sequence is no greater than its index. (Contributed by Jim Kingdon, 19-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  P  e.  NN0 )   =>    |-  ( ph  ->  dom  ( H `  P )  C_  ( `' N `  P ) )
 
Theoremennnfonelemhf1o 13361* Lemma for ennnfone 13373. Each of the functions in  H is one to one and onto an image of  F. (Contributed by Jim Kingdon, 17-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  P  e.  NN0 )   =>    |-  ( ph  ->  ( H `  P ) : dom  ( H `  P ) -1-1-onto-> ( F " ( `' N `  P ) ) )
 
Theoremennnfonelemex 13362* Lemma for ennnfone 13373. Extending the sequence  ( H `  P ) to include an additional element. (Contributed by Jim Kingdon, 19-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  P  e.  NN0 )   =>    |-  ( ph  ->  E. i  e.  NN0  dom  ( H `  P )  e.  dom  ( H `  i ) )
 
Theoremennnfonelemhom 13363* Lemma for ennnfone 13373. The sequences in  H increase in length without bound if you go out far enough. (Contributed by Jim Kingdon, 19-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  M  e.  om )   =>    |-  ( ph  ->  E. i  e.  NN0  M  e.  dom  ( H `  i ) )
 
Theoremennnfonelemrnh 13364* Lemma for ennnfone 13373. A consequence of ennnfonelemss 13358. (Contributed by Jim Kingdon, 16-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  ( ph  ->  X  e.  ran  H )   &    |-  ( ph  ->  Y  e.  ran  H )   =>    |-  ( ph  ->  ( X  C_  Y  \/  Y  C_  X ) )
 
Theoremennnfonelemfun 13365* Lemma for ennnfone 13373. 
L is a function. (Contributed by Jim Kingdon, 16-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  L  =  U_ i  e.  NN0  ( H `  i )   =>    |-  ( ph  ->  Fun  L )
 
Theoremennnfonelemf1 13366* Lemma for ennnfone 13373. 
L is one-to-one. (Contributed by Jim Kingdon, 16-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  L  =  U_ i  e.  NN0  ( H `  i )   =>    |-  ( ph  ->  L : dom  L -1-1-> A )
 
Theoremennnfonelemrn 13367* Lemma for ennnfone 13373. 
L is onto  A. (Contributed by Jim Kingdon, 16-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  L  =  U_ i  e.  NN0  ( H `  i )   =>    |-  ( ph  ->  ran  L  =  A )
 
Theoremennnfonelemdm 13368* Lemma for ennnfone 13373. The function  L is defined everywhere. (Contributed by Jim Kingdon, 16-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  L  =  U_ i  e.  NN0  ( H `  i )   =>    |-  ( ph  ->  dom  L  =  om )
 
Theoremennnfonelemen 13369* Lemma for ennnfone 13373. The result. (Contributed by Jim Kingdon, 16-Jul-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e.  om  E. k  e.  om  A. j  e.  suc  n ( F `
  k )  =/=  ( F `  j
 ) )   &    |-  G  =  ( x  e.  ( A 
 ^pm  om ) ,  y  e.  om  |->  if ( ( F `
  y )  e.  ( F " y
 ) ,  x ,  ( x  u.  { <. dom 
 x ,  ( F `
  y ) >. } ) ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  J  =  ( x  e.  NN0  |->  if ( x  =  0 ,  (/)
 ,  ( `' N `  ( x  -  1
 ) ) ) )   &    |-  H  =  seq 0
 ( G ,  J )   &    |-  L  =  U_ i  e.  NN0  ( H `  i )   =>    |-  ( ph  ->  A  ~~ 
 NN )
 
Theoremennnfonelemnn0 13370* Lemma for ennnfone 13373. A version of ennnfonelemen 13369 expressed in terms of  NN0 instead of  om. (Contributed by Jim Kingdon, 27-Oct-2022.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : NN0
 -onto-> A )   &    |-  ( ph  ->  A. n  e.  NN0  E. k  e.  NN0  A. j  e.  (
 0 ... n ) ( F `  k )  =/=  ( F `  j ) )   &    |-  N  = frec ( ( x  e. 
 ZZ  |->  ( x  +  1 ) ) ,  0 )   =>    |-  ( ph  ->  A  ~~ 
 NN )
 
Theoremennnfonelemr 13371* Lemma for ennnfone 13373. The interesting direction, expressed in deduction form. (Contributed by Jim Kingdon, 27-Oct-2022.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  F : NN0
 -onto-> A )   &    |-  ( ph  ->  A. n  e.  NN0  E. k  e.  NN0  A. j  e.  (
 0 ... n ) ( F `  k )  =/=  ( F `  j ) )   =>    |-  ( ph  ->  A 
 ~~  NN )
 
Theoremennnfonelemim 13372* Lemma for ennnfone 13373. The trivial direction. (Contributed by Jim Kingdon, 27-Oct-2022.)
 |-  ( A  ~~  NN  ->  ( A. x  e.  A  A. y  e.  A DECID  x  =  y  /\  E. f ( f :
 NN0 -onto-> A  /\  A. n  e.  NN0  E. k  e. 
 NN0  A. j  e.  (
 0 ... n ) ( f `  k )  =/=  ( f `  j ) ) ) )
 
Theoremennnfone 13373* A condition for a set being countably infinite. Corollary 8.1.13 of [AczelRathjen], p. 73. Roughly speaking, the condition says that 
A is countable (that's the  f : NN0 -onto-> A part, as seen in theorems like ctm 7455), infinite (that's the part about being able to find an element of  A distinct from any mapping of a natural number via  f), and has decidable equality. (Contributed by Jim Kingdon, 27-Oct-2022.)
 |-  ( A  ~~  NN  <->  ( A. x  e.  A  A. y  e.  A DECID  x  =  y  /\  E. f
 ( f : NN0 -onto-> A 
 /\  A. n  e.  NN0  E. k  e.  NN0  A. j  e.  ( 0 ... n ) ( f `  k )  =/=  (
 f `  j )
 ) ) )
 
Theoremexmidunben 13374* If any unbounded set of positive integers is equinumerous to  NN, then the Limited Principle of Omniscience (LPO) implies excluded middle. (Contributed by Jim Kingdon, 29-Jul-2023.)
 |-  ( ( A. x ( ( x  C_  NN  /\  A. m  e. 
 NN  E. n  e.  x  m  <  n )  ->  x  ~~  NN )  /\  om  e. Omni )  -> EXMID )
 
Theoremctinfomlemom 13375* Lemma for ctinfom 13376. Converting between  om and  NN0. (Contributed by Jim Kingdon, 10-Aug-2023.)
 |-  N  = frec ( ( x  e.  ZZ  |->  ( x  +  1 ) ) ,  0 )   &    |-  G  =  ( F  o.  `' N )   &    |-  ( ph  ->  F : om -onto-> A )   &    |-  ( ph  ->  A. n  e. 
 om  E. k  e.  om  -.  ( F `  k
 )  e.  ( F
 " n ) )   =>    |-  ( ph  ->  ( G : NN0 -onto-> A  /\  A. m  e.  NN0  E. j  e. 
 NN0  A. i  e.  (
 0 ... m ) ( G `  j )  =/=  ( G `  i ) ) )
 
Theoremctinfom 13376* A condition for a set being countably infinite. Restates ennnfone 13373 in terms of  om and function image. Like ennnfone 13373 the condition can be summarized as  A being countable, infinite, and having decidable equality. (Contributed by Jim Kingdon, 7-Aug-2023.)
 |-  ( A  ~~  NN  <->  ( A. x  e.  A  A. y  e.  A DECID  x  =  y  /\  E. f
 ( f : om -onto-> A  /\  A. n  e. 
 om  E. k  e.  om  -.  ( f `  k
 )  e.  ( f
 " n ) ) ) )
 
Theoreminffinp1 13377* An infinite set contains an element not contained in a given finite subset. (Contributed by Jim Kingdon, 7-Aug-2023.)
 |-  ( ph  ->  A. x  e.  A  A. y  e.  A DECID  x  =  y )   &    |-  ( ph  ->  om  ~<_  A )   &    |-  ( ph  ->  B  C_  A )   &    |-  ( ph  ->  B  e.  Fin )   =>    |-  ( ph  ->  E. x  e.  A  -.  x  e.  B )
 
Theoremctinf 13378* A set is countably infinite if and only if it has decidable equality, is countable, and is infinite. (Contributed by Jim Kingdon, 7-Aug-2023.)
 |-  ( A  ~~  NN  <->  ( A. x  e.  A  A. y  e.  A DECID  x  =  y  /\  E. f  f : om -onto-> A  /\  om  ~<_  A ) )
 
Theoremqnnen 13379 The rational numbers are countably infinite. Corollary 8.1.23 of [AczelRathjen], p. 75. This is Metamath 100 proof #3. (Contributed by Jim Kingdon, 11-Aug-2023.)
 |- 
 QQ  ~~  NN
 
Theoremenctlem 13380* Lemma for enct 13381. One direction of the biconditional. (Contributed by Jim Kingdon, 23-Dec-2023.)
 |-  ( A  ~~  B  ->  ( E. f  f : om -onto-> ( A ⊔  1o )  ->  E. g  g : om -onto-> ( B ⊔  1o ) ) )
 
Theoremenct 13381* Countability is invariant relative to equinumerosity. (Contributed by Jim Kingdon, 23-Dec-2023.)
 |-  ( A  ~~  B  ->  ( E. f  f : om -onto-> ( A ⊔  1o )  <->  E. g  g : om -onto-> ( B ⊔  1o )
 ) )
 
Theoremctiunctlemu1st 13382* Lemma for ctiunct 13388. (Contributed by Jim Kingdon, 28-Oct-2023.)
 |-  ( ph  ->  S  C_ 
 om )   &    |-  ( ph  ->  A. n  e.  om DECID  n  e.  S )   &    |-  ( ph  ->  F : S -onto-> A )   &    |-  ( ( ph  /\  x  e.  A )  ->  T  C_ 
 om )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  A. n  e.  om DECID  n  e.  T )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  G : T -onto-> B )   &    |-  ( ph  ->  J : om
 -1-1-onto-> ( om  X.  om )
 )   &    |-  U  =  { z  e.  om  |  ( ( 1st `  ( J `  z ) )  e.  S  /\  ( 2nd `  ( J `  z
 ) )  e.  [_ ( F `  ( 1st `  ( J `  z
 ) ) )  /  x ]_ T ) }   &    |-  ( ph  ->  N  e.  U )   =>    |-  ( ph  ->  ( 1st `  ( J `  N ) )  e.  S )
 
Theoremctiunctlemu2nd 13383* Lemma for ctiunct 13388. (Contributed by Jim Kingdon, 28-Oct-2023.)
 |-  ( ph  ->  S  C_ 
 om )   &    |-  ( ph  ->  A. n  e.  om DECID  n  e.  S )   &    |-  ( ph  ->  F : S -onto-> A )   &    |-  ( ( ph  /\  x  e.  A )  ->  T  C_ 
 om )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  A. n  e.  om DECID  n  e.  T )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  G : T -onto-> B )   &    |-  ( ph  ->  J : om
 -1-1-onto-> ( om  X.  om )
 )   &    |-  U  =  { z  e.  om  |  ( ( 1st `  ( J `  z ) )  e.  S  /\  ( 2nd `  ( J `  z
 ) )  e.  [_ ( F `  ( 1st `  ( J `  z
 ) ) )  /  x ]_ T ) }   &    |-  ( ph  ->  N  e.  U )   =>    |-  ( ph  ->  ( 2nd `  ( J `  N ) )  e.  [_ ( F `  ( 1st `  ( J `  N ) ) ) 
 /  x ]_ T )
 
Theoremctiunctlemuom 13384 Lemma for ctiunct 13388. (Contributed by Jim Kingdon, 28-Oct-2023.)
 |-  ( ph  ->  S  C_ 
 om )   &    |-  ( ph  ->  A. n  e.  om DECID  n  e.  S )   &    |-  ( ph  ->  F : S -onto-> A )   &    |-  ( ( ph  /\  x  e.  A )  ->  T  C_ 
 om )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  A. n  e.  om DECID  n  e.  T )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  G : T -onto-> B )   &    |-  ( ph  ->  J : om
 -1-1-onto-> ( om  X.  om )
 )   &    |-  U  =  { z  e.  om  |  ( ( 1st `  ( J `  z ) )  e.  S  /\  ( 2nd `  ( J `  z
 ) )  e.  [_ ( F `  ( 1st `  ( J `  z
 ) ) )  /  x ]_ T ) }   =>    |-  ( ph  ->  U  C_  om )
 
Theoremctiunctlemudc 13385* Lemma for ctiunct 13388. (Contributed by Jim Kingdon, 28-Oct-2023.)
 |-  ( ph  ->  S  C_ 
 om )   &    |-  ( ph  ->  A. n  e.  om DECID  n  e.  S )   &    |-  ( ph  ->  F : S -onto-> A )   &    |-  ( ( ph  /\  x  e.  A )  ->  T  C_ 
 om )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  A. n  e.  om DECID  n  e.  T )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  G : T -onto-> B )   &    |-  ( ph  ->  J : om
 -1-1-onto-> ( om  X.  om )
 )   &    |-  U  =  { z  e.  om  |  ( ( 1st `  ( J `  z ) )  e.  S  /\  ( 2nd `  ( J `  z
 ) )  e.  [_ ( F `  ( 1st `  ( J `  z
 ) ) )  /  x ]_ T ) }   =>    |-  ( ph  ->  A. n  e.  om DECID  n  e.  U )
 
Theoremctiunctlemf 13386* Lemma for ctiunct 13388. (Contributed by Jim Kingdon, 28-Oct-2023.)
 |-  ( ph  ->  S  C_ 
 om )   &    |-  ( ph  ->  A. n  e.  om DECID  n  e.  S )   &    |-  ( ph  ->  F : S -onto-> A )   &    |-  ( ( ph  /\  x  e.  A )  ->  T  C_ 
 om )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  A. n  e.  om DECID  n  e.  T )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  G : T -onto-> B )   &    |-  ( ph  ->  J : om
 -1-1-onto-> ( om  X.  om )
 )   &    |-  U  =  { z  e.  om  |  ( ( 1st `  ( J `  z ) )  e.  S  /\  ( 2nd `  ( J `  z
 ) )  e.  [_ ( F `  ( 1st `  ( J `  z
 ) ) )  /  x ]_ T ) }   &    |-  H  =  ( n  e.  U  |->  ( [_ ( F `  ( 1st `  ( J `  n ) ) ) 
 /  x ]_ G `  ( 2nd `  ( J `  n ) ) ) )   =>    |-  ( ph  ->  H : U --> U_ x  e.  A  B )
 
Theoremctiunctlemfo 13387* Lemma for ctiunct 13388. (Contributed by Jim Kingdon, 28-Oct-2023.)
 |-  ( ph  ->  S  C_ 
 om )   &    |-  ( ph  ->  A. n  e.  om DECID  n  e.  S )   &    |-  ( ph  ->  F : S -onto-> A )   &    |-  ( ( ph  /\  x  e.  A )  ->  T  C_ 
 om )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  A. n  e.  om DECID  n  e.  T )   &    |-  ( ( ph  /\  x  e.  A ) 
 ->  G : T -onto-> B )   &    |-  ( ph  ->  J : om
 -1-1-onto-> ( om  X.  om )
 )   &    |-  U  =  { z  e.  om  |  ( ( 1st `  ( J `  z ) )  e.  S  /\  ( 2nd `  ( J `  z
 ) )  e.  [_ ( F `  ( 1st `  ( J `  z
 ) ) )  /  x ]_ T ) }   &    |-  H  =  ( n  e.  U  |->  ( [_ ( F `  ( 1st `  ( J `  n ) ) ) 
 /  x ]_ G `  ( 2nd `  ( J `  n ) ) ) )   &    |-  F/_ x H   &    |-  F/_ x U   =>    |-  ( ph  ->  H : U -onto-> U_ x  e.  A  B )
 
Theoremctiunct 13388* A sequence of enumerations gives an enumeration of the union. We refer to "sequence of enumerations" rather than "countably many countable sets" because the hypothesis provides more than countability for each  B ( x ): it refers to  B ( x ) together with the  G ( x ) which enumerates it. Theorem 8.1.19 of [AczelRathjen], p. 74.

For "countably many countable sets" the key hypothesis would be  ( ph  /\  x  e.  A )  ->  E. g g : om -onto-> ( B ⊔  1o ). This is almost omiunct 13392 (which uses countable choice) although that is for a countably infinite collection not any countable collection.

Compare with the case of two sets instead of countably many, as seen at unct 13390, which says that the union of two countable sets is countable .

The proof proceeds by mapping a natural number to a pair of natural numbers (by xpomen 13343) and using the first number to map to an element  x of  A and the second number to map to an element of B(x) . In this way we are able to map to every element of  U_ x  e.  A B. Although it would be possible to work directly with countability expressed as  F : om -onto-> ( A ⊔  1o ), we instead use functions from subsets of the natural numbers via ctssdccl 7457 and ctssdc 7459.

(Contributed by Jim Kingdon, 31-Oct-2023.)

 |-  ( ph  ->  F : om -onto-> ( A ⊔  1o )
 )   &    |-  ( ( ph  /\  x  e.  A )  ->  G : om -onto-> ( B ⊔  1o )
 )   =>    |-  ( ph  ->  E. h  h : om -onto-> ( U_ x  e.  A  B ⊔  1o ) )
 
Theoremctiunctal 13389* Variation of ctiunct 13388 which allows  x to be present in  ph. (Contributed by Jim Kingdon, 5-May-2024.)
 |-  ( ph  ->  F : om -onto-> ( A ⊔  1o )
 )   &    |-  ( ph  ->  A. x  e.  A  G : om -onto->
 ( B ⊔  1o ) )   =>    |-  ( ph  ->  E. h  h : om -onto-> ( U_ x  e.  A  B ⊔  1o ) )
 
Theoremunct 13390* The union of two countable sets is countable. Corollary 8.1.20 of [AczelRathjen], p. 75. (Contributed by Jim Kingdon, 1-Nov-2023.)
 |-  ( ( E. f  f : om -onto-> ( A ⊔  1o )  /\  E. g  g : om -onto-> ( B ⊔  1o ) )  ->  E. h  h : om -onto-> ( ( A  u.  B ) ⊔  1o ) )
 
Theoremomctfn 13391* Using countable choice to find a sequence of enumerations for a collection of countable sets. Lemma 8.1.27 of [AczelRathjen], p. 77. (Contributed by Jim Kingdon, 19-Apr-2024.)
 |-  ( ph  -> CCHOICE )   &    |-  ( ( ph  /\  x  e.  om )  ->  E. g  g : om -onto-> ( B ⊔  1o )
 )   =>    |-  ( ph  ->  E. f
 ( f  Fn  om  /\ 
 A. x  e.  om  ( f `  x ) : om -onto-> ( B ⊔  1o ) ) )
 
Theoremomiunct 13392* The union of a countably infinite collection of countable sets is countable. Theorem 8.1.28 of [AczelRathjen], p. 78. Compare with ctiunct 13388 which has a stronger hypothesis but does not require countable choice. (Contributed by Jim Kingdon, 5-May-2024.)
 |-  ( ph  -> CCHOICE )   &    |-  ( ( ph  /\  x  e.  om )  ->  E. g  g : om -onto-> ( B ⊔  1o )
 )   =>    |-  ( ph  ->  E. h  h : om -onto-> ( U_ x  e.  om  B ⊔  1o )
 )
 
Theoremssomct 13393* A decidable subset of  om is countable. (Contributed by Jim Kingdon, 19-Sep-2024.)
 |-  ( ( A  C_  om 
 /\  A. x  e.  om DECID  x  e.  A )  ->  E. f  f : om -onto-> ( A ⊔  1o ) )
 
Theoremssnnctlemct 13394* Lemma for ssnnct 13395. The result. (Contributed by Jim Kingdon, 29-Sep-2024.)
 |-  G  = frec ( ( x  e.  ZZ  |->  ( x  +  1 ) ) ,  1 )   =>    |-  ( ( A  C_  NN  /\  A. x  e. 
 NN DECID  x  e.  A )  ->  E. f  f : om -onto-> ( A ⊔  1o )
 )
 
Theoremssnnct 13395* A decidable subset of  NN is countable. (Contributed by Jim Kingdon, 29-Sep-2024.)
 |-  ( ( A  C_  NN  /\  A. x  e. 
 NN DECID  x  e.  A )  ->  E. f  f : om -onto-> ( A ⊔  1o )
 )
 
Theoremnninfdclemcl 13396* Lemma for nninfdc 13401. (Contributed by Jim Kingdon, 25-Sep-2024.)
 |-  ( ph  ->  A  C_ 
 NN )   &    |-  ( ph  ->  A. x  e.  NN DECID  x  e.  A )   &    |-  ( ph  ->  A. m  e.  NN  E. n  e.  A  m  <  n )   &    |-  ( ph  ->  P  e.  A )   &    |-  ( ph  ->  Q  e.  A )   =>    |-  ( ph  ->  ( P ( y  e. 
 NN ,  z  e. 
 NN  |-> inf ( ( A  i^i  ( ZZ>= `  (
 y  +  1 ) ) ) ,  RR ,  <  ) ) Q )  e.  A )
 
Theoremnninfdclemf 13397* Lemma for nninfdc 13401. A function from the natural numbers into  A. (Contributed by Jim Kingdon, 23-Sep-2024.)
 |-  ( ph  ->  A  C_ 
 NN )   &    |-  ( ph  ->  A. x  e.  NN DECID  x  e.  A )   &    |-  ( ph  ->  A. m  e.  NN  E. n  e.  A  m  <  n )   &    |-  ( ph  ->  ( J  e.  A  /\  1  <  J ) )   &    |-  F  =  seq 1
 ( ( y  e. 
 NN ,  z  e. 
 NN  |-> inf ( ( A  i^i  ( ZZ>= `  (
 y  +  1 ) ) ) ,  RR ,  <  ) ) ,  ( i  e.  NN  |->  J ) )   =>    |-  ( ph  ->  F : NN --> A )
 
Theoremnninfdclemp1 13398* Lemma for nninfdc 13401. Each element of the sequence  F is greater than the previous element. (Contributed by Jim Kingdon, 26-Sep-2024.)
 |-  ( ph  ->  A  C_ 
 NN )   &    |-  ( ph  ->  A. x  e.  NN DECID  x  e.  A )   &    |-  ( ph  ->  A. m  e.  NN  E. n  e.  A  m  <  n )   &    |-  ( ph  ->  ( J  e.  A  /\  1  <  J ) )   &    |-  F  =  seq 1
 ( ( y  e. 
 NN ,  z  e. 
 NN  |-> inf ( ( A  i^i  ( ZZ>= `  (
 y  +  1 ) ) ) ,  RR ,  <  ) ) ,  ( i  e.  NN  |->  J ) )   &    |-  ( ph  ->  U  e.  NN )   =>    |-  ( ph  ->  ( F `  U )  < 
 ( F `  ( U  +  1 )
 ) )
 
Theoremnninfdclemlt 13399* Lemma for nninfdc 13401. The function from nninfdclemf 13397 is strictly monotonic. (Contributed by Jim Kingdon, 24-Sep-2024.)
 |-  ( ph  ->  A  C_ 
 NN )   &    |-  ( ph  ->  A. x  e.  NN DECID  x  e.  A )   &    |-  ( ph  ->  A. m  e.  NN  E. n  e.  A  m  <  n )   &    |-  ( ph  ->  ( J  e.  A  /\  1  <  J ) )   &    |-  F  =  seq 1
 ( ( y  e. 
 NN ,  z  e. 
 NN  |-> inf ( ( A  i^i  ( ZZ>= `  (
 y  +  1 ) ) ) ,  RR ,  <  ) ) ,  ( i  e.  NN  |->  J ) )   &    |-  ( ph  ->  U  e.  NN )   &    |-  ( ph  ->  V  e.  NN )   &    |-  ( ph  ->  U  <  V )   =>    |-  ( ph  ->  ( F `  U )  <  ( F `  V ) )
 
Theoremnninfdclemf1 13400* Lemma for nninfdc 13401. The function from nninfdclemf 13397 is one-to-one. (Contributed by Jim Kingdon, 23-Sep-2024.)
 |-  ( ph  ->  A  C_ 
 NN )   &    |-  ( ph  ->  A. x  e.  NN DECID  x  e.  A )   &    |-  ( ph  ->  A. m  e.  NN  E. n  e.  A  m  <  n )   &    |-  ( ph  ->  ( J  e.  A  /\  1  <  J ) )   &    |-  F  =  seq 1
 ( ( y  e. 
 NN ,  z  e. 
 NN  |-> inf ( ( A  i^i  ( ZZ>= `  (
 y  +  1 ) ) ) ,  RR ,  <  ) ) ,  ( i  e.  NN  |->  J ) )   =>    |-  ( ph  ->  F : NN -1-1-> A )
    < Previous  Next >

Page List
Jump to page: Contents  1 1-100 2 101-200 3 201-300 4 301-400 5 401-500 6 501-600 7 601-700 8 701-800 9 801-900 10 901-1000 11 1001-1100 12 1101-1200 13 1201-1300 14 1301-1400 15 1401-1500 16 1501-1600 17 1601-1700 18 1701-1800 19 1801-1900 20 1901-2000 21 2001-2100 22 2101-2200 23 2201-2300 24 2301-2400 25 2401-2500 26 2501-2600 27 2601-2700 28 2701-2800 29 2801-2900 30 2901-3000 31 3001-3100 32 3101-3200 33 3201-3300 34 3301-3400 35 3401-3500 36 3501-3600 37 3601-3700 38 3701-3800 39 3801-3900 40 3901-4000 41 4001-4100 42 4101-4200 43 4201-4300 44 4301-4400 45 4401-4500 46 4501-4600 47 4601-4700 48 4701-4800 49 4801-4900 50 4901-5000 51 5001-5100 52 5101-5200 53 5201-5300 54 5301-5400 55 5401-5500 56 5501-5600 57 5601-5700 58 5701-5800 59 5801-5900 60 5901-6000 61 6001-6100 62 6101-6200 63 6201-6300 64 6301-6400 65 6401-6500 66 6501-6600 67 6601-6700 68 6701-6800 69 6801-6900 70 6901-7000 71 7001-7100 72 7101-7200 73 7201-7300 74 7301-7400 75 7401-7500 76 7501-7600 77 7601-7700 78 7701-7800 79 7801-7900 80 7901-8000 81 8001-8100 82 8101-8200 83 8201-8300 84 8301-8400 85 8401-8500 86 8501-8600 87 8601-8700 88 8701-8800 89 8801-8900 90 8901-9000 91 9001-9100 92 9101-9200 93 9201-9300 94 9301-9400 95 9401-9500 96 9501-9600 97 9601-9700 98 9701-9800 99 9801-9900 100 9901-10000 101 10001-10100 102 10101-10200 103 10201-10300 104 10301-10400 105 10401-10500 106 10501-10600 107 10601-10700 108 10701-10800 109 10801-10900 110 10901-11000 111 11001-11100 112 11101-11200 113 11201-11300 114 11301-11400 115 11401-11500 116 11501-11600 117 11601-11700 118 11701-11800 119 11801-11900 120 11901-12000 121 12001-12100 122 12101-12200 123 12201-12300 124 12301-12400 125 12401-12500 126 12501-12600 127 12601-12700 128 12701-12800 129 12801-12900 130 12901-13000 131 13001-13100 132 13101-13200 133 13201-13300 134 13301-13400 135 13401-13500 136 13501-13600 137 13601-13700 138 13701-13800 139 13801-13900 140 13901-14000 141 14001-14100 142 14101-14200 143 14201-14300 144 14301-14400 145 14401-14500 146 14501-14600 147 14601-14700 148 14701-14800 149 14801-14900 150 14901-15000 151 15001-15100 152 15101-15200 153 15201-15300 154 15301-15400 155 15401-15500 156 15501-15600 157 15601-15700 158 15701-15800 159 15801-15900 160 15901-16000 161 16001-16100 162 16101-16200 163 16201-16300 164 16301-16400 165 16401-16500 166 16501-16600 167 16601-16700 168 16701-16800 169 16801-16900 170 16901-17000 171 17001-17100 172 17101-17200 173 17201-17300 174 17301-17400 175 17401-17403
  Copyright terms: Public domain < Previous  Next >