Article FUNCT_2, MML version 4.99.1005

:: FUNCT_2:attrnot 1 => FUNCT_2:attr 1
definition
  let a1, a2 be set;
  let a3 be Relation of a1,a2;
  attr a3 is quasi_total means
    a1 = dom a3
    if (a2 = {} implies a1 = {})
    otherwise a3 = {};
end;

:: FUNCT_2:dfs 1
definiens
  let a1, a2 be set;
  let a3 be Relation of a1,a2;
To prove
     a3 is quasi_total
it is sufficient to prove
  per cases;
  case (a2 = {} implies a1 = {});
    thus a1 = dom a3;
  end;
  case a2 = {} & a1 <> {};
    thus a3 = {};
  end;

:: FUNCT_2:def 1
theorem
for b1, b2 being set
for b3 being Relation of b1,b2 holds
   (b2 = {} & b1 <> {} or    (b3 is quasi_total(b1, b2)
    iff
       b1 = dom b3)) &
    (b2 = {} & b1 <> {} implies    (b3 is quasi_total(b1, b2)
    iff
       b3 = {}));

:: FUNCT_2:exreg 1
registration
  let a1, a2 be set;
  cluster Relation-like Function-like quasi_total Relation of a1,a2;
end;

:: FUNCT_2:condreg 1
registration
  let a1, a2 be set;
  cluster Function-like total -> quasi_total (Relation of a1,a2);
end;

:: FUNCT_2:modenot 1
definition
  let a1, a2 be set;
  mode Function of a1,a2 is Function-like quasi_total Relation of a1,a2;
end;

:: FUNCT_2:th 3
theorem
for b1 being Relation-like Function-like set holds
   b1 is Function-like quasi_total Relation of proj1 b1,proj2 b1;

:: FUNCT_2:th 4
theorem
for b1 being set
for b2 being Relation-like Function-like set
      st proj2 b2 c= b1
   holds b2 is Function-like quasi_total Relation of proj1 b2,b1;

:: FUNCT_2:th 5
theorem
for b1, b2 being set
for b3 being Relation-like Function-like set
      st proj1 b3 = b1 &
         (for b4 being set
               st b4 in b1
            holds b3 . b4 in b2)
   holds b3 is Function-like quasi_total Relation of b1,b2;

:: FUNCT_2:th 6
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
      st b2 <> {} & b3 in b1
   holds b4 . b3 in rng b4;

:: FUNCT_2:th 7
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
      st b2 <> {} & b3 in b1
   holds b4 . b3 in b2;

:: FUNCT_2:th 8
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {}) & rng b4 c= b3
   holds b4 is Function-like quasi_total Relation of b1,b3;

:: FUNCT_2:th 9
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {}) & b2 c= b3
   holds b4 is Function-like quasi_total Relation of b1,b3;

:: FUNCT_2:sch 1
scheme FUNCT_2:sch 1
{F1 -> set,
  F2 -> set}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   for b2 being set
         st b2 in F1()
      holds P1[b2, b1 . b2]
provided
   for b1 being set
         st b1 in F1()
      holds ex b2 being set st
         b2 in F2() & P1[b1, b2];


:: FUNCT_2:sch 2
scheme FUNCT_2:sch 2
{F1 -> set,
  F2 -> set,
  F3 -> set}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   for b2 being set
         st b2 in F1()
      holds b1 . b2 = F3(b2)
provided
   for b1 being set
         st b1 in F1()
      holds F3(b1) in F2();


:: FUNCT_2:funcnot 1 => FUNCT_2:func 1
definition
  let a1, a2 be set;
  func Funcs(A1,A2) -> set means
    for b1 being set holds
          b1 in it
       iff
          ex b2 being Relation-like Function-like set st
             b1 = b2 & proj1 b2 = a1 & proj2 b2 c= a2;
end;

:: FUNCT_2:def 2
theorem
for b1, b2, b3 being set holds
   b3 = Funcs(b1,b2)
iff
   for b4 being set holds
         b4 in b3
      iff
         ex b5 being Relation-like Function-like set st
            b4 = b5 & proj1 b5 = b1 & proj2 b5 c= b2;

:: FUNCT_2:th 11
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds b3 in Funcs(b1,b2);

:: FUNCT_2:th 12
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,b1 holds
   b2 in Funcs(b1,b1);

:: FUNCT_2:funcreg 1
registration
  let a1 be set;
  let a2 be non empty set;
  cluster Funcs(a1,a2) -> non empty;
end;

:: FUNCT_2:funcreg 2
registration
  let a1 be set;
  cluster Funcs(a1,a1) -> non empty;
end;

:: FUNCT_2:th 14
theorem
for b1 being set
      st b1 <> {}
   holds Funcs(b1,{}) = {};

:: FUNCT_2:th 16
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st b2 <> {} &
         (for b4 being set
               st b4 in b2
            holds ex b5 being set st
               b5 in b1 & b4 = b3 . b5)
   holds rng b3 = b2;

:: FUNCT_2:th 17
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
      st b3 in rng b4
   holds ex b5 being set st
      b5 in b1 & b4 . b5 = b3;

:: FUNCT_2:th 18
theorem
for b1, b2 being set
for b3, b4 being Function-like quasi_total Relation of b1,b2
      st for b5 being set
              st b5 in b1
           holds b3 . b5 = b4 . b5
   holds b3 = b4;

:: FUNCT_2:th 19
theorem
for b1, b2, b3 being set
for b4 being quasi_total Relation of b1,b2
for b5 being quasi_total Relation of b2,b3
      st (b2 = {} & b3 <> {} implies b1 = {})
   holds b4 * b5 is quasi_total(b1, b3);

:: FUNCT_2:th 20
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
for b5 being Function-like quasi_total Relation of b2,b3
      st b2 <> {} & b3 <> {} & rng b4 = b2 & rng b5 = b3
   holds rng (b5 * b4) = b3;

:: FUNCT_2:th 21
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
for b5 being Relation-like Function-like set
      st b2 <> {} & b3 in b1
   holds (b4 * b5) . b3 = b5 . (b4 . b3);

:: FUNCT_2:th 22
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st b2 <> {}
   holds    rng b3 = b2
   iff
      for b4 being set
         st b4 <> {}
      for b5, b6 being Function-like quasi_total Relation of b2,b4
            st b5 * b3 = b6 * b3
         holds b5 = b6;

:: FUNCT_2:th 23
theorem
for b1, b2 being set
for b3 being Relation of b1,b2 holds
   (id b1) * b3 = b3 & b3 * id b2 = b3;

:: FUNCT_2:th 24
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
for b4 being Function-like quasi_total Relation of b2,b1
      st b3 * b4 = id b2
   holds rng b3 = b2;

:: FUNCT_2:th 25
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds    b3 is one-to-one
   iff
      for b4, b5 being set
            st b4 in b1 & b5 in b1 & b3 . b4 = b3 . b5
         holds b4 = b5;

:: FUNCT_2:th 26
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
for b5 being Function-like quasi_total Relation of b2,b3
      st (b3 = {} implies b2 = {}) & (b2 = {} implies b1 = {}) & b5 * b4 is one-to-one
   holds b4 is one-to-one;

:: FUNCT_2:th 27
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st b1 <> {} & b2 <> {}
   holds    b3 is one-to-one
   iff
      for b4 being set
      for b5, b6 being Function-like quasi_total Relation of b4,b1
            st b3 * b5 = b3 * b6
         holds b5 = b6;

:: FUNCT_2:th 28
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
for b5 being Function-like quasi_total Relation of b2,b3
      st b3 <> {} & rng (b5 * b4) = b3 & b5 is one-to-one
   holds rng b4 = b2;

:: FUNCT_2:th 29
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
for b4 being Function-like quasi_total Relation of b2,b1
      st b2 <> {} & b4 * b3 = id b1
   holds b3 is one-to-one & rng b4 = b1;

:: FUNCT_2:th 30
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
for b5 being Function-like quasi_total Relation of b2,b3
      st (b3 = {} implies b2 = {}) & b5 * b4 is one-to-one & rng b4 = b2
   holds b4 is one-to-one & b5 is one-to-one;

:: FUNCT_2:th 31
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st b3 is one-to-one & rng b3 = b2
   holds b3 " is Function-like quasi_total Relation of b2,b1;

:: FUNCT_2:th 32
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
      st b2 <> {} & b4 is one-to-one & b3 in b1
   holds b4 " . (b4 . b3) = b3;

:: FUNCT_2:th 34
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
for b4 being Function-like quasi_total Relation of b2,b1
      st b1 <> {} &
         b2 <> {} &
         rng b3 = b2 &
         b3 is one-to-one &
         (for b5, b6 being set holds
            b5 in b2 & b4 . b5 = b6
         iff
            b6 in b1 & b3 . b6 = b5)
   holds b4 = b3 ";

:: FUNCT_2:th 35
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st b2 <> {} & rng b3 = b2 & b3 is one-to-one
   holds b3 * (b3 ") = id b1 & b3 " * b3 = id b2;

:: FUNCT_2:th 36
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
for b4 being Function-like quasi_total Relation of b2,b1
      st b1 <> {} & b2 <> {} & rng b3 = b2 & b4 * b3 = id b1 & b3 is one-to-one
   holds b4 = b3 ";

:: FUNCT_2:th 37
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st b2 <> {} &
         (ex b4 being Function-like quasi_total Relation of b2,b1 st
            b4 * b3 = id b1)
   holds b3 is one-to-one;

:: FUNCT_2:th 38
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {}) & b3 c= b1
   holds b4 | b3 is Function-like quasi_total Relation of b3,b2;

:: FUNCT_2:th 40
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
      st b1 c= b3
   holds b4 | b3 = b4;

:: FUNCT_2:th 41
theorem
for b1, b2, b3, b4 being set
for b5 being Function-like quasi_total Relation of b1,b2
      st b2 <> {} & b3 in b1 & b5 . b3 in b4
   holds (b4 | b5) . b3 = b5 . b3;

:: FUNCT_2:th 43
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
   st b2 <> {}
for b5 being set
      st ex b6 being set st
           b6 in b1 & b6 in b3 & b5 = b4 . b6
   holds b5 in b4 .: b3;

:: FUNCT_2:th 44
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2 holds
   b4 .: b3 c= b2;

:: FUNCT_2:th 45
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds b3 .: b1 = rng b3;

:: FUNCT_2:th 46
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
   st b2 <> {}
for b5 being set holds
      b5 in b4 " b3
   iff
      b5 in b1 & b4 . b5 in b3;

:: FUNCT_2:th 47
theorem
for b1, b2, b3 being set
for b4 being Function-like Relation of b1,b2 holds
   b4 " b3 c= b1;

:: FUNCT_2:th 48
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds b3 " b2 = b1;

:: FUNCT_2:th 49
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2 holds
      for b4 being set
            st b4 in b2
         holds b3 " {b4} <> {}
   iff
      rng b3 = b2;

:: FUNCT_2:th 50
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {}) & b3 c= b1
   holds b3 c= b4 " (b4 .: b3);

:: FUNCT_2:th 51
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds b3 " (b3 .: b1) = b1;

:: FUNCT_2:th 53
theorem
for b1, b2, b3, b4 being set
for b5 being Function-like quasi_total Relation of b1,b2
for b6 being Function-like quasi_total Relation of b2,b3
      st (b3 = {} implies b2 = {}) & (b2 = {} implies b1 = {})
   holds b5 " b4 c= (b6 * b5) " (b6 .: b4);

:: FUNCT_2:th 55
theorem
for b1 being set
for b2 being Relation-like Function-like set
      st proj1 b2 = {}
   holds b2 is Function-like quasi_total Relation of {},b1;

:: FUNCT_2:th 59
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of {},b1 holds
   b3 .: b2 = {};

:: FUNCT_2:th 60
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of {},b1 holds
   b3 " b2 = {};

:: FUNCT_2:th 61
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of {b1},b2
      st b2 <> {}
   holds b3 . b1 in b2;

:: FUNCT_2:th 62
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of {b1},b2
      st b2 <> {}
   holds rng b3 = {b3 . b1};

:: FUNCT_2:th 64
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of {b1},b2
      st b2 <> {}
   holds b4 .: b3 c= {b4 . b1};

:: FUNCT_2:th 65
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,{b2}
      st b3 in b1
   holds b4 . b3 = b2;

:: FUNCT_2:th 66
theorem
for b1, b2 being set
for b3, b4 being Function-like quasi_total Relation of b1,{b2} holds
b3 = b4;

:: FUNCT_2:funcreg 3
registration
  let a1 be set;
  let a2, a3 be Function-like quasi_total Relation of a1,a1;
  cluster a2 * a3 -> Function-like quasi_total;
end;

:: FUNCT_2:th 67
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,b1 holds
   dom b2 = b1;

:: FUNCT_2:th 70
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b1
for b4 being Relation-like Function-like set
      st b2 in b1
   holds (b3 * b4) . b2 = b4 . (b3 . b2);

:: FUNCT_2:th 73
theorem
for b1 being set
for b2, b3 being Relation of b1,b1
      st rng b2 = b1 & rng b3 = b1
   holds rng (b3 * b2) = b1;

:: FUNCT_2:th 75
theorem
for b1 being set
for b2, b3 being Function-like quasi_total Relation of b1,b1
      st b3 * b2 = b2 & rng b2 = b1
   holds b3 = id b1;

:: FUNCT_2:th 76
theorem
for b1 being set
for b2, b3 being Function-like quasi_total Relation of b1,b1
      st b2 * b3 = b2 & b2 is one-to-one
   holds b3 = id b1;

:: FUNCT_2:th 77
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,b1 holds
      b2 is one-to-one
   iff
      for b3, b4 being set
            st b3 in b1 & b4 in b1 & b2 . b3 = b2 . b4
         holds b3 = b4;

:: FUNCT_2:th 79
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,b1 holds
   b2 .: b1 = rng b2;

:: FUNCT_2:th 82
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,b1 holds
   b2 " (b2 .: b1) = b1;

:: FUNCT_2:attrnot 2 => FUNCT_2:attr 2
definition
  let a1, a2 be set;
  let a3 be Relation of a1,a2;
  attr a3 is onto means
    rng a3 = a2;
end;

:: FUNCT_2:dfs 3
definiens
  let a1, a2 be set;
  let a3 be Relation of a1,a2;
To prove
     a3 is onto
it is sufficient to prove
  thus rng a3 = a2;

:: FUNCT_2:def 3
theorem
for b1, b2 being set
for b3 being Relation of b1,b2 holds
      b3 is onto(b1, b2)
   iff
      rng b3 = b2;

:: FUNCT_2:attrnot 3 => FUNCT_2:attr 3
definition
  let a1, a2 be set;
  let a3 be Function-like quasi_total Relation of a1,a2;
  attr a3 is bijective means
    a3 is one-to-one & a3 is onto(a1, a2);
end;

:: FUNCT_2:dfs 4
definiens
  let a1, a2 be set;
  let a3 be Function-like quasi_total Relation of a1,a2;
To prove
     a3 is bijective
it is sufficient to prove
  thus a3 is one-to-one & a3 is onto(a1, a2);

:: FUNCT_2:def 4
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2 holds
      b3 is bijective(b1, b2)
   iff
      b3 is one-to-one & b3 is onto(b1, b2);

:: FUNCT_2:condreg 2
registration
  let a1, a2 be set;
  cluster Function-like quasi_total bijective -> one-to-one onto (Relation of a1,a2);
end;

:: FUNCT_2:condreg 3
registration
  let a1, a2 be set;
  cluster Function-like one-to-one quasi_total onto -> bijective (Relation of a1,a2);
end;

:: FUNCT_2:exreg 2
registration
  let a1 be set;
  cluster Relation-like Function-like quasi_total bijective Relation of a1,a1;
end;

:: FUNCT_2:modenot 2
definition
  let a1 be set;
  mode Permutation of a1 is Function-like quasi_total bijective Relation of a1,a1;
end;

:: FUNCT_2:th 83
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,b1
      st b2 is one-to-one & rng b2 = b1
   holds b2 is Function-like quasi_total bijective Relation of b1,b1;

:: FUNCT_2:th 85
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,b1
   st b2 is one-to-one
for b3, b4 being set
      st b3 in b1 & b4 in b1 & b2 . b3 = b2 . b4
   holds b3 = b4;

:: FUNCT_2:funcreg 4
registration
  let a1 be set;
  let a2, a3 be Function-like onto Relation of a1,a1;
  cluster a3 * a2 -> Function-like onto;
end;

:: FUNCT_2:funcreg 5
registration
  let a1 be set;
  let a2, a3 be Function-like quasi_total bijective Relation of a1,a1;
  cluster a2 * a3 -> Function-like quasi_total bijective;
end;

:: FUNCT_2:condreg 4
registration
  let a1 be set;
  cluster reflexive Function-like total quasi_total -> bijective (Relation of a1,a1);
end;

:: FUNCT_2:funcnot 2 => FUNCT_2:func 2
definition
  let a1 be set;
  let a2 be Function-like quasi_total bijective Relation of a1,a1;
  redefine func a2 " -> Function-like quasi_total bijective Relation of a1,a1;
end;

:: FUNCT_2:th 86
theorem
for b1 being set
for b2, b3 being Function-like quasi_total bijective Relation of b1,b1
      st b3 * b2 = b3
   holds b2 = id b1;

:: FUNCT_2:th 87
theorem
for b1 being set
for b2, b3 being Function-like quasi_total bijective Relation of b1,b1
      st b3 * b2 = id b1
   holds b3 = b2 ";

:: FUNCT_2:th 88
theorem
for b1 being set
for b2 being Function-like quasi_total bijective Relation of b1,b1 holds
   b2 " * b2 = id b1 & b2 * (b2 ") = id b1;

:: FUNCT_2:th 92
theorem
for b1, b2 being set
for b3 being Function-like quasi_total bijective Relation of b1,b1
      st b2 c= b1
   holds b3 .: (b3 " b2) = b2 & b3 " (b3 .: b2) = b2;

:: FUNCT_2:condreg 5
registration
  let a1 be set;
  let a2 be non empty set;
  cluster Function-like quasi_total -> total (Relation of a1,a2);
end;

:: FUNCT_2:funcreg 6
registration
  let a1 be set;
  let a2 be non empty set;
  let a3 be set;
  let a4 be Function-like quasi_total Relation of a1,a2;
  let a5 be Function-like quasi_total Relation of a2,a3;
  cluster a4 * a5 -> Function-like quasi_total;
end;

:: FUNCT_2:funcnot 3 => FUNCT_2:func 3
definition
  let a1 be non empty set;
  let a2 be set;
  let a3 be Function-like quasi_total Relation of a1,a2;
  let a4 be Element of a1;
  redefine func a3 . a4 -> Element of a2;
end;

:: FUNCT_2:sch 3
scheme FUNCT_2:sch 3
{F1 -> non empty set,
  F2 -> non empty set}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   for b2 being Element of F1() holds
      P1[b2, b1 . b2]
provided
   for b1 being Element of F1() holds
      ex b2 being Element of F2() st
         P1[b1, b2];


:: FUNCT_2:sch 4
scheme FUNCT_2:sch 4
{F1 -> non empty set,
  F2 -> non empty set,
  F3 -> Element of F2()}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   for b2 being Element of F1() holds
      b1 . b2 = F3(b2)


:: FUNCT_2:th 113
theorem
for b1, b2 being set
for b3, b4 being Function-like quasi_total Relation of b1,b2
      st for b5 being Element of b1 holds
           b3 . b5 = b4 . b5
   holds b3 = b4;

:: FUNCT_2:th 115
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
for b5 being set
      st b5 in b4 .: b3
   holds ex b6 being set st
      b6 in b1 & b6 in b3 & b5 = b4 . b6;

:: FUNCT_2:th 116
theorem
for b1, b2, b3 being set
for b4 being Function-like quasi_total Relation of b1,b2
for b5 being set
      st b5 in b4 .: b3
   holds ex b6 being Element of b1 st
      b6 in b3 & b5 = b4 . b6;

:: FUNCT_2:th 121
theorem
for b1, b2, b3 being set
      st b3 in Funcs(b1,b2)
   holds b3 is Function-like quasi_total Relation of b1,b2;

:: FUNCT_2:sch 5
scheme FUNCT_2:sch 5
{F1 -> set,
  F2 -> set,
  F3 -> set,
  F4 -> set}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   for b2 being set
         st b2 in F1()
      holds (P1[b2] implies b1 . b2 = F3(b2)) & (P1[b2] or b1 . b2 = F4(b2))
provided
   for b1 being set
         st b1 in F1()
      holds (P1[b1] implies F3(b1) in F2()) & (P1[b1] or F4(b1) in F2());


:: FUNCT_2:th 130
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,b2
      st dom b3 = b1
   holds b3 is Function-like quasi_total Relation of b1,b2;

:: FUNCT_2:th 131
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,b2
      st b3 is total(b1, b2)
   holds b3 is Function-like quasi_total Relation of b1,b2;

:: FUNCT_2:th 132
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,b2
      st (b2 = {} implies b1 = {}) & b3 is Function-like quasi_total Relation of b1,b2
   holds b3 is total(b1, b2);

:: FUNCT_2:th 133
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds <:b3,b1,b2:> is total(b1, b2);

:: FUNCT_2:th 134
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,b1 holds
   <:b2,b1,b1:> is total(b1, b1);

:: FUNCT_2:th 136
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds ex b4 being Function-like quasi_total Relation of b1,b2 st
      for b5 being set
            st b5 in dom b3
         holds b4 . b5 = b3 . b5;

:: FUNCT_2:th 141
theorem
for b1, b2 being set holds
Funcs(b1,b2) c= PFuncs(b1,b2);

:: FUNCT_2:th 142
theorem
for b1, b2 being set
for b3, b4 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {}) & b3 tolerates b4
   holds b3 = b4;

:: FUNCT_2:th 143
theorem
for b1 being set
for b2, b3 being Function-like quasi_total Relation of b1,b1
      st b2 tolerates b3
   holds b2 = b3;

:: FUNCT_2:th 145
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,b2
for b4 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds    b3 tolerates b4
   iff
      for b5 being set
            st b5 in dom b3
         holds b3 . b5 = b4 . b5;

:: FUNCT_2:th 146
theorem
for b1 being set
for b2 being Function-like Relation of b1,b1
for b3 being Function-like quasi_total Relation of b1,b1 holds
      b2 tolerates b3
   iff
      for b4 being set
            st b4 in dom b2
         holds b2 . b4 = b3 . b4;

:: FUNCT_2:th 148
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds ex b4 being Function-like quasi_total Relation of b1,b2 st
      b3 tolerates b4;

:: FUNCT_2:th 149
theorem
for b1 being set
for b2 being Function-like Relation of b1,b1 holds
   ex b3 being Function-like quasi_total Relation of b1,b1 st
      b2 tolerates b3;

:: FUNCT_2:th 151
theorem
for b1, b2 being set
for b3, b4 being Function-like Relation of b1,b2
for b5 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {}) & b3 tolerates b5 & b4 tolerates b5
   holds b3 tolerates b4;

:: FUNCT_2:th 152
theorem
for b1 being set
for b2, b3 being Function-like Relation of b1,b1
for b4 being Function-like quasi_total Relation of b1,b1
      st b2 tolerates b4 & b3 tolerates b4
   holds b2 tolerates b3;

:: FUNCT_2:th 154
theorem
for b1, b2 being set
for b3, b4 being Function-like Relation of b1,b2
      st (b2 = {} implies b1 = {}) & b3 tolerates b4
   holds ex b5 being Function-like quasi_total Relation of b1,b2 st
      b3 tolerates b5 & b4 tolerates b5;

:: FUNCT_2:th 155
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,b2
for b4 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {}) & b3 tolerates b4
   holds b4 in TotFuncs b3;

:: FUNCT_2:th 156
theorem
for b1 being set
for b2 being Function-like Relation of b1,b1
for b3 being Function-like quasi_total Relation of b1,b1
      st b2 tolerates b3
   holds b3 in TotFuncs b2;

:: FUNCT_2:th 158
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,b2
for b4 being set
      st b4 in TotFuncs b3
   holds b4 is Function-like quasi_total Relation of b1,b2;

:: FUNCT_2:th 159
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,b2 holds
   TotFuncs b3 c= Funcs(b1,b2);

:: FUNCT_2:th 160
theorem
for b1, b2 being set holds
TotFuncs <:{},b1,b2:> = Funcs(b1,b2);

:: FUNCT_2:th 161
theorem
for b1, b2 being set
for b3 being Function-like quasi_total Relation of b1,b2
      st (b2 = {} implies b1 = {})
   holds TotFuncs <:b3,b1,b2:> = {b3};

:: FUNCT_2:th 162
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,b1 holds
   TotFuncs <:b2,b1,b1:> = {b2};

:: FUNCT_2:th 164
theorem
for b1, b2 being set
for b3 being Function-like Relation of b1,{b2}
for b4 being Function-like quasi_total Relation of b1,{b2} holds
   TotFuncs b3 = {b4};

:: FUNCT_2:th 165
theorem
for b1, b2 being set
for b3, b4 being Function-like Relation of b1,b2
      st b4 c= b3
   holds TotFuncs b3 c= TotFuncs b4;

:: FUNCT_2:th 166
theorem
for b1, b2 being set
for b3, b4 being Function-like Relation of b1,b2
      st dom b4 c= dom b3 & TotFuncs b3 c= TotFuncs b4
   holds b4 c= b3;

:: FUNCT_2:th 167
theorem
for b1, b2 being set
for b3, b4 being Function-like Relation of b1,b2
      st TotFuncs b3 c= TotFuncs b4 &
         (for b5 being set holds
            b2 <> {b5})
   holds b4 c= b3;

:: FUNCT_2:th 168
theorem
for b1, b2 being set
for b3, b4 being Function-like Relation of b1,b2
      st (for b5 being set holds
            b2 <> {b5}) &
         TotFuncs b3 = TotFuncs b4
   holds b3 = b4;

:: FUNCT_2:condreg 6
registration
  let a1, a2 be non empty set;
  cluster Function-like quasi_total -> non empty (Relation of a1,a2);
end;

:: FUNCT_2:sch 6
scheme FUNCT_2:sch 6
{F1 -> non empty set,
  F2 -> non empty set,
  F3 -> Element of F1(),
  F4 -> Element of F2(),
  F5 -> Element of F2()}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   b1 . F3() = F4() &
    (for b2 being Element of F1()
          st b2 <> F3()
       holds b1 . b2 = F5(b2))


:: FUNCT_2:sch 7
scheme FUNCT_2:sch 7
{F1 -> non empty set,
  F2 -> non empty set,
  F3 -> Element of F1(),
  F4 -> Element of F1(),
  F5 -> Element of F2(),
  F6 -> Element of F2(),
  F7 -> Element of F2()}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   b1 . F3() = F5() &
    b1 . F4() = F6() &
    (for b2 being Element of F1()
          st b2 <> F3() & b2 <> F4()
       holds b1 . b2 = F7(b2))
provided
   F3() <> F4();


:: FUNCT_2:th 169
theorem
for b1, b2 being set
for b3 being Relation-like Function-like set
      st b3 in Funcs(b1,b2)
   holds proj1 b3 = b1 & proj2 b3 c= b2;

:: FUNCT_2:sch 8
scheme FUNCT_2:sch 8
{F1 -> non empty set,
  F2 -> set,
  F3 -> set}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   for b2 being Element of F1() holds
      b1 . b2 = F3(b2)
provided
   for b1 being Element of F1() holds
      F3(b1) in F2();


:: FUNCT_2:sch 9
scheme FUNCT_2:sch 9
{F1 -> non empty set,
  F2 -> non empty set,
  F3 -> set}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   for b2 being Element of F1() holds
      b1 . b2 = F3(b2)
provided
   for b1 being Element of F1() holds
      F3(b1) is Element of F2();


:: FUNCT_2:sch 10
scheme FUNCT_2:sch 10
{F1 -> non empty set,
  F2 -> non empty set}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   for b2 being Element of F1() holds
      P1[b2, b1 . b2]
provided
   for b1 being Element of F1() holds
      ex b2 being Element of F2() st
         P1[b1, b2];


:: FUNCT_2:funcnot 4 => FUNCT_2:func 4
definition
  let a1, a2, a3 be non empty set;
  let a4 be Function-like quasi_total Relation of a1,[:a2,a3:];
  redefine func pr1 A4 -> Function-like quasi_total Relation of a1,a2 means
    for b1 being Element of a1 holds
       it . b1 = (a4 . b1) `1;
end;

:: FUNCT_2:def 6
theorem
for b1, b2, b3 being non empty set
for b4 being Function-like quasi_total Relation of b1,[:b2,b3:]
for b5 being Function-like quasi_total Relation of b1,b2 holds
      b5 = pr1 b4
   iff
      for b6 being Element of b1 holds
         b5 . b6 = (b4 . b6) `1;

:: FUNCT_2:funcnot 5 => FUNCT_2:func 5
definition
  let a1, a2, a3 be non empty set;
  let a4 be Function-like quasi_total Relation of a1,[:a2,a3:];
  redefine func pr2 A4 -> Function-like quasi_total Relation of a1,a3 means
    for b1 being Element of a1 holds
       it . b1 = (a4 . b1) `2;
end;

:: FUNCT_2:def 7
theorem
for b1, b2, b3 being non empty set
for b4 being Function-like quasi_total Relation of b1,[:b2,b3:]
for b5 being Function-like quasi_total Relation of b1,b3 holds
      b5 = pr2 b4
   iff
      for b6 being Element of b1 holds
         b5 . b6 = (b4 . b6) `2;

:: FUNCT_2:prednot 1 => FUNCT_2:pred 1
definition
  let a1 be set;
  let a2 be non empty set;
  let a3 be set;
  let a4 be non empty set;
  let a5 be Function-like quasi_total Relation of a1,a2;
  let a6 be Function-like quasi_total Relation of a3,a4;
  redefine pred A5 = A6 means
    a1 = a3 &
     (for b1 being Element of a1 holds
        a5 . b1 = a6 . b1);
  symmetry;
::  for a1 being set
::  for a2 being non empty set
::  for a3 being set
::  for a4 being non empty set
::  for a5 being Function-like quasi_total Relation of a1,a2
::  for a6 being Function-like quasi_total Relation of a3,a4
::        st a5 = a6
::     holds a6 = a5;
  reflexivity;
::  for a1 being set
::  for a2 being non empty set
::  for a3 being set
::  for a4 being non empty set
::  for a5 being Function-like quasi_total Relation of a1,a2 holds
::     a5 = a5;
end;

:: FUNCT_2:dfs 7
definiens
  let a1 be set;
  let a2 be non empty set;
  let a3 be set;
  let a4 be non empty set;
  let a5 be Function-like quasi_total Relation of a1,a2;
  let a6 be Function-like quasi_total Relation of a3,a4;
To prove
     a5 = a6
it is sufficient to prove
  thus a1 = a3 &
     (for b1 being Element of a1 holds
        a5 . b1 = a6 . b1);

:: FUNCT_2:def 8
theorem
for b1 being set
for b2 being non empty set
for b3 being set
for b4 being non empty set
for b5 being Function-like quasi_total Relation of b1,b2
for b6 being Function-like quasi_total Relation of b3,b4 holds
      b5 = b6
   iff
      b1 = b3 &
       (for b7 being Element of b1 holds
          b5 . b7 = b6 . b7);

:: FUNCT_2:prednot 2 => FUNCT_2:pred 2
definition
  let a1 be set;
  let a2 be non empty set;
  let a3, a4 be Function-like quasi_total Relation of a1,a2;
  redefine pred A3 = A4 means
    for b1 being Element of a1 holds
       a3 . b1 = a4 . b1;
  symmetry;
::  for a1 being set
::  for a2 being non empty set
::  for a3, a4 being Function-like quasi_total Relation of a1,a2
::        st a3 = a4
::     holds a4 = a3;
  reflexivity;
::  for a1 being set
::  for a2 being non empty set
::  for a3 being Function-like quasi_total Relation of a1,a2 holds
::     a3 = a3;
end;

:: FUNCT_2:dfs 8
definiens
  let a1 be set;
  let a2 be non empty set;
  let a3, a4 be Function-like quasi_total Relation of a1,a2;
To prove
     a3 = a4
it is sufficient to prove
  thus for b1 being Element of a1 holds
       a3 . b1 = a4 . b1;

:: FUNCT_2:def 9
theorem
for b1 being set
for b2 being non empty set
for b3, b4 being Function-like quasi_total Relation of b1,b2 holds
   b3 = b4
iff
   for b5 being Element of b1 holds
      b3 . b5 = b4 . b5;

:: FUNCT_2:th 170
theorem
for b1 being set
for b2 being Function-like quasi_total Relation of b1,bool b1 holds
   ex b3 being Relation of b1,b1 st
      for b4 being set
            st b4 in b1
         holds Im(b3,b4) = b2 . b4;

:: FUNCT_2:th 171
theorem
for b1 being set
for b2 being Element of bool b1 holds
   (id b1) " b2 = b2;

:: FUNCT_2:th 172
theorem
for b1, b2 being non empty set
for b3 being Function-like quasi_total Relation of b1,b2
for b4 being Element of bool b1
for b5 being Element of bool b2 holds
      b3 .: b4 c= b5
   iff
      b4 c= b3 " b5;

:: FUNCT_2:th 173
theorem
for b1, b2 being non empty set
for b3 being Function-like quasi_total Relation of b1,b2
for b4 being non empty Element of bool b1
for b5 being Function-like quasi_total Relation of b4,b2
      st for b6 being Element of b1
              st b6 in b4
           holds b3 . b6 = b5 . b6
   holds b3 | b4 = b5;

:: FUNCT_2:th 174
theorem
for b1 being Relation-like Function-like set
for b2, b3 being set
      st b3 c= b2
   holds b1 .: b3 = (b1 | b2) .: b3;

:: FUNCT_2:th 175
theorem
for b1 being Relation-like Function-like set
for b2, b3 being set
      st b1 " b3 c= b2
   holds b1 " b3 = (b1 | b2) " b3;

:: FUNCT_2:sch 11
scheme FUNCT_2:sch 11
{F1 -> non empty set,
  F2 -> non empty set,
  F3 -> set}:
ex b1 being Function-like quasi_total Relation of F1(),F2() st
   for b2 being Element of F1() holds
      b1 . b2 in F3(b2)
provided
   for b1 being Element of F1() holds
      F2() meets F3(b1);


:: FUNCT_2:th 176
theorem
for b1, b2 being non empty set
for b3 being Function-like quasi_total Relation of b1,b2
for b4 being Element of b1 holds
   b3 /. b4 = b3 . b4;