Article RFINSEQ, MML version 4.99.1005

:: RFINSEQ:prednot 1 => RFINSEQ:pred 1
definition
  let a1, a2 be Relation-like set;
  pred A1,A2 are_fiberwise_equipotent means
    for b1 being set holds
       Card (a1 " {b1}) = Card (a2 " {b1});
  symmetry;
::  for a1, a2 being Relation-like set
::        st a1,a2 are_fiberwise_equipotent
::     holds a2,a1 are_fiberwise_equipotent;
  reflexivity;
::  for a1 being Relation-like set holds
::     a1,a1 are_fiberwise_equipotent;
end;

:: RFINSEQ:dfs 1
definiens
  let a1, a2 be Relation-like set;
To prove
     a1,a2 are_fiberwise_equipotent
it is sufficient to prove
  thus for b1 being set holds
       Card (a1 " {b1}) = Card (a2 " {b1});

:: RFINSEQ:def 1
theorem
for b1, b2 being Relation-like set holds
   b1,b2 are_fiberwise_equipotent
iff
   for b3 being set holds
      Card (b1 " {b3}) = Card (b2 " {b3});

:: RFINSEQ:th 1
theorem
for b1, b2 being Relation-like Function-like set
      st b1,b2 are_fiberwise_equipotent
   holds proj2 b1 = proj2 b2;

:: RFINSEQ:th 2
theorem
for b1, b2, b3 being Relation-like Function-like set
      st b1,b2 are_fiberwise_equipotent & b1,b3 are_fiberwise_equipotent
   holds b2,b3 are_fiberwise_equipotent;

:: RFINSEQ:th 3
theorem
for b1, b2 being Relation-like Function-like set holds
   b1,b2 are_fiberwise_equipotent
iff
   ex b3 being Relation-like Function-like set st
      proj1 b3 = proj1 b1 & proj2 b3 = proj1 b2 & b3 is one-to-one & b1 = b3 * b2;

:: RFINSEQ:th 4
theorem
for b1, b2 being Relation-like Function-like set holds
   b1,b2 are_fiberwise_equipotent
iff
   for b3 being set holds
      Card (b1 " b3) = Card (b2 " b3);

:: RFINSEQ:th 5
theorem
for b1 being non empty set
for b2, b3 being Relation-like Function-like set
      st proj2 b2 c= b1 & proj2 b3 c= b1
   holds    b2,b3 are_fiberwise_equipotent
   iff
      for b4 being Element of b1 holds
         Card (b2 " {b4}) = Card (b3 " {b4});

:: RFINSEQ:th 6
theorem
for b1, b2 being Relation-like Function-like set
      st proj1 b1 = proj1 b2
   holds    b1,b2 are_fiberwise_equipotent
   iff
      ex b3 being Function-like quasi_total bijective Relation of proj1 b1,proj1 b1 st
         b1 = b3 * b2;

:: RFINSEQ:th 7
theorem
for b1, b2 being Relation-like Function-like set
      st b1,b2 are_fiberwise_equipotent
   holds Card proj1 b1 = Card proj1 b2;

:: RFINSEQ:th 9
theorem
for b1, b2 being Relation-like Function-like finite set holds
   b1,b2 are_fiberwise_equipotent
iff
   for b3 being set holds
      card (b1 " b3) = card (b2 " b3);

:: RFINSEQ:th 10
theorem
for b1, b2 being Relation-like Function-like finite set
      st b1,b2 are_fiberwise_equipotent
   holds card proj1 b1 = card proj1 b2;

:: RFINSEQ:th 11
theorem
for b1 being non empty set
for b2, b3 being Relation-like Function-like finite set
      st proj2 b2 c= b1 & proj2 b3 c= b1
   holds    b2,b3 are_fiberwise_equipotent
   iff
      for b4 being Element of b1 holds
         card (b2 " {b4}) = card (b3 " {b4});

:: RFINSEQ:th 13
theorem
for b1, b2 being Relation-like Function-like FinSequence-like set holds
   b1,b2 are_fiberwise_equipotent
iff
   for b3 being set holds
      card (b1 " b3) = card (b2 " b3);

:: RFINSEQ:th 14
theorem
for b1, b2, b3 being Relation-like Function-like FinSequence-like set holds
   b1,b2 are_fiberwise_equipotent
iff
   b1 ^ b3,b2 ^ b3 are_fiberwise_equipotent;

:: RFINSEQ:th 15
theorem
for b1, b2 being Relation-like Function-like FinSequence-like set holds
b1 ^ b2,b2 ^ b1 are_fiberwise_equipotent;

:: RFINSEQ:th 16
theorem
for b1, b2 being Relation-like Function-like FinSequence-like set
      st b1,b2 are_fiberwise_equipotent
   holds len b1 = len b2 & dom b1 = dom b2;

:: RFINSEQ:th 17
theorem
for b1, b2 being Relation-like Function-like FinSequence-like set holds
   b1,b2 are_fiberwise_equipotent
iff
   ex b3 being Function-like quasi_total bijective Relation of dom b2,dom b2 st
      b1 = b3 * b2;

:: RFINSEQ:funcreg 1
registration
  let a1 be Relation-like Function-like set;
  let a2 be finite set;
  cluster a1 | a2 -> Relation-like finite;
end;

:: RFINSEQ:th 18
theorem
for b1 being Relation-like Function-like set
for b2 being finite set holds
   ex b3 being Relation-like Function-like FinSequence-like set st
      b1 | b2,b3 are_fiberwise_equipotent;

:: RFINSEQ:funcnot 1 => RFINSEQ:func 1
definition
  let a1 be Relation-like Function-like FinSequence-like set;
  let a2 be natural set;
  func A1 /^ A2 -> Relation-like Function-like FinSequence-like set means
    len it = (len a1) - a2 &
     (for b1 being natural set
           st b1 in dom it
        holds it . b1 = a1 . (b1 + a2))
    if a2 <= len a1
    otherwise it = {};
end;

:: RFINSEQ:def 2
theorem
for b1 being Relation-like Function-like FinSequence-like set
for b2 being natural set
for b3 being Relation-like Function-like FinSequence-like set holds
   (b2 <= len b1 implies    (b3 = b1 /^ b2
    iff
       len b3 = (len b1) - b2 &
        (for b4 being natural set
              st b4 in dom b3
           holds b3 . b4 = b1 . (b4 + b2)))) &
    (b2 <= len b1 or    (b3 = b1 /^ b2
    iff
       b3 = {}));

:: RFINSEQ:funcnot 2 => RFINSEQ:func 2
definition
  let a1 be set;
  let a2 be FinSequence of a1;
  let a3 be natural set;
  redefine func a2 /^ a3 -> FinSequence of a1;
end;

:: RFINSEQ:th 19
theorem
for b1 being non empty set
for b2 being FinSequence of b1
for b3, b4 being natural set
      st b3 in dom b2 & b4 in Seg b3
   holds (b2 | b3) . b4 = b2 . b4 & b4 in dom b2;

:: RFINSEQ:th 20
theorem
for b1 being non empty set
for b2 being FinSequence of b1
for b3 being natural set
for b4 being set
      st len b2 = b3 + 1 & b4 = b2 . (b3 + 1)
   holds b2 = (b2 | b3) ^ <*b4*>;

:: RFINSEQ:th 21
theorem
for b1 being non empty set
for b2 being FinSequence of b1
for b3 being natural set holds
   (b2 | b3) ^ (b2 /^ b3) = b2;

:: RFINSEQ:th 22
theorem
for b1, b2 being FinSequence of REAL
      st b1,b2 are_fiberwise_equipotent
   holds Sum b1 = Sum b2;

:: RFINSEQ:funcnot 3 => RFINSEQ:func 3
definition
  let a1 be FinSequence of REAL;
  func MIM A1 -> FinSequence of REAL means
    len it = len a1 &
     it . len it = a1 . len a1 &
     (for b1 being natural set
           st 1 <= b1 & b1 <= (len it) - 1
        holds it . b1 = (a1 . b1) - (a1 . (b1 + 1)));
end;

:: RFINSEQ:def 3
theorem
for b1, b2 being FinSequence of REAL holds
   b2 = MIM b1
iff
   len b2 = len b1 &
    b2 . len b2 = b1 . len b1 &
    (for b3 being natural set
          st 1 <= b3 & b3 <= (len b2) - 1
       holds b2 . b3 = (b1 . b3) - (b1 . (b3 + 1)));

:: RFINSEQ:th 23
theorem
for b1 being FinSequence of REAL
for b2 being Element of REAL
for b3 being Element of NAT
      st len b1 = b3 + 2 & b1 . (b3 + 1) = b2
   holds MIM (b1 | (b3 + 1)) = ((MIM b1) | b3) ^ <*b2*>;

:: RFINSEQ:th 24
theorem
for b1 being FinSequence of REAL
for b2, b3 being Element of REAL
for b4 being Element of NAT
      st len b1 = b4 + 2 & b1 . (b4 + 1) = b2 & b1 . (b4 + 2) = b3
   holds MIM b1 = ((MIM b1) | b4) ^ <*b2 - b3,b3*>;

:: RFINSEQ:th 25
theorem
MIM <*> REAL = <*> REAL;

:: RFINSEQ:th 26
theorem
for b1 being Element of REAL holds
   MIM <*b1*> = <*b1*>;

:: RFINSEQ:th 27
theorem
for b1, b2 being Element of REAL holds
MIM <*b1,b2*> = <*b1 - b2,b2*>;

:: RFINSEQ:th 28
theorem
for b1 being FinSequence of REAL
for b2 being Element of NAT holds
   (MIM b1) /^ b2 = MIM (b1 /^ b2);

:: RFINSEQ:th 29
theorem
for b1 being FinSequence of REAL
      st len b1 <> 0
   holds Sum MIM b1 = b1 . 1;

:: RFINSEQ:th 30
theorem
for b1 being FinSequence of REAL
for b2 being Element of NAT
      st 1 <= b2 & b2 < len b1
   holds Sum MIM (b1 /^ b2) = b1 . (b2 + 1);

:: RFINSEQ:attrnot 1 => SEQM_3:attr 4
definition
  let a1 be Function-like Relation of NAT,REAL;
  attr a1 is non-increasing means
    for b1 being Element of NAT
          st b1 in dom a1 & b1 + 1 in dom a1
       holds a1 . (b1 + 1) <= a1 . b1;
end;

:: RFINSEQ:dfs 4
definiens
  let a1 be FinSequence of REAL;
To prove
     a1 is non-increasing
it is sufficient to prove
  thus for b1 being Element of NAT
          st b1 in dom a1 & b1 + 1 in dom a1
       holds a1 . (b1 + 1) <= a1 . b1;

:: RFINSEQ:def 4
theorem
for b1 being FinSequence of REAL holds
      b1 is non-increasing
   iff
      for b2 being Element of NAT
            st b2 in dom b1 & b2 + 1 in dom b1
         holds b1 . (b2 + 1) <= b1 . b2;

:: RFINSEQ:exreg 1
registration
  cluster Relation-like Function-like complex-valued ext-real-valued real-valued non-increasing finite FinSequence-like FinSequence of REAL;
end;

:: RFINSEQ:th 31
theorem
for b1 being FinSequence of REAL
      st (len b1 = 0 or len b1 = 1)
   holds b1 is non-increasing;

:: RFINSEQ:th 32
theorem
for b1 being FinSequence of REAL holds
      b1 is non-increasing
   iff
      for b2, b3 being Element of NAT
            st b2 in dom b1 & b3 in dom b1 & b2 < b3
         holds b1 . b3 <= b1 . b2;

:: RFINSEQ:th 33
theorem
for b1 being non-increasing FinSequence of REAL
for b2 being Element of NAT holds
   b1 | b2 is non-increasing FinSequence of REAL;

:: RFINSEQ:th 34
theorem
for b1 being non-increasing FinSequence of REAL
for b2 being Element of NAT holds
   b1 /^ b2 is non-increasing FinSequence of REAL;

:: RFINSEQ:th 35
theorem
for b1 being FinSequence of REAL holds
   ex b2 being non-increasing FinSequence of REAL st
      b1,b2 are_fiberwise_equipotent;

:: RFINSEQ:th 36
theorem
for b1, b2 being non-increasing FinSequence of REAL
      st b1,b2 are_fiberwise_equipotent
   holds b1 = b2;

:: RFINSEQ:th 37
theorem
for b1 being FinSequence of REAL
for b2, b3 being Element of REAL
      st b2 <> 0
   holds b1 " {b3 / b2} = (b2 * b1) " {b3};

:: RFINSEQ:th 38
theorem
for b1 being FinSequence of REAL holds
   (0 * b1) " {0} = dom b1;

:: RFINSEQ:th 39
theorem
for b1, b2 being Relation-like Function-like set
      st proj2 b1 = proj2 b2 & b1 is one-to-one & b2 is one-to-one
   holds b1,b2 are_fiberwise_equipotent;

:: RFINSEQ:th 40
theorem
for b1 being non empty set
for b2 being FinSequence of b1 holds
   b2 /^ len b2 = {};

:: RFINSEQ:th 41
theorem
for b1, b2 being Relation-like Function-like set
for b3, b4 being set
      st b1 . b3 = b2 . b4 &
         b1 . b4 = b2 . b3 &
         b3 in proj1 b1 &
         b4 in proj1 b1 &
         proj1 b1 = proj1 b2 &
         (for b5 being set
               st b5 <> b3 & b5 <> b4 & b5 in proj1 b1
            holds b1 . b5 = b2 . b5)
   holds b1,b2 are_fiberwise_equipotent;