Article CATALG_1, MML version 4.99.1005

:: CATALG_1:funcnot 1 => CATALG_1:func 1
definition
  let a1 be set;
  let a2, a3 be Relation-like Function-like set;
  func A3 -MSF(A1,A2) -> Function-yielding ManySortedSet of a1 means
    for b1 being set
          st b1 in a1
       holds it . b1 = a3 | (a2 . b1);
end;

:: CATALG_1:def 1
theorem
for b1 being set
for b2, b3 being Relation-like Function-like set
for b4 being Function-yielding ManySortedSet of b1 holds
      b4 = b3 -MSF(b1,b2)
   iff
      for b5 being set
            st b5 in b1
         holds b4 . b5 = b3 | (b2 . b5);

:: CATALG_1:th 1
theorem
for b1 being set
for b2 being ManySortedSet of b1 holds
   (id Union b2) -MSF(b1,b2) = id b2;

:: CATALG_1:th 2
theorem
for b1 being set
for b2, b3 being ManySortedSet of b1
for b4, b5 being Relation-like Function-like set
      st rngs (b4 -MSF(b1,b2)) c= b3
   holds (b4 * b5) -MSF(b1,b2) = (b5 -MSF(b1,b3)) ** (b4 -MSF(b1,b2));

:: CATALG_1:th 3
theorem
for b1 being Relation-like Function-like set
for b2 being set
for b3, b4 being ManySortedSet of b2
      st for b5 being set
              st b5 in b2
           holds b3 . b5 c= proj1 b1 & b1 .: (b3 . b5) c= b4 . b5
   holds b1 -MSF(b2,b3) is ManySortedFunction of b3,b4;

:: CATALG_1:th 4
theorem
for b1 being set
for b2 being Element of NAT
for b3 being Relation-like Function-like FinSequence-like set holds
      b3 in b2 -tuples_on b1
   iff
      len b3 = b2 & proj2 b3 c= b1;

:: CATALG_1:th 5
theorem
for b1 being set
for b2 being Element of NAT
for b3 being FinSequence of b1 holds
      b3 in b2 -tuples_on b1
   iff
      len b3 = b2;

:: CATALG_1:th 6
theorem
for b1 being set
for b2 being Element of NAT holds
   b2 -tuples_on b1 c= b1 *;

:: CATALG_1:th 7
theorem
for b1 being set
for b2 being Element of NAT holds
      b2 <> 0 & b1 = {}
   iff
      b2 -tuples_on b1 = {};

:: CATALG_1:th 8
theorem
for b1, b2 being set holds
   b2 in 1 -tuples_on b1
iff
   ex b3 being set st
      b3 in b1 & b2 = <*b3*>;

:: CATALG_1:th 9
theorem
for b1, b2 being set
      st <*b2*> in 1 -tuples_on b1
   holds b2 in b1;

:: CATALG_1:th 10
theorem
for b1, b2 being set holds
   b2 in 2 -tuples_on b1
iff
   ex b3, b4 being set st
      b3 in b1 & b4 in b1 & b2 = <*b3,b4*>;

:: CATALG_1:th 11
theorem
for b1, b2, b3 being set
      st <*b2,b3*> in 2 -tuples_on b1
   holds b2 in b1 & b3 in b1;

:: CATALG_1:th 12
theorem
for b1, b2 being set holds
   b2 in 3 -tuples_on b1
iff
   ex b3, b4, b5 being set st
      b3 in b1 & b4 in b1 & b5 in b1 & b2 = <*b3,b4,b5*>;

:: CATALG_1:th 13
theorem
for b1, b2, b3, b4 being set
      st <*b2,b3,b4*> in 3 -tuples_on b1
   holds b2 in b1 & b3 in b1 & b4 in b1;

:: CATALG_1:attrnot 1 => CATALG_1:attr 1
definition
  let a1 be non empty ManySortedSign;
  let a2 be MSAlgebra over a1;
  attr a2 is empty means
    the Sorts of a2 is empty-yielding;
end;

:: CATALG_1:dfs 2
definiens
  let a1 be non empty ManySortedSign;
  let a2 be MSAlgebra over a1;
To prove
     a2 is empty
it is sufficient to prove
  thus the Sorts of a2 is empty-yielding;

:: CATALG_1:def 3
theorem
for b1 being non empty ManySortedSign
for b2 being MSAlgebra over b1 holds
      b2 is empty(b1)
   iff
      the Sorts of b2 is empty-yielding;

:: CATALG_1:condreg 1
registration
  let a1 be non empty ManySortedSign;
  cluster non-empty -> non empty (MSAlgebra over a1);
end;

:: CATALG_1:funcreg 1
registration
  let a1 be non empty non void ManySortedSign;
  let a2 be non-empty ManySortedSet of the carrier of a1;
  cluster FreeMSA a2 -> disjoint_valued;
end;

:: CATALG_1:exreg 1
registration
  let a1 be non empty non void ManySortedSign;
  cluster strict non-empty disjoint_valued MSAlgebra over a1;
end;

:: CATALG_1:funcreg 2
registration
  let a1 be non empty non void ManySortedSign;
  let a2 be non empty MSAlgebra over a1;
  cluster the Sorts of a2 -> non empty-yielding;
end;

:: CATALG_1:exreg 2
registration
  cluster Relation-like non empty-yielding Function-like set;
end;

:: CATALG_1:funcnot 2 => CATALG_1:func 2
definition
  let a1 be set;
  func CatSign A1 -> strict ManySortedSign means
    the carrier of it = [:{0},2 -tuples_on a1:] &
     the OperSymbols of it = [:{1},1 -tuples_on a1:] \/ [:{2},3 -tuples_on a1:] &
     (for b1 being set
           st b1 in a1
        holds (the Arity of it) . [1,<*b1*>] = {} &
         (the ResultSort of it) . [1,<*b1*>] = [0,<*b1,b1*>]) &
     (for b1, b2, b3 being set
           st b1 in a1 & b2 in a1 & b3 in a1
        holds (the Arity of it) . [2,<*b1,b2,b3*>] = <*[0,<*b2,b3*>],[0,<*b1,b2*>]*> &
         (the ResultSort of it) . [2,<*b1,b2,b3*>] = [0,<*b1,b3*>]);
end;

:: CATALG_1:def 5
theorem
for b1 being set
for b2 being strict ManySortedSign holds
      b2 = CatSign b1
   iff
      the carrier of b2 = [:{0},2 -tuples_on b1:] &
       the OperSymbols of b2 = [:{1},1 -tuples_on b1:] \/ [:{2},3 -tuples_on b1:] &
       (for b3 being set
             st b3 in b1
          holds (the Arity of b2) . [1,<*b3*>] = {} &
           (the ResultSort of b2) . [1,<*b3*>] = [0,<*b3,b3*>]) &
       (for b3, b4, b5 being set
             st b3 in b1 & b4 in b1 & b5 in b1
          holds (the Arity of b2) . [2,<*b3,b4,b5*>] = <*[0,<*b4,b5*>],[0,<*b3,b4*>]*> &
           (the ResultSort of b2) . [2,<*b3,b4,b5*>] = [0,<*b3,b5*>]);

:: CATALG_1:funcreg 3
registration
  let a1 be set;
  cluster CatSign a1 -> strict feasible;
end;

:: CATALG_1:funcreg 4
registration
  let a1 be non empty set;
  cluster CatSign a1 -> non empty strict non void;
end;

:: CATALG_1:modenot 1
definition
  mode Signature is feasible ManySortedSign;
end;

:: CATALG_1:attrnot 2 => CATALG_1:attr 2
definition
  let a1 be feasible ManySortedSign;
  attr a1 is Categorial means
    ex b1 being set st
       CatSign b1 is Subsignature of a1 &
        the carrier of a1 = [:{0},2 -tuples_on b1:];
end;

:: CATALG_1:dfs 4
definiens
  let a1 be feasible ManySortedSign;
To prove
     a1 is Categorial
it is sufficient to prove
  thus ex b1 being set st
       CatSign b1 is Subsignature of a1 &
        the carrier of a1 = [:{0},2 -tuples_on b1:];

:: CATALG_1:def 6
theorem
for b1 being feasible ManySortedSign holds
      b1 is Categorial
   iff
      ex b2 being set st
         CatSign b2 is Subsignature of b1 &
          the carrier of b1 = [:{0},2 -tuples_on b2:];

:: CATALG_1:condreg 2
registration
  cluster non empty feasible Categorial -> non void (ManySortedSign);
end;

:: CATALG_1:exreg 3
registration
  cluster non empty strict feasible Categorial ManySortedSign;
end;

:: CATALG_1:modenot 2
definition
  mode CatSignature is feasible Categorial ManySortedSign;
end;

:: CATALG_1:modenot 3 => CATALG_1:mode 1
definition
  let a1 be set;
  mode CatSignature of A1 -> feasible ManySortedSign means
    CatSign a1 is Subsignature of it &
     the carrier of it = [:{0},2 -tuples_on a1:];
end;

:: CATALG_1:dfs 5
definiens
  let a1 be set;
  let a2 be feasible ManySortedSign;
To prove
     a2 is CatSignature of a1
it is sufficient to prove
  thus CatSign a1 is Subsignature of a2 &
     the carrier of a2 = [:{0},2 -tuples_on a1:];

:: CATALG_1:def 7
theorem
for b1 being set
for b2 being feasible ManySortedSign holds
      b2 is CatSignature of b1
   iff
      CatSign b1 is Subsignature of b2 &
       the carrier of b2 = [:{0},2 -tuples_on b1:];

:: CATALG_1:th 14
theorem
for b1, b2 being set
for b3 being CatSignature of b1
      st b3 is CatSignature of b2
   holds b1 = b2;

:: CATALG_1:condreg 3
registration
  let a1 be set;
  cluster -> Categorial (CatSignature of a1);
end;

:: CATALG_1:condreg 4
registration
  let a1 be non empty set;
  cluster -> non empty (CatSignature of a1);
end;

:: CATALG_1:exreg 4
registration
  let a1 be set;
  cluster strict feasible Categorial CatSignature of a1;
end;

:: CATALG_1:funcnot 3 => CATALG_1:func 3
definition
  let a1 be set;
  redefine func CatSign a1 -> strict CatSignature of a1;
end;

:: CATALG_1:funcnot 4 => CATALG_1:func 4
definition
  let a1 be ManySortedSign;
  func underlay A1 -> set means
    for b1 being set holds
          b1 in it
       iff
          ex b2 being set st
             ex b3 being Relation-like Function-like set st
                [b2,b3] in (the carrier of a1) \/ the OperSymbols of a1 &
                 b1 in proj2 b3;
end;

:: CATALG_1:def 8
theorem
for b1 being ManySortedSign
for b2 being set holds
      b2 = underlay b1
   iff
      for b3 being set holds
            b3 in b2
         iff
            ex b4 being set st
               ex b5 being Relation-like Function-like set st
                  [b4,b5] in (the carrier of b1) \/ the OperSymbols of b1 &
                   b3 in proj2 b5;

:: CATALG_1:th 15
theorem
for b1 being set holds
   underlay CatSign b1 = b1;

:: CATALG_1:attrnot 3 => CATALG_1:attr 3
definition
  let a1 be ManySortedSign;
  attr a1 is delta-concrete means
    ex b1 being Function-like quasi_total Relation of NAT,NAT st
       (for b2 being set
              st b2 in the carrier of a1
           holds ex b3 being Element of NAT st
              ex b4 being Relation-like Function-like FinSequence-like set st
                 b2 = [b3,b4] &
                  len b4 = b1 . b3 &
                  [:{b3},(b1 . b3) -tuples_on underlay a1:] c= the carrier of a1) &
        (for b2 being set
              st b2 in the OperSymbols of a1
           holds ex b3 being Element of NAT st
              ex b4 being Relation-like Function-like FinSequence-like set st
                 b2 = [b3,b4] &
                  len b4 = b1 . b3 &
                  [:{b3},(b1 . b3) -tuples_on underlay a1:] c= the OperSymbols of a1);
end;

:: CATALG_1:dfs 7
definiens
  let a1 be ManySortedSign;
To prove
     a1 is delta-concrete
it is sufficient to prove
  thus ex b1 being Function-like quasi_total Relation of NAT,NAT st
       (for b2 being set
              st b2 in the carrier of a1
           holds ex b3 being Element of NAT st
              ex b4 being Relation-like Function-like FinSequence-like set st
                 b2 = [b3,b4] &
                  len b4 = b1 . b3 &
                  [:{b3},(b1 . b3) -tuples_on underlay a1:] c= the carrier of a1) &
        (for b2 being set
              st b2 in the OperSymbols of a1
           holds ex b3 being Element of NAT st
              ex b4 being Relation-like Function-like FinSequence-like set st
                 b2 = [b3,b4] &
                  len b4 = b1 . b3 &
                  [:{b3},(b1 . b3) -tuples_on underlay a1:] c= the OperSymbols of a1);

:: CATALG_1:def 9
theorem
for b1 being ManySortedSign holds
      b1 is delta-concrete
   iff
      ex b2 being Function-like quasi_total Relation of NAT,NAT st
         (for b3 being set
                st b3 in the carrier of b1
             holds ex b4 being Element of NAT st
                ex b5 being Relation-like Function-like FinSequence-like set st
                   b3 = [b4,b5] &
                    len b5 = b2 . b4 &
                    [:{b4},(b2 . b4) -tuples_on underlay b1:] c= the carrier of b1) &
          (for b3 being set
                st b3 in the OperSymbols of b1
             holds ex b4 being Element of NAT st
                ex b5 being Relation-like Function-like FinSequence-like set st
                   b3 = [b4,b5] &
                    len b5 = b2 . b4 &
                    [:{b4},(b2 . b4) -tuples_on underlay b1:] c= the OperSymbols of b1);

:: CATALG_1:funcreg 5
registration
  let a1 be set;
  cluster CatSign a1 -> strict delta-concrete;
end;

:: CATALG_1:exreg 5
registration
  cluster non empty strict feasible Categorial delta-concrete ManySortedSign;
end;

:: CATALG_1:exreg 6
registration
  let a1 be set;
  cluster strict feasible Categorial delta-concrete CatSignature of a1;
end;

:: CATALG_1:th 16
theorem
for b1 being delta-concrete ManySortedSign
for b2 being set
      st (b2 in the carrier of b1 or b2 in the OperSymbols of b1)
   holds ex b3 being Element of NAT st
      ex b4 being Relation-like Function-like FinSequence-like set st
         b2 = [b3,b4] & proj2 b4 c= underlay b1;

:: CATALG_1:th 17
theorem
for b1 being delta-concrete ManySortedSign
for b2 being set
for b3, b4 being Relation-like Function-like FinSequence-like set
      st ([b2,b3] in the carrier of b1 & [b2,b4] in the carrier of b1 or [b2,b3] in the OperSymbols of b1 & [b2,b4] in the OperSymbols of b1)
   holds len b3 = len b4;

:: CATALG_1:th 18
theorem
for b1 being delta-concrete ManySortedSign
for b2 being set
for b3, b4 being Relation-like Function-like FinSequence-like set
      st len b4 = len b3 & proj2 b4 c= underlay b1
   holds ([b2,b3] in the carrier of b1 implies [b2,b4] in the carrier of b1) &
    ([b2,b3] in the OperSymbols of b1 implies [b2,b4] in the OperSymbols of b1);

:: CATALG_1:th 19
theorem
for b1 being non empty feasible Categorial delta-concrete ManySortedSign holds
   b1 is CatSignature of underlay b1;

:: CATALG_1:funcreg 6
registration
  let a1 be non empty feasible Categorial ManySortedSign;
  let a2 be Element of the carrier of a1;
  cluster a2 `2 -> Relation-like Function-like;
end;

:: CATALG_1:funcreg 7
registration
  let a1 be non empty delta-concrete ManySortedSign;
  let a2 be Element of the carrier of a1;
  cluster a2 `2 -> Relation-like Function-like;
end;

:: CATALG_1:funcreg 8
registration
  let a1 be non void delta-concrete ManySortedSign;
  let a2 be Element of the OperSymbols of a1;
  cluster a2 `2 -> Relation-like Function-like;
end;

:: CATALG_1:funcreg 9
registration
  let a1 be non empty feasible Categorial ManySortedSign;
  let a2 be Element of the carrier of a1;
  cluster a2 `2 -> FinSequence-like;
end;

:: CATALG_1:funcreg 10
registration
  let a1 be non empty delta-concrete ManySortedSign;
  let a2 be Element of the carrier of a1;
  cluster a2 `2 -> FinSequence-like;
end;

:: CATALG_1:funcreg 11
registration
  let a1 be non void delta-concrete ManySortedSign;
  let a2 be Element of the OperSymbols of a1;
  cluster a2 `2 -> FinSequence-like;
end;

:: CATALG_1:funcnot 5 => CATALG_1:func 5
definition
  let a1 be set;
  func idsym A1 -> set equals
    [1,<*a1*>];
end;

:: CATALG_1:def 10
theorem
for b1 being set holds
   idsym b1 = [1,<*b1*>];

:: CATALG_1:funcnot 6 => CATALG_1:func 6
definition
  let a1, a2 be set;
  func homsym(A1,A2) -> set equals
    [0,<*a1,a2*>];
end;

:: CATALG_1:def 11
theorem
for b1, b2 being set holds
homsym(b1,b2) = [0,<*b1,b2*>];

:: CATALG_1:funcnot 7 => CATALG_1:func 7
definition
  let a1, a2, a3 be set;
  func compsym(A1,A2,A3) -> set equals
    [2,<*a1,a2,a3*>];
end;

:: CATALG_1:def 12
theorem
for b1, b2, b3 being set holds
compsym(b1,b2,b3) = [2,<*b1,b2,b3*>];

:: CATALG_1:th 20
theorem
for b1 being non empty set
for b2 being CatSignature of b1
for b3 being Element of b1 holds
   idsym b3 in the OperSymbols of b2 &
    (for b4 being Element of b1 holds
       homsym(b3,b4) in the carrier of b2 &
        (for b5 being Element of b1 holds
           compsym(b3,b4,b5) in the OperSymbols of b2));

:: CATALG_1:funcnot 8 => CATALG_1:func 8
definition
  let a1 be non empty set;
  let a2 be Element of a1;
  redefine func idsym a2 -> Element of the OperSymbols of CatSign a1;
end;

:: CATALG_1:funcnot 9 => CATALG_1:func 9
definition
  let a1 be non empty set;
  let a2, a3 be Element of a1;
  redefine func homsym(a2,a3) -> Element of the carrier of CatSign a1;
end;

:: CATALG_1:funcnot 10 => CATALG_1:func 10
definition
  let a1 be non empty set;
  let a2, a3, a4 be Element of a1;
  redefine func compsym(a2,a3,a4) -> Element of the OperSymbols of CatSign a1;
end;

:: CATALG_1:th 21
theorem
for b1, b2 being set
      st idsym b1 = idsym b2
   holds b1 = b2;

:: CATALG_1:th 22
theorem
for b1, b2, b3, b4 being set
      st homsym(b1,b3) = homsym(b2,b4)
   holds b1 = b2 & b3 = b4;

:: CATALG_1:th 23
theorem
for b1, b2, b3, b4, b5, b6 being set
      st compsym(b1,b3,b5) = compsym(b2,b4,b6)
   holds b1 = b2 & b3 = b4 & b5 = b6;

:: CATALG_1:th 24
theorem
for b1 being non empty set
for b2 being CatSignature of b1
for b3 being Element of the carrier of b2 holds
   ex b4, b5 being Element of b1 st
      b3 = homsym(b4,b5);

:: CATALG_1:th 25
theorem
for b1 being non empty set
for b2 being Element of the OperSymbols of CatSign b1
      st (b2 `1 = 1 implies len (b2 `2) <> 1)
   holds b2 `1 = 2 & len (b2 `2) = 3;

:: CATALG_1:th 26
theorem
for b1 being non empty set
for b2 being Element of the OperSymbols of CatSign b1
      st (b2 `1 = 1 or len (b2 `2) = 1)
   holds ex b3 being Element of b1 st
      b2 = idsym b3;

:: CATALG_1:th 27
theorem
for b1 being non empty set
for b2 being Element of the OperSymbols of CatSign b1
      st (b2 `1 = 2 or len (b2 `2) = 3)
   holds ex b3, b4, b5 being Element of b1 st
      b2 = compsym(b3,b4,b5);

:: CATALG_1:th 28
theorem
for b1 being non empty set
for b2 being Element of b1 holds
   the_arity_of idsym b2 = {} & the_result_sort_of idsym b2 = homsym(b2,b2);

:: CATALG_1:th 29
theorem
for b1 being non empty set
for b2, b3, b4 being Element of b1 holds
the_arity_of compsym(b2,b3,b4) = <*homsym(b3,b4),homsym(b2,b3)*> &
 the_result_sort_of compsym(b2,b3,b4) = homsym(b2,b4);

:: CATALG_1:funcnot 11 => CATALG_1:func 11
definition
  let a1, a2 be non void Category-like CatStr;
  let a3 be Functor of a1,a2;
  func Upsilon A3 -> Function-like quasi_total Relation of the carrier of CatSign the Vertices of a1,the carrier of CatSign the Vertices of a2 means
    for b1 being Element of the carrier of CatSign the Vertices of a1 holds
       it . b1 = [0,b1 `2 * Obj a3];
end;

:: CATALG_1:def 13
theorem
for b1, b2 being non void Category-like CatStr
for b3 being Functor of b1,b2
for b4 being Function-like quasi_total Relation of the carrier of CatSign the Vertices of b1,the carrier of CatSign the Vertices of b2 holds
      b4 = Upsilon b3
   iff
      for b5 being Element of the carrier of CatSign the Vertices of b1 holds
         b4 . b5 = [0,b5 `2 * Obj b3];

:: CATALG_1:funcnot 12 => CATALG_1:func 12
definition
  let a1, a2 be non void Category-like CatStr;
  let a3 be Functor of a1,a2;
  func Psi A3 -> Function-like quasi_total Relation of the OperSymbols of CatSign the Vertices of a1,the OperSymbols of CatSign the Vertices of a2 means
    for b1 being Element of the OperSymbols of CatSign the Vertices of a1 holds
       it . b1 = [b1 `1,b1 `2 * Obj a3];
end;

:: CATALG_1:def 14
theorem
for b1, b2 being non void Category-like CatStr
for b3 being Functor of b1,b2
for b4 being Function-like quasi_total Relation of the OperSymbols of CatSign the Vertices of b1,the OperSymbols of CatSign the Vertices of b2 holds
      b4 = Psi b3
   iff
      for b5 being Element of the OperSymbols of CatSign the Vertices of b1 holds
         b4 . b5 = [b5 `1,b5 `2 * Obj b3];

:: CATALG_1:th 30
theorem
for b1, b2 being non void Category-like CatStr
for b3 being Functor of b1,b2
for b4, b5 being Element of the Vertices of b1 holds
(Upsilon b3) . homsym(b4,b5) = homsym(b3 . b4,b3 . b5);

:: CATALG_1:th 31
theorem
for b1, b2 being non void Category-like CatStr
for b3 being Functor of b1,b2
for b4 being Element of the Vertices of b1 holds
   (Psi b3) . idsym b4 = idsym (b3 . b4);

:: CATALG_1:th 32
theorem
for b1, b2 being non void Category-like CatStr
for b3 being Functor of b1,b2
for b4, b5, b6 being Element of the Vertices of b1 holds
(Psi b3) . compsym(b4,b5,b6) = compsym(b3 . b4,b3 . b5,b3 . b6);

:: CATALG_1:th 33
theorem
for b1, b2 being non void Category-like CatStr
for b3 being Functor of b1,b2 holds
   Upsilon b3,Psi b3 form_morphism_between CatSign the Vertices of b1,CatSign the Vertices of b2;

:: CATALG_1:th 34
theorem
for b1 being non empty set
for b2 being MSAlgebra over CatSign b1
for b3 being Element of b1 holds
   Args(idsym b3,b2) = {{}};

:: CATALG_1:sch 1
scheme CATALG_1:sch 1
{F1 -> non empty set,
  F2 -> non empty set,
  F3 -> set,
  F4 -> set,
  F5 -> set}:
ex b1 being strict MSAlgebra over CatSign F1() st
   (for b2, b3 being Element of F1() holds
    (the Sorts of b1) . homsym(b2,b3) = F3(b2, b3)) &
    (for b2 being Element of F1() holds
       (Den(idsym b2,b1)) . {} = F5(b2)) &
    (for b2, b3, b4 being Element of F1()
    for b5, b6 being Element of F2()
          st b5 in F3(b2, b3) & b6 in F3(b3, b4)
       holds (Den(compsym(b2,b3,b4),b1)) . <*b6,b5*> = F4(b2, b3, b4, b6, b5))
provided
   for b1, b2 being Element of F1() holds
   F3(b1, b2) c= F2()
and
   for b1 being Element of F1() holds
      F5(b1) in F3(b1, b1)
and
   for b1, b2, b3 being Element of F1()
   for b4, b5 being Element of F2()
         st b4 in F3(b1, b2) & b5 in F3(b2, b3)
      holds F4(b1, b2, b3, b5, b4) in F3(b1, b3);


:: CATALG_1:funcnot 13 => CATALG_1:func 13
definition
  let a1 be non void Category-like CatStr;
  func MSAlg A1 -> strict MSAlgebra over CatSign the Vertices of a1 means
    (for b1, b2 being Element of the Vertices of a1 holds
     (the Sorts of it) . homsym(b1,b2) = Hom(b1,b2)) &
     (for b1 being Element of the Vertices of a1 holds
        (Den(idsym b1,it)) . {} = id b1) &
     (for b1, b2, b3 being Element of the Vertices of a1
     for b4, b5 being Element of the Edges of a1
           st dom b4 = b1 & cod b4 = b2 & dom b5 = b2 & cod b5 = b3
        holds (Den(compsym(b1,b2,b3),it)) . <*b5,b4*> = b5 * b4);
end;

:: CATALG_1:def 15
theorem
for b1 being non void Category-like CatStr
for b2 being strict MSAlgebra over CatSign the Vertices of b1 holds
      b2 = MSAlg b1
   iff
      (for b3, b4 being Element of the Vertices of b1 holds
       (the Sorts of b2) . homsym(b3,b4) = Hom(b3,b4)) &
       (for b3 being Element of the Vertices of b1 holds
          (Den(idsym b3,b2)) . {} = id b3) &
       (for b3, b4, b5 being Element of the Vertices of b1
       for b6, b7 being Element of the Edges of b1
             st dom b6 = b3 & cod b6 = b4 & dom b7 = b4 & cod b7 = b5
          holds (Den(compsym(b3,b4,b5),b2)) . <*b7,b6*> = b7 * b6);

:: CATALG_1:th 36
theorem
for b1 being non void Category-like CatStr
for b2 being Element of the Vertices of b1 holds
   Result(idsym b2,MSAlg b1) = Hom(b2,b2);

:: CATALG_1:th 37
theorem
for b1 being non void Category-like CatStr
for b2, b3, b4 being Element of the Vertices of b1 holds
Args(compsym(b2,b3,b4),MSAlg b1) = product <*Hom(b3,b4),Hom(b2,b3)*> &
 Result(compsym(b2,b3,b4),MSAlg b1) = Hom(b2,b4);

:: CATALG_1:funcreg 12
registration
  let a1 be non void Category-like CatStr;
  cluster MSAlg a1 -> strict disjoint_valued feasible;
end;

:: CATALG_1:th 38
theorem
for b1, b2 being non void Category-like CatStr
for b3 being Functor of b1,b2 holds
   b3 -MSF(the carrier of CatSign the Vertices of b1,the Sorts of MSAlg b1) is ManySortedFunction of the Sorts of MSAlg b1,the Sorts of (MSAlg b2) |(CatSign the Vertices of b1,Upsilon b3,Psi b3);

:: CATALG_1:th 39
theorem
for b1 being non void Category-like CatStr
for b2, b3, b4 being Element of the Vertices of b1
for b5 being set holds
      b5 in Args(compsym(b2,b3,b4),MSAlg b1)
   iff
      ex b6, b7 being Element of the Edges of b1 st
         b5 = <*b6,b7*> & dom b7 = b2 & cod b7 = b3 & dom b6 = b3 & cod b6 = b4;

:: CATALG_1:th 40
theorem
for b1, b2 being non void Category-like CatStr
for b3 being Functor of b1,b2
for b4, b5, b6 being Element of the Vertices of b1
for b7, b8 being Element of the Edges of b1
   st b7 in Hom(b4,b5) & b8 in Hom(b5,b6)
for b9 being Element of Args(compsym(b4,b5,b6),MSAlg b1)
   st b9 = <*b8,b7*>
for b10 being ManySortedFunction of the Sorts of MSAlg b1,the Sorts of (MSAlg b2) |(CatSign the Vertices of b1,Upsilon b3,Psi b3)
      st b10 = b3 -MSF(the carrier of CatSign the Vertices of b1,the Sorts of MSAlg b1)
   holds b10 # b9 = <*b3 . b8,b3 . b7*>;

:: CATALG_1:th 42
theorem
for b1 being non void Category-like CatStr
for b2, b3, b4 being Element of the Vertices of b1
for b5, b6 being Element of the Edges of b1
      st b5 in Hom(b2,b3) & b6 in Hom(b3,b4)
   holds (Den(compsym(b2,b3,b4),MSAlg b1)) . <*b6,b5*> = b6 * b5;

:: CATALG_1:th 43
theorem
for b1 being non void Category-like CatStr
for b2, b3, b4, b5 being Element of the Vertices of b1
for b6, b7, b8 being Element of the Edges of b1
      st b6 in Hom(b2,b3) & b7 in Hom(b3,b4) & b8 in Hom(b4,b5)
   holds (Den(compsym(b2,b4,b5),MSAlg b1)) . <*b8,(Den(compsym(b2,b3,b4),MSAlg b1)) . <*b7,b6*>*> = (Den(compsym(b2,b3,b5),MSAlg b1)) . <*(Den(compsym(b3,b4,b5),MSAlg b1)) . <*b8,b7*>,b6*>;

:: CATALG_1:th 44
theorem
for b1 being non void Category-like CatStr
for b2, b3 being Element of the Vertices of b1
for b4 being Element of the Edges of b1
      st b4 in Hom(b2,b3)
   holds (Den(compsym(b2,b3,b3),MSAlg b1)) . <*id b3,b4*> = b4 &
    (Den(compsym(b2,b2,b3),MSAlg b1)) . <*b4,id b2*> = b4;

:: CATALG_1:th 45
theorem
for b1, b2 being non void Category-like CatStr
for b3 being Functor of b1,b2 holds
   ex b4 being ManySortedFunction of the Sorts of MSAlg b1,the Sorts of (MSAlg b2) |(CatSign the Vertices of b1,Upsilon b3,Psi b3) st
      b4 = b3 -MSF(the carrier of CatSign the Vertices of b1,the Sorts of MSAlg b1) &
       b4 is_homomorphism MSAlg b1,(MSAlg b2) |(CatSign the Vertices of b1,Upsilon b3,Psi b3);