Article NECKLA_2, MML version 4.99.1005

:: NECKLA_2:th 1
theorem
for b1 being non empty universal set
for b2, b3 being set
   st b2 in b1 & b3 in b1
for b4 being Relation of b2,b3 holds
   b4 in b1;

:: NECKLA_2:th 2
theorem
the InternalRel of Necklace 4 = {[0,1],[1,0],[1,2],[2,1],[2,3],[3,2]};

:: NECKLA_2:condreg 1
registration
  let a1 be natural set;
  cluster -> finite (Element of Rank a1);
end;

:: NECKLA_2:th 3
theorem
for b1 being set
      st b1 in FinSETS
   holds b1 is finite;

:: NECKLA_2:condreg 2
registration
  cluster -> finite (Element of FinSETS);
end;

:: NECKLA_2:condreg 3
registration
  cluster ordinal finite -> natural (set);
end;

:: NECKLA_2:attrnot 1 => NECKLA_2:attr 1
definition
  let a1 be non empty RelStr;
  attr a1 is N-free means
    not a1 embeds Necklace 4;
end;

:: NECKLA_2:dfs 1
definiens
  let a1 be non empty RelStr;
To prove
     a1 is N-free
it is sufficient to prove
  thus not a1 embeds Necklace 4;

:: NECKLA_2:def 1
theorem
for b1 being non empty RelStr holds
      b1 is N-free
   iff
      not b1 embeds Necklace 4;

:: NECKLA_2:exreg 1
registration
  cluster non empty finite strict N-free RelStr;
end;

:: NECKLA_2:funcnot 1 => NECKLA_2:func 1
definition
  let a1, a2 be RelStr;
  func union_of(A1,A2) -> strict RelStr means
    the carrier of it = (the carrier of a1) \/ the carrier of a2 &
     the InternalRel of it = (the InternalRel of a1) \/ the InternalRel of a2;
end;

:: NECKLA_2:def 2
theorem
for b1, b2 being RelStr
for b3 being strict RelStr holds
      b3 = union_of(b1,b2)
   iff
      the carrier of b3 = (the carrier of b1) \/ the carrier of b2 &
       the InternalRel of b3 = (the InternalRel of b1) \/ the InternalRel of b2;

:: NECKLA_2:funcnot 2 => NECKLA_2:func 2
definition
  let a1, a2 be RelStr;
  func sum_of(A1,A2) -> strict RelStr means
    the carrier of it = (the carrier of a1) \/ the carrier of a2 &
     the InternalRel of it = (((the InternalRel of a1) \/ the InternalRel of a2) \/ [:the carrier of a1,the carrier of a2:]) \/ [:the carrier of a2,the carrier of a1:];
end;

:: NECKLA_2:def 3
theorem
for b1, b2 being RelStr
for b3 being strict RelStr holds
      b3 = sum_of(b1,b2)
   iff
      the carrier of b3 = (the carrier of b1) \/ the carrier of b2 &
       the InternalRel of b3 = (((the InternalRel of b1) \/ the InternalRel of b2) \/ [:the carrier of b1,the carrier of b2:]) \/ [:the carrier of b2,the carrier of b1:];

:: NECKLA_2:funcnot 3 => NECKLA_2:func 3
definition
  func fin_RelStr -> set means
    for b1 being set holds
          b1 in it
       iff
          ex b2 being strict RelStr st
             b1 = b2 & the carrier of b2 in FinSETS;
end;

:: NECKLA_2:def 4
theorem
for b1 being set holds
      b1 = fin_RelStr
   iff
      for b2 being set holds
            b2 in b1
         iff
            ex b3 being strict RelStr st
               b2 = b3 & the carrier of b3 in FinSETS;

:: NECKLA_2:funcreg 1
registration
  cluster fin_RelStr -> non empty;
end;

:: NECKLA_2:funcnot 4 => NECKLA_2:func 4
definition
  func fin_RelStr_sp -> Element of bool fin_RelStr means
    (for b1 being strict RelStr
           st the carrier of b1 is not empty & the carrier of b1 is trivial & the carrier of b1 in FinSETS
        holds b1 in it) &
     (for b1, b2 being strict RelStr
           st the carrier of b1 misses the carrier of b2 & b1 in it & b2 in it
        holds union_of(b1,b2) in it & sum_of(b1,b2) in it) &
     (for b1 being Element of bool fin_RelStr
           st (for b2 being strict RelStr
                    st the carrier of b2 is not empty & the carrier of b2 is trivial & the carrier of b2 in FinSETS
                 holds b2 in b1) &
              (for b2, b3 being strict RelStr
                    st the carrier of b2 misses the carrier of b3 & b2 in b1 & b3 in b1
                 holds union_of(b2,b3) in b1 & sum_of(b2,b3) in b1)
        holds it c= b1);
end;

:: NECKLA_2:def 5
theorem
for b1 being Element of bool fin_RelStr holds
      b1 = fin_RelStr_sp
   iff
      (for b2 being strict RelStr
             st the carrier of b2 is not empty & the carrier of b2 is trivial & the carrier of b2 in FinSETS
          holds b2 in b1) &
       (for b2, b3 being strict RelStr
             st the carrier of b2 misses the carrier of b3 & b2 in b1 & b3 in b1
          holds union_of(b2,b3) in b1 & sum_of(b2,b3) in b1) &
       (for b2 being Element of bool fin_RelStr
             st (for b3 being strict RelStr
                      st the carrier of b3 is not empty & the carrier of b3 is trivial & the carrier of b3 in FinSETS
                   holds b3 in b2) &
                (for b3, b4 being strict RelStr
                      st the carrier of b3 misses the carrier of b4 & b3 in b2 & b4 in b2
                   holds union_of(b3,b4) in b2 & sum_of(b3,b4) in b2)
          holds b1 c= b2);

:: NECKLA_2:funcreg 2
registration
  cluster fin_RelStr_sp -> non empty;
end;

:: NECKLA_2:th 4
theorem
for b1 being set
      st b1 in fin_RelStr_sp
   holds b1 is non empty finite strict RelStr;

:: NECKLA_2:th 5
theorem
for b1 being RelStr
      st b1 in fin_RelStr_sp
   holds the carrier of b1 in FinSETS;

:: NECKLA_2:th 6
theorem
for b1 being set
      st b1 in fin_RelStr_sp & b1 is not non empty trivial strict RelStr
   holds ex b2, b3 being strict RelStr st
      the carrier of b2 misses the carrier of b3 & b2 in fin_RelStr_sp & b3 in fin_RelStr_sp & (b1 = union_of(b2,b3) or b1 = sum_of(b2,b3));

:: NECKLA_2:th 7
theorem
for b1 being non empty strict RelStr
      st b1 in fin_RelStr_sp
   holds b1 is N-free;