Article HALLMAR1, MML version 4.99.1005

:: HALLMAR1:th 1
theorem
for b1, b2 being finite set holds
(card (b1 \/ b2)) + card (b1 /\ b2) = (card b1) + card b2;

:: HALLMAR1:sch 1
scheme HALLMAR1:sch 1
{F1 -> Element of NAT}:
for b1 being Element of NAT
      st 1 <= b1 & b1 <= F1()
   holds P1[b1]
provided
   P1[F1()] & 2 <= F1()
and
   for b1 being Element of NAT
         st 1 <= b1 & b1 < F1() & P1[b1 + 1]
      holds P1[b1];


:: HALLMAR1:sch 2
scheme HALLMAR1:sch 2
P1[1]
provided
   ex b1 being Element of NAT st
      1 < b1 & P1[b1]
and
   for b1 being Element of NAT
         st 1 <= b1 & P1[b1 + 1]
      holds P1[b1];


:: HALLMAR1:exreg 1
registration
  let a1 be non empty set;
  cluster Relation-like non-empty Function-like non empty finite FinSequence-like FinSequence of bool a1;
end;

:: HALLMAR1:th 2
theorem
for b1 being non empty set
for b2 being non-empty FinSequence of bool b1
for b3 being Element of NAT
      st b3 in dom b2
   holds b2 . b3 <> {};

:: HALLMAR1:funcreg 1
registration
  let a1 be finite set;
  let a2 be FinSequence of bool a1;
  let a3 be Element of NAT;
  cluster a2 . a3 -> finite;
end;

:: HALLMAR1:funcnot 1 => HALLMAR1:func 1
definition
  let a1 be set;
  let a2 be FinSequence of bool a1;
  let a3 be set;
  func union(A2,A3) -> set means
    for b1 being set holds
          b1 in it
       iff
          ex b2 being set st
             b2 in a3 & b2 in dom a2 & b1 in a2 . b2;
end;

:: HALLMAR1:def 1
theorem
for b1 being set
for b2 being FinSequence of bool b1
for b3, b4 being set holds
   b4 = union(b2,b3)
iff
   for b5 being set holds
         b5 in b4
      iff
         ex b6 being set st
            b6 in b3 & b6 in dom b2 & b5 in b2 . b6;

:: HALLMAR1:th 3
theorem
for b1 being set
for b2 being FinSequence of bool b1
for b3 being set holds
   union(b2,b3) c= b1;

:: HALLMAR1:th 4
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3, b4 being set
      st b3 c= b4
   holds union(b2,b3) c= union(b2,b4);

:: HALLMAR1:funcreg 2
registration
  let a1 be finite set;
  let a2 be FinSequence of bool a1;
  let a3 be set;
  cluster union(a2,a3) -> finite;
end;

:: HALLMAR1:th 5
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
      st b3 in dom b2
   holds union(b2,{b3}) = b2 . b3;

:: HALLMAR1:th 6
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3, b4 being Element of NAT
      st b3 in dom b2 & b4 in dom b2
   holds union(b2,{b3,b4}) = (b2 . b3) \/ (b2 . b4);

:: HALLMAR1:th 7
theorem
for b1 being set
for b2 being finite set
for b3 being FinSequence of bool b2
for b4 being Element of NAT
      st b4 in b1 & b4 in dom b3
   holds b3 . b4 c= union(b3,b1);

:: HALLMAR1:th 8
theorem
for b1 being set
for b2 being finite set
for b3 being Element of NAT
for b4 being FinSequence of bool b2
      st b3 in b1 & b3 in dom b4
   holds union(b4,b1) = (union(b4,b1 \ {b3})) \/ (b4 . b3);

:: HALLMAR1:th 9
theorem
for b1, b2 being set
for b3 being finite set
for b4 being Element of NAT
for b5 being FinSequence of bool b3
      st b4 in dom b5
   holds union(b5,({b4} \/ b1) \/ b2) = (b5 . b4) \/ union(b5,b1 \/ b2);

:: HALLMAR1:th 10
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4, b5 being set
      st b4 <> b5 & b4 in b2 . b3 & b5 in b2 . b3
   holds ((b2 . b3) \ {b4}) \/ ((b2 . b3) \ {b5}) = b2 . b3;

:: HALLMAR1:funcnot 2 => HALLMAR1:func 2
definition
  let a1 be finite set;
  let a2 be FinSequence of bool a1;
  let a3 be Element of NAT;
  let a4 be set;
  func Cut(A2,A3,A4) -> FinSequence of bool a1 means
    dom it = dom a2 &
     (for b1 being Element of NAT
           st b1 in dom it
        holds (a3 = b1 implies it . b1 = (a2 . b1) \ {a4}) &
         (a3 = b1 or it . b1 = a2 . b1));
end;

:: HALLMAR1:def 2
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4 being set
for b5 being FinSequence of bool b1 holds
      b5 = Cut(b2,b3,b4)
   iff
      dom b5 = dom b2 &
       (for b6 being Element of NAT
             st b6 in dom b5
          holds (b3 = b6 implies b5 . b6 = (b2 . b6) \ {b4}) &
           (b3 = b6 or b5 . b6 = b2 . b6));

:: HALLMAR1:th 11
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4 being set
      st b3 in dom b2 & b4 in b2 . b3
   holds card ((Cut(b2,b3,b4)) . b3) = (card (b2 . b3)) - 1;

:: HALLMAR1:th 12
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4, b5 being set holds
union(Cut(b2,b3,b4),b5 \ {b3}) = union(b2,b5 \ {b3});

:: HALLMAR1:th 13
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4, b5 being set
      st not b3 in b5
   holds union(b2,b5) = union(Cut(b2,b3,b4),b5);

:: HALLMAR1:th 14
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4, b5 being set
      st b3 in dom Cut(b2,b3,b4) & b5 c= dom Cut(b2,b3,b4) & b3 in b5
   holds union(Cut(b2,b3,b4),b5) = (union(b2,b5 \ {b3})) \/ ((b2 . b3) \ {b4});

:: HALLMAR1:prednot 1 => HALLMAR1:pred 1
definition
  let a1 be finite set;
  let a2 be FinSequence of bool a1;
  let a3 be set;
  pred A3 is_a_system_of_different_representatives_of A2 means
    ex b1 being FinSequence of a1 st
       b1 = a3 &
        dom a2 = dom b1 &
        (for b2 being Element of NAT
              st b2 in dom b1
           holds b1 . b2 in a2 . b2) &
        b1 is one-to-one;
end;

:: HALLMAR1:dfs 3
definiens
  let a1 be finite set;
  let a2 be FinSequence of bool a1;
  let a3 be set;
To prove
     a3 is_a_system_of_different_representatives_of a2
it is sufficient to prove
  thus ex b1 being FinSequence of a1 st
       b1 = a3 &
        dom a2 = dom b1 &
        (for b2 being Element of NAT
              st b2 in dom b1
           holds b1 . b2 in a2 . b2) &
        b1 is one-to-one;

:: HALLMAR1:def 3
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being set holds
      b3 is_a_system_of_different_representatives_of b2
   iff
      ex b4 being FinSequence of b1 st
         b4 = b3 &
          dom b2 = dom b4 &
          (for b5 being Element of NAT
                st b5 in dom b4
             holds b4 . b5 in b2 . b5) &
          b4 is one-to-one;

:: HALLMAR1:attrnot 1 => HALLMAR1:attr 1
definition
  let a1 be finite set;
  let a2 be FinSequence of bool a1;
  attr a2 is Hall means
    for b1 being finite set
          st b1 c= dom a2
       holds card b1 <= card union(a2,b1);
end;

:: HALLMAR1:dfs 4
definiens
  let a1 be finite set;
  let a2 be FinSequence of bool a1;
To prove
     a2 is Hall
it is sufficient to prove
  thus for b1 being finite set
          st b1 c= dom a2
       holds card b1 <= card union(a2,b1);

:: HALLMAR1:def 4
theorem
for b1 being finite set
for b2 being FinSequence of bool b1 holds
      b2 is Hall(b1)
   iff
      for b3 being finite set
            st b3 c= dom b2
         holds card b3 <= card union(b2,b3);

:: HALLMAR1:th 15
theorem
for b1 being finite set
for b2 being non empty FinSequence of bool b1
      st b2 is Hall(b1)
   holds b2 is non-empty;

:: HALLMAR1:th 16
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
      st b3 in dom b2 & b2 is Hall(b1)
   holds 1 <= card (b2 . b3);

:: HALLMAR1:th 17
theorem
for b1 being non empty finite set
for b2 being non empty FinSequence of bool b1
      st (for b3 being Element of NAT
               st b3 in dom b2
            holds card (b2 . b3) = 1) &
         b2 is Hall(b1)
   holds ex b3 being set st
      b3 is_a_system_of_different_representatives_of b2;

:: HALLMAR1:th 18
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
      st ex b3 being set st
           b3 is_a_system_of_different_representatives_of b2
   holds b2 is Hall(b1);

:: HALLMAR1:modenot 1 => HALLMAR1:mode 1
definition
  let a1 be set;
  let a2 be FinSequence of bool a1;
  let a3 be Element of NAT;
  mode Reduction of A2,A3 -> FinSequence of bool a1 means
    dom it = dom a2 &
     (for b1 being Element of NAT
           st b1 in dom a2 & b1 <> a3
        holds a2 . b1 = it . b1) &
     it . a3 c= a2 . a3;
end;

:: HALLMAR1:dfs 5
definiens
  let a1 be set;
  let a2 be FinSequence of bool a1;
  let a3 be Element of NAT;
  let a4 be FinSequence of bool a1;
To prove
     a4 is Reduction of a2,a3
it is sufficient to prove
  thus dom a4 = dom a2 &
     (for b1 being Element of NAT
           st b1 in dom a2 & b1 <> a3
        holds a2 . b1 = a4 . b1) &
     a4 . a3 c= a2 . a3;

:: HALLMAR1:def 5
theorem
for b1 being set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4 being FinSequence of bool b1 holds
      b4 is Reduction of b2,b3
   iff
      dom b4 = dom b2 &
       (for b5 being Element of NAT
             st b5 in dom b2 & b5 <> b3
          holds b2 . b5 = b4 . b5) &
       b4 . b3 c= b2 . b3;

:: HALLMAR1:modenot 2 => HALLMAR1:mode 2
definition
  let a1 be set;
  let a2 be FinSequence of bool a1;
  mode Reduction of A2 -> FinSequence of bool a1 means
    dom it = dom a2 &
     (for b1 being Element of NAT
           st b1 in dom a2
        holds it . b1 c= a2 . b1);
end;

:: HALLMAR1:dfs 6
definiens
  let a1 be set;
  let a2, a3 be FinSequence of bool a1;
To prove
     a3 is Reduction of a2
it is sufficient to prove
  thus dom a3 = dom a2 &
     (for b1 being Element of NAT
           st b1 in dom a2
        holds a3 . b1 c= a2 . b1);

:: HALLMAR1:def 6
theorem
for b1 being set
for b2, b3 being FinSequence of bool b1 holds
   b3 is Reduction of b2
iff
   dom b3 = dom b2 &
    (for b4 being Element of NAT
          st b4 in dom b2
       holds b3 . b4 c= b2 . b4);

:: HALLMAR1:modenot 3 => HALLMAR1:mode 3
definition
  let a1 be set;
  let a2 be FinSequence of bool a1;
  let a3 be Element of NAT;
  assume a3 in dom a2 & a2 . a3 <> {};
  mode Singlification of A2,A3 -> Reduction of a2 means
    Card (it . a3) = 1;
end;

:: HALLMAR1:dfs 7
definiens
  let a1 be set;
  let a2 be FinSequence of bool a1;
  let a3 be Element of NAT;
  let a4 be Reduction of a2;
To prove
     a4 is Singlification of a2,a3
it is sufficient to prove
thus a3 in dom a2 & a2 . a3 <> {};
  thus Card (a4 . a3) = 1;

:: HALLMAR1:def 7
theorem
for b1 being set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
   st b3 in dom b2 & b2 . b3 <> {}
for b4 being Reduction of b2 holds
      b4 is Singlification of b2,b3
   iff
      Card (b4 . b3) = 1;

:: HALLMAR1:th 19
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4 being Reduction of b2,b3 holds
   b4 is Reduction of b2;

:: HALLMAR1:th 20
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4 being set
      st b3 in dom b2 & b4 in b2 . b3
   holds Cut(b2,b3,b4) is Reduction of b2,b3;

:: HALLMAR1:th 21
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
for b4 being set
      st b3 in dom b2 & b4 in b2 . b3
   holds Cut(b2,b3,b4) is Reduction of b2;

:: HALLMAR1:th 22
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Reduction of b2
for b4 being Reduction of b3 holds
   b4 is Reduction of b2;

:: HALLMAR1:th 23
theorem
for b1 being non empty finite set
for b2 being non-empty FinSequence of bool b1
for b3 being Element of NAT
for b4 being Singlification of b2,b3
      st b3 in dom b2
   holds b4 . b3 <> {};

:: HALLMAR1:th 24
theorem
for b1 being non empty finite set
for b2 being non-empty FinSequence of bool b1
for b3, b4 being Element of NAT
for b5 being Singlification of b2,b3
for b6 being Singlification of b5,b4
      st b3 in dom b2 & b4 in dom b2 & b6 . b3 <> {} & b5 . b4 <> {}
   holds b6 is Singlification of b2,b4 & b6 is Singlification of b2,b3;

:: HALLMAR1:th 25
theorem
for b1 being set
for b2 being FinSequence of bool b1
for b3 being Element of NAT holds
   b2 is Reduction of b2,b3;

:: HALLMAR1:th 26
theorem
for b1 being set
for b2 being FinSequence of bool b1 holds
   b2 is Reduction of b2;

:: HALLMAR1:modenot 4 => HALLMAR1:mode 4
definition
  let a1 be non empty set;
  let a2 be FinSequence of bool a1;
  assume a2 is non-empty;
  mode Singlification of A2 -> Reduction of a2 means
    for b1 being Element of NAT
          st b1 in dom a2
       holds Card (it . b1) = 1;
end;

:: HALLMAR1:dfs 8
definiens
  let a1 be non empty set;
  let a2 be FinSequence of bool a1;
  let a3 be Reduction of a2;
To prove
     a3 is Singlification of a2
it is sufficient to prove
thus a2 is non-empty;
  thus for b1 being Element of NAT
          st b1 in dom a2
       holds Card (a3 . b1) = 1;

:: HALLMAR1:def 8
theorem
for b1 being non empty set
for b2 being FinSequence of bool b1
   st b2 is non-empty
for b3 being Reduction of b2 holds
      b3 is Singlification of b2
   iff
      for b4 being Element of NAT
            st b4 in dom b2
         holds Card (b3 . b4) = 1;

:: HALLMAR1:th 27
theorem
for b1 being non empty finite set
for b2 being non-empty non empty FinSequence of bool b1
for b3 being Relation-like Function-like set holds
      b3 is Singlification of b2
   iff
      proj1 b3 = dom b2 &
       (for b4 being Element of NAT
             st b4 in dom b2
          holds b3 is Singlification of b2,b4);

:: HALLMAR1:condreg 1
registration
  let a1 be non empty finite set;
  let a2 be non empty FinSequence of bool a1;
  let a3 be Element of NAT;
  cluster -> non empty (Singlification of a2,a3);
end;

:: HALLMAR1:condreg 2
registration
  let a1 be non empty finite set;
  let a2 be non empty FinSequence of bool a1;
  cluster -> non empty (Singlification of a2);
end;

:: HALLMAR1:th 28
theorem
for b1 being non empty finite set
for b2 being non empty FinSequence of bool b1
for b3 being set
for b4 being Reduction of b2
      st b3 is_a_system_of_different_representatives_of b4
   holds b3 is_a_system_of_different_representatives_of b2;

:: HALLMAR1:th 29
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
   st b2 is Hall(b1)
for b3 being Element of NAT
      st 2 <= card (b2 . b3)
   holds ex b4 being set st
      b4 in b2 . b3 & Cut(b2,b3,b4) is Hall(b1);

:: HALLMAR1:th 30
theorem
for b1 being finite set
for b2 being FinSequence of bool b1
for b3 being Element of NAT
      st b3 in dom b2 & b2 is Hall(b1)
   holds ex b4 being Singlification of b2,b3 st
      b4 is Hall(b1);

:: HALLMAR1:th 31
theorem
for b1 being non empty finite set
for b2 being non empty FinSequence of bool b1
      st b2 is Hall(b1)
   holds ex b3 being Singlification of b2 st
      b3 is Hall(b1);

:: HALLMAR1:th 32
theorem
for b1 being non empty finite set
for b2 being non empty FinSequence of bool b1 holds
      ex b3 being set st
         b3 is_a_system_of_different_representatives_of b2
   iff
      b2 is Hall(b1);