:: NATTRA_1 semantic presentation

definition
let c1 be set ;
let c2 be non empty set ;
let c3 be Function of c1,c2;
let c4 be Subset of c1;
redefine func | as c3 | c4 -> Function of a4,a2;
coherence
c3 | c4 is Function of c4,c2
by FUNCT_2:38;
end;

theorem Th1: :: NATTRA_1:1
for b1, b2, b3, b4 being non empty set
for b5 being Function of b3,b1
for b6 being Function of b4,b2
for b7 being non empty Subset of b3
for b8 being non empty Subset of b4 holds [:b5,b6:] | [:b7,b8:] = [:(b5 | b7),(b6 | b8):]
proof end;

definition
let c1, c2 be non empty set ;
let c3 be non empty Subset of c1;
let c4 be non empty Subset of c2;
let c5 be PartFunc of [:c3,c3:],c3;
let c6 be PartFunc of [:c4,c4:],c4;
redefine func |: as |:c5,c6:| -> PartFunc of [:[:a3,a4:],[:a3,a4:]:],[:a3,a4:];
coherence
|:c5,c6:| is PartFunc of [:[:c3,c4:],[:c3,c4:]:],[:c3,c4:]
by FUNCT_4:62;
end;

theorem Th2: :: NATTRA_1:2
for b1, b2 being non empty set
for b3 being non empty Subset of b1
for b4 being non empty Subset of b2
for b5 being PartFunc of [:b1,b1:],b1
for b6 being PartFunc of [:b2,b2:],b2
for b7 being PartFunc of [:b3,b3:],b3 st b7 = b5 || b3 holds
for b8 being PartFunc of [:b4,b4:],b4 st b8 = b6 || b4 holds
|:b7,b8:| = |:b5,b6:| || [:b3,b4:]
proof end;

scheme :: NATTRA_1:sch 1
s1{ F1() -> non empty set , F2() -> non empty set , F3( set ) -> set } :
ex b1 being Function of F1(),F2() st
for b2 being Element of F1() holds b1 . b2 in F3(b2)
provided
E3: for b1 being Element of F1() holds F2() meets F3(b1)
proof end;

theorem Th3: :: NATTRA_1:3
for b1 being Category
for b2 being Object of b1
for b3 being Morphism of b2,b2 holds b3 in Hom b2,b2
proof end;

theorem Th4: :: NATTRA_1:4
for b1, b2 being set
for b3, b4 being Morphism of (1Cat b1,b2) holds b3 = b4
proof end;

theorem Th5: :: NATTRA_1:5
for b1 being Category
for b2 being Object of b1 holds [[(id b2),(id b2)],(id b2)] in the Comp of b1
proof end;

theorem Th6: :: NATTRA_1:6
for b1, b2 being set holds the Comp of (1Cat b1,b2) = {[[b2,b2],b2]}
proof end;

theorem Th7: :: NATTRA_1:7
for b1 being Category
for b2 being Object of b1 holds 1Cat b2,(id b2) is Subcategory of b1
proof end;

theorem Th8: :: NATTRA_1:8
for b1 being Category
for b2 being Subcategory of b1 holds
( the Dom of b2 = the Dom of b1 | the Morphisms of b2 & the Cod of b2 = the Cod of b1 | the Morphisms of b2 & the Comp of b2 = the Comp of b1 || the Morphisms of b2 & the Id of b2 = the Id of b1 | the Objects of b2 )
proof end;

theorem Th9: :: NATTRA_1:9
for b1 being Category
for b2 being non empty Subset of the Objects of b1
for b3 being non empty Subset of the Morphisms of b1
for b4, b5 being Function of b3,b2 st b4 = the Dom of b1 | b3 & b5 = the Cod of b1 | b3 holds
for b6 being PartFunc of [:b3,b3:],b3 st b6 = the Comp of b1 || b3 holds
for b7 being Function of b2,b3 st b7 = the Id of b1 | b2 holds
CatStr(# b2,b3,b4,b5,b6,b7 #) is Subcategory of b1
proof end;

theorem Th10: :: NATTRA_1:10
for b1 being strict Category
for b2 being strict Subcategory of b1 st the Objects of b2 = the Objects of b1 & the Morphisms of b2 = the Morphisms of b1 holds
b2 = b1
proof end;

definition
let c1, c2 be Category;
let c3 be Functor of c1,c2;
let c4, c5 be Object of c1;
assume E11: Hom c4,c5 <> {} ;
let c6 be Morphism of c4,c5;
func c3 . c6 -> Morphism of a3 . a4,a3 . a5 equals :Def1: :: NATTRA_1:def 1
a3 . a6;
coherence
c3 . c6 is Morphism of c3 . c4,c3 . c5
by E11, CAT_1:125;
end;

:: deftheorem Def1 defines . NATTRA_1:def 1 :
for b1, b2 being Category
for b3 being Functor of b1,b2
for b4, b5 being Object of b1 st Hom b4,b5 <> {} holds
for b6 being Morphism of b4,b5 holds b3 . b6 = b3 . b6;

theorem Th11: :: NATTRA_1:11
for b1, b2, b3 being Category
for b4 being Functor of b3,b1
for b5 being Functor of b1,b2
for b6, b7 being Object of b3 st Hom b6,b7 <> {} holds
for b8 being Morphism of b6,b7 holds (b5 * b4) . b8 = b5 . (b4 . b8)
proof end;

theorem Th12: :: NATTRA_1:12
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 st ( for b5, b6 being Object of b1 st Hom b5,b6 <> {} holds
for b7 being Morphism of b5,b6 holds b3 . b7 = b4 . b7 ) holds
b3 = b4
proof end;

theorem Th13: :: NATTRA_1:13
for b1, b2 being Category
for b3 being Functor of b2,b1
for b4, b5, b6 being Object of b2 st Hom b4,b5 <> {} & Hom b5,b6 <> {} holds
for b7 being Morphism of b4,b5
for b8 being Morphism of b5,b6 holds b3 . (b8 * b7) = (b3 . b8) * (b3 . b7)
proof end;

theorem Th14: :: NATTRA_1:14
for b1, b2 being Category
for b3 being Functor of b1,b2
for b4 being Object of b1
for b5 being Object of b2 st b3 . (id b4) = id b5 holds
b3 . b4 = b5
proof end;

theorem Th15: :: NATTRA_1:15
for b1, b2 being Category
for b3 being Functor of b2,b1
for b4 being Object of b2 holds b3 . (id b4) = id (b3 . b4)
proof end;

theorem Th16: :: NATTRA_1:16
for b1 being Category
for b2, b3 being Object of b1 st Hom b2,b3 <> {} holds
for b4 being Morphism of b2,b3 holds (id b1) . b4 = b4
proof end;

theorem Th17: :: NATTRA_1:17
for b1 being Category
for b2, b3, b4, b5 being Object of b1 st Hom b2,b3 meets Hom b4,b5 holds
( b2 = b4 & b3 = b5 )
proof end;

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
pred c3 is_transformable_to c4 means :Def2: :: NATTRA_1:def 2
for b1 being Object of a1 holds Hom (a3 . b1),(a4 . b1) <> {} ;
reflexivity
for b1 being Functor of c1,c2
for b2 being Object of c1 holds Hom (b1 . b2),(b1 . b2) <> {}
by CAT_1:56;
end;

:: deftheorem Def2 defines is_transformable_to NATTRA_1:def 2 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 holds
( b3 is_transformable_to b4 iff for b5 being Object of b1 holds Hom (b3 . b5),(b4 . b5) <> {} );

theorem Th18: :: NATTRA_1:18
canceled;

theorem Th19: :: NATTRA_1:19
for b1, b2 being Category
for b3, b4, b5 being Functor of b1,b2 st b3 is_transformable_to b4 & b4 is_transformable_to b5 holds
b3 is_transformable_to b5
proof end;

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
assume E17: c3 is_transformable_to c4 ;
mode transformation of c3,c4 -> Function of the Objects of a1,the Morphisms of a2 means :Def3: :: NATTRA_1:def 3
for b1 being Object of a1 holds a5 . b1 is Morphism of a3 . b1,a4 . b1;
existence
ex b1 being Function of the Objects of c1,the Morphisms of c2 st
for b2 being Object of c1 holds b1 . b2 is Morphism of c3 . b2,c4 . b2
proof end;
end;

:: deftheorem Def3 defines transformation NATTRA_1:def 3 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 st b3 is_transformable_to b4 holds
for b5 being Function of the Objects of b1,the Morphisms of b2 holds
( b5 is transformation of b3,b4 iff for b6 being Object of b1 holds b5 . b6 is Morphism of b3 . b6,b4 . b6 );

definition
let c1, c2 be Category;
let c3 be Functor of c1,c2;
func id c3 -> transformation of a3,a3 means :Def4: :: NATTRA_1:def 4
for b1 being Object of a1 holds a4 . b1 = id (a3 . b1);
existence
ex b1 being transformation of c3,c3 st
for b2 being Object of c1 holds b1 . b2 = id (c3 . b2)
proof end;
uniqueness
for b1, b2 being transformation of c3,c3 st ( for b3 being Object of c1 holds b1 . b3 = id (c3 . b3) ) & ( for b3 being Object of c1 holds b2 . b3 = id (c3 . b3) ) holds
b1 = b2
proof end;
end;

:: deftheorem Def4 defines id NATTRA_1:def 4 :
for b1, b2 being Category
for b3 being Functor of b1,b2
for b4 being transformation of b3,b3 holds
( b4 = id b3 iff for b5 being Object of b1 holds b4 . b5 = id (b3 . b5) );

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
assume E19: c3 is_transformable_to c4 ;
let c5 be transformation of c3,c4;
let c6 be Object of c1;
func c5 . c6 -> Morphism of a3 . a6,a4 . a6 equals :Def5: :: NATTRA_1:def 5
a5 . a6;
coherence
c5 . c6 is Morphism of c3 . c6,c4 . c6
by E19, Def3;
end;

:: deftheorem Def5 defines . NATTRA_1:def 5 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 st b3 is_transformable_to b4 holds
for b5 being transformation of b3,b4
for b6 being Object of b1 holds b5 . b6 = b5 . b6;

definition
let c1, c2 be Category;
let c3, c4, c5 be Functor of c1,c2;
assume that
E20: c3 is_transformable_to c4 and
E21: c4 is_transformable_to c5 ;
let c6 be transformation of c3,c4;
let c7 be transformation of c4,c5;
func c7 `*` c6 -> transformation of a3,a5 means :Def6: :: NATTRA_1:def 6
for b1 being Object of a1 holds a8 . b1 = (a7 . b1) * (a6 . b1);
existence
ex b1 being transformation of c3,c5 st
for b2 being Object of c1 holds b1 . b2 = (c7 . b2) * (c6 . b2)
proof end;
uniqueness
for b1, b2 being transformation of c3,c5 st ( for b3 being Object of c1 holds b1 . b3 = (c7 . b3) * (c6 . b3) ) & ( for b3 being Object of c1 holds b2 . b3 = (c7 . b3) * (c6 . b3) ) holds
b1 = b2
proof end;
end;

:: deftheorem Def6 defines `*` NATTRA_1:def 6 :
for b1, b2 being Category
for b3, b4, b5 being Functor of b1,b2 st b3 is_transformable_to b4 & b4 is_transformable_to b5 holds
for b6 being transformation of b3,b4
for b7 being transformation of b4,b5
for b8 being transformation of b3,b5 holds
( b8 = b7 `*` b6 iff for b9 being Object of b1 holds b8 . b9 = (b7 . b9) * (b6 . b9) );

theorem Th20: :: NATTRA_1:20
for b1, b2 being Category
for b3, b4 being Functor of b2,b1 st b3 is_transformable_to b4 holds
for b5, b6 being transformation of b3,b4 st ( for b7 being Object of b2 holds b5 . b7 = b6 . b7 ) holds
b5 = b6
proof end;

theorem Th21: :: NATTRA_1:21
for b1, b2 being Category
for b3 being Functor of b2,b1
for b4 being Object of b2 holds (id b3) . b4 = id (b3 . b4)
proof end;

theorem Th22: :: NATTRA_1:22
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 st b3 is_transformable_to b4 holds
for b5 being transformation of b3,b4 holds
( (id b4) `*` b5 = b5 & b5 `*` (id b3) = b5 )
proof end;

theorem Th23: :: NATTRA_1:23
for b1, b2 being Category
for b3, b4, b5, b6 being Functor of b1,b2 st b3 is_transformable_to b4 & b4 is_transformable_to b5 & b5 is_transformable_to b6 holds
for b7 being transformation of b3,b4
for b8 being transformation of b4,b5
for b9 being transformation of b5,b6 holds (b9 `*` b8) `*` b7 = b9 `*` (b8 `*` b7)
proof end;

Lemma25: for b1, b2 being Category
for b3 being Functor of b2,b1
for b4, b5 being Object of b2 st Hom b4,b5 <> {} holds
for b6 being Morphism of b4,b5 holds ((id b3) . b5) * (b3 . b6) = (b3 . b6) * ((id b3) . b4)
proof end;

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
pred c3 is_naturally_transformable_to c4 means :Def7: :: NATTRA_1:def 7
( a3 is_transformable_to a4 & ex b1 being transformation of a3,a4 st
for b2, b3 being Object of a1 st Hom b2,b3 <> {} holds
for b4 being Morphism of b2,b3 holds (b1 . b3) * (a3 . b4) = (a4 . b4) * (b1 . b2) );
reflexivity
for b1 being Functor of c1,c2 holds
( b1 is_transformable_to b1 & ex b2 being transformation of b1,b1 st
for b3, b4 being Object of c1 st Hom b3,b4 <> {} holds
for b5 being Morphism of b3,b4 holds (b2 . b4) * (b1 . b5) = (b1 . b5) * (b2 . b3) )
proof end;
end;

:: deftheorem Def7 defines is_naturally_transformable_to NATTRA_1:def 7 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 holds
( b3 is_naturally_transformable_to b4 iff ( b3 is_transformable_to b4 & ex b5 being transformation of b3,b4 st
for b6, b7 being Object of b1 st Hom b6,b7 <> {} holds
for b8 being Morphism of b6,b7 holds (b5 . b7) * (b3 . b8) = (b4 . b8) * (b5 . b6) ) );

Lemma27: for b1, b2 being Category
for b3, b4, b5 being Functor of b2,b1 st b3 is_transformable_to b4 & b4 is_transformable_to b5 holds
for b6 being transformation of b3,b4 st ( for b7, b8 being Object of b2 st Hom b7,b8 <> {} holds
for b9 being Morphism of b7,b8 holds (b6 . b8) * (b3 . b9) = (b4 . b9) * (b6 . b7) ) holds
for b7 being transformation of b4,b5 st ( for b8, b9 being Object of b2 st Hom b8,b9 <> {} holds
for b10 being Morphism of b8,b9 holds (b7 . b9) * (b4 . b10) = (b5 . b10) * (b7 . b8) ) holds
for b8, b9 being Object of b2 st Hom b8,b9 <> {} holds
for b10 being Morphism of b8,b9 holds ((b7 `*` b6) . b9) * (b3 . b10) = (b5 . b10) * ((b7 `*` b6) . b8)
proof end;

theorem Th24: :: NATTRA_1:24
canceled;

theorem Th25: :: NATTRA_1:25
for b1, b2 being Category
for b3, b4, b5 being Functor of b1,b2 st b3 is_naturally_transformable_to b4 & b4 is_naturally_transformable_to b5 holds
b3 is_naturally_transformable_to b5
proof end;

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
assume E29: c3 is_naturally_transformable_to c4 ;
mode natural_transformation of c3,c4 -> transformation of a3,a4 means :Def8: :: NATTRA_1:def 8
for b1, b2 being Object of a1 st Hom b1,b2 <> {} holds
for b3 being Morphism of b1,b2 holds (a5 . b2) * (a3 . b3) = (a4 . b3) * (a5 . b1);
existence
ex b1 being transformation of c3,c4 st
for b2, b3 being Object of c1 st Hom b2,b3 <> {} holds
for b4 being Morphism of b2,b3 holds (b1 . b3) * (c3 . b4) = (c4 . b4) * (b1 . b2)
by E29, Def7;
end;

:: deftheorem Def8 defines natural_transformation NATTRA_1:def 8 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 st b3 is_naturally_transformable_to b4 holds
for b5 being transformation of b3,b4 holds
( b5 is natural_transformation of b3,b4 iff for b6, b7 being Object of b1 st Hom b6,b7 <> {} holds
for b8 being Morphism of b6,b7 holds (b5 . b7) * (b3 . b8) = (b4 . b8) * (b5 . b6) );

definition
let c1, c2 be Category;
let c3 be Functor of c1,c2;
redefine func id as id c3 -> natural_transformation of a3,a3;
coherence
id c3 is natural_transformation of c3,c3
proof end;
end;

definition
let c1, c2 be Category;
let c3, c4, c5 be Functor of c1,c2;
assume that
E30: c3 is_naturally_transformable_to c4 and
E31: c4 is_naturally_transformable_to c5 ;
let c6 be natural_transformation of c3,c4;
let c7 be natural_transformation of c4,c5;
func c7 `*` c6 -> natural_transformation of a3,a5 equals :Def9: :: NATTRA_1:def 9
a7 `*` a6;
coherence
c7 `*` c6 is natural_transformation of c3,c5
proof end;
end;

:: deftheorem Def9 defines `*` NATTRA_1:def 9 :
for b1, b2 being Category
for b3, b4, b5 being Functor of b1,b2 st b3 is_naturally_transformable_to b4 & b4 is_naturally_transformable_to b5 holds
for b6 being natural_transformation of b3,b4
for b7 being natural_transformation of b4,b5 holds b7 `*` b6 = b7 `*` b6;

theorem Th26: :: NATTRA_1:26
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 st b3 is_naturally_transformable_to b4 holds
for b5 being natural_transformation of b3,b4 holds
( (id b4) `*` b5 = b5 & b5 `*` (id b3) = b5 )
proof end;

theorem Th27: :: NATTRA_1:27
for b1, b2 being Category
for b3, b4, b5 being Functor of b2,b1 st b3 is_naturally_transformable_to b4 & b4 is_naturally_transformable_to b5 holds
for b6 being natural_transformation of b3,b4
for b7 being natural_transformation of b4,b5
for b8 being Object of b2 holds (b7 `*` b6) . b8 = (b7 . b8) * (b6 . b8)
proof end;

theorem Th28: :: NATTRA_1:28
for b1, b2 being Category
for b3, b4, b5, b6 being Functor of b1,b2
for b7 being natural_transformation of b3,b4
for b8 being natural_transformation of b4,b5 st b3 is_naturally_transformable_to b4 & b4 is_naturally_transformable_to b5 & b5 is_naturally_transformable_to b6 holds
for b9 being natural_transformation of b5,b6 holds (b9 `*` b8) `*` b7 = b9 `*` (b8 `*` b7)
proof end;

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
let c5 be transformation of c3,c4;
attr a5 is invertible means :Def10: :: NATTRA_1:def 10
for b1 being Object of a1 holds a5 . b1 is invertible;
end;

:: deftheorem Def10 defines invertible NATTRA_1:def 10 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2
for b5 being transformation of b3,b4 holds
( b5 is invertible iff for b6 being Object of b1 holds b5 . b6 is invertible );

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
pred c3,c4 are_naturally_equivalent means :Def11: :: NATTRA_1:def 11
( a3 is_naturally_transformable_to a4 & ex b1 being natural_transformation of a3,a4 st b1 is invertible );
reflexivity
for b1 being Functor of c1,c2 holds
( b1 is_naturally_transformable_to b1 & ex b2 being natural_transformation of b1,b1 st b2 is invertible )
proof end;
end;

:: deftheorem Def11 defines are_naturally_equivalent NATTRA_1:def 11 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 holds
( b3,b4 are_naturally_equivalent iff ( b3 is_naturally_transformable_to b4 & ex b5 being natural_transformation of b3,b4 st b5 is invertible ) );

notation
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
synonym c3 ~= c4 for c3,c4 are_naturally_equivalent ;
end;

Lemma36: for b1, b2 being Category
for b3, b4 being Functor of b1,b2
for b5 being transformation of b3,b4 st b3 is_transformable_to b4 & b5 is invertible holds
b4 is_transformable_to b3
proof end;

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
assume E37: c3 is_transformable_to c4 ;
let c5 be transformation of c3,c4;
assume E38: c5 is invertible ;
func c5 " -> transformation of a4,a3 means :Def12: :: NATTRA_1:def 12
for b1 being Object of a1 holds a6 . b1 = (a5 . b1) " ;
existence
ex b1 being transformation of c4,c3 st
for b2 being Object of c1 holds b1 . b2 = (c5 . b2) "
proof end;
uniqueness
for b1, b2 being transformation of c4,c3 st ( for b3 being Object of c1 holds b1 . b3 = (c5 . b3) " ) & ( for b3 being Object of c1 holds b2 . b3 = (c5 . b3) " ) holds
b1 = b2
proof end;
end;

:: deftheorem Def12 defines " NATTRA_1:def 12 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 st b3 is_transformable_to b4 holds
for b5 being transformation of b3,b4 st b5 is invertible holds
for b6 being transformation of b4,b3 holds
( b6 = b5 " iff for b7 being Object of b1 holds b6 . b7 = (b5 . b7) " );

E38: now
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
let c5 be natural_transformation of c3,c4;
assume that
E39: c3 is_naturally_transformable_to c4 and
E40: c5 is invertible ;
E41: c3 is_transformable_to c4 by E39, Def7;
let c6, c7 be Object of c1;
assume E42: Hom c6,c7 <> {} ;
E43: c5 . c7 is invertible by E40, Def10;
E44: c5 . c6 is invertible by E40, Def10;
E45: Hom (c3 . c6),(c3 . c7) <> {} by E42, CAT_1:126;
E46: Hom (c3 . c6),(c4 . c6) <> {} by E41, Def2;
E47: Hom (c3 . c7),(c4 . c7) <> {} by E41, Def2;
then E48: Hom (c4 . c7),(c3 . c7) <> {} by E43, CAT_1:70;
E49: Hom (c4 . c6),(c4 . c7) <> {} by E42, CAT_1:126;
E50: Hom (c4 . c6),(c3 . c6) <> {} by E44, E46, CAT_1:70;
then E51: Hom (c4 . c6),(c3 . c7) <> {} by E45, CAT_1:52;
let c8 be Morphism of c6,c7;
(c4 . c8) * (c5 . c6) = (c5 . c7) * (c3 . c8) by E39, E42, Def8;
then E52: (((c5 . c7) " ) * (c4 . c8)) * (c5 . c6) = ((c5 . c7) " ) * ((c5 . c7) * (c3 . c8)) by E46, E48, E49, CAT_1:54
.= (((c5 . c7) " ) * (c5 . c7)) * (c3 . c8) by E45, E47, E48, CAT_1:54
.= (id (c3 . c7)) * (c3 . c8) by E43, E47, CAT_1:def 14
.= c3 . c8 by E45, CAT_1:57 ;
((c5 . c7) " ) * (c4 . c8) = (((c5 . c7) " ) * (c4 . c8)) * (id (c4 . c6)) by E51, CAT_1:58
.= (((c5 . c7) " ) * (c4 . c8)) * ((c5 . c6) * ((c5 . c6) " )) by E44, E46, CAT_1:def 14
.= (c3 . c8) * ((c5 . c6) " ) by E46, E50, E51, E52, CAT_1:54 ;
hence ((c5 " ) . c7) * (c4 . c8) = (c3 . c8) * ((c5 . c6) " ) by E40, E41, Def12
.= (c3 . c8) * ((c5 " ) . c6) by E40, E41, Def12 ;

end;

Lemma39: for b1, b2 being Category
for b3, b4 being Functor of b1,b2
for b5 being natural_transformation of b3,b4 st b3 is_naturally_transformable_to b4 & b5 is invertible holds
b4 is_naturally_transformable_to b3
proof end;

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
let c5 be natural_transformation of c3,c4;
assume that
E40: c3 is_naturally_transformable_to c4 and
E41: c5 is invertible ;
func c5 " -> natural_transformation of a4,a3 equals :Def13: :: NATTRA_1:def 13
a5 " ;
coherence
c5 " is natural_transformation of c4,c3
proof end;
end;

:: deftheorem Def13 defines " NATTRA_1:def 13 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2
for b5 being natural_transformation of b3,b4 st b3 is_naturally_transformable_to b4 & b5 is invertible holds
b5 " = b5 " ;

theorem Th29: :: NATTRA_1:29
canceled;

theorem Th30: :: NATTRA_1:30
for b1, b2 being Category
for b3, b4 being Functor of b1,b2
for b5 being natural_transformation of b3,b4 st b3 is_naturally_transformable_to b4 & b5 is invertible holds
for b6 being Object of b1 holds (b5 " ) . b6 = (b5 . b6) "
proof end;

theorem Th31: :: NATTRA_1:31
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 st b3 ~= b4 holds
b4 ~= b3
proof end;

theorem Th32: :: NATTRA_1:32
for b1, b2 being Category
for b3, b4, b5 being Functor of b1,b2 st b3 ~= b4 & b4 ~= b5 holds
b3 ~= b5
proof end;

definition
let c1, c2 be Category;
let c3, c4 be Functor of c1,c2;
assume E43: c3,c4 are_naturally_equivalent ;
mode natural_equivalence of c3,c4 -> natural_transformation of a3,a4 means :Def14: :: NATTRA_1:def 14
a5 is invertible;
existence
ex b1 being natural_transformation of c3,c4 st b1 is invertible
by E43, Def11;
end;

:: deftheorem Def14 defines natural_equivalence NATTRA_1:def 14 :
for b1, b2 being Category
for b3, b4 being Functor of b1,b2 st b3,b4 are_naturally_equivalent holds
for b5 being natural_transformation of b3,b4 holds
( b5 is natural_equivalence of b3,b4 iff b5 is invertible );

theorem Th33: :: NATTRA_1:33
for b1, b2 being Category
for b3 being Functor of b1,b2 holds id b3 is natural_equivalence of b3,b3
proof end;

theorem Th34: :: NATTRA_1:34
for b1, b2 being Category
for b3, b4, b5 being Functor of b1,b2 st b3 ~= b4 & b4 ~= b5 holds
for b6 being natural_equivalence of b3,b4
for b7 being natural_equivalence of b4,b5 holds b7 `*` b6 is natural_equivalence of b3,b5
proof end;

definition
let c1, c2 be Category;
mode NatTrans-DOMAIN of c1,c2 -> non empty set means :Def15: :: NATTRA_1:def 15
for b1 being set st b1 in a3 holds
ex b2, b3 being Functor of a1,a2ex b4 being natural_transformation of b2,b3 st
( b1 = [[b2,b3],b4] & b2 is_naturally_transformable_to b3 );
existence
ex b1 being non empty set st
for b2 being set st b2 in b1 holds
ex b3, b4 being Functor of c1,c2ex b5 being natural_transformation of b3,b4 st
( b2 = [[b3,b4],b5] & b3 is_naturally_transformable_to b4 )
proof end;
end;

:: deftheorem Def15 defines NatTrans-DOMAIN NATTRA_1:def 15 :
for b1, b2 being Category
for b3 being non empty set holds
( b3 is NatTrans-DOMAIN of b1,b2 iff for b4 being set st b4 in b3 holds
ex b5, b6 being Functor of b1,b2ex b7 being natural_transformation of b5,b6 st
( b4 = [[b5,b6],b7] & b5 is_naturally_transformable_to b6 ) );

definition
let c1, c2 be Category;
func NatTrans c1,c2 -> NatTrans-DOMAIN of a1,a2 means :Def16: :: NATTRA_1:def 16
for b1 being set holds
( b1 in a3 iff ex b2, b3 being Functor of a1,a2ex b4 being natural_transformation of b2,b3 st
( b1 = [[b2,b3],b4] & b2 is_naturally_transformable_to b3 ) );
existence
ex b1 being NatTrans-DOMAIN of c1,c2 st
for b2 being set holds
( b2 in b1 iff ex b3, b4 being Functor of c1,c2ex b5 being natural_transformation of b3,b4 st
( b2 = [[b3,b4],b5] & b3 is_naturally_transformable_to b4 ) )
proof end;
uniqueness
for b1, b2 being NatTrans-DOMAIN of c1,c2 st ( for b3 being set holds
( b3 in b1 iff ex b4, b5 being Functor of c1,c2ex b6 being natural_transformation of b4,b5 st
( b3 = [[b4,b5],b6] & b4 is_naturally_transformable_to b5 ) ) ) & ( for b3 being set holds
( b3 in b2 iff ex b4, b5 being Functor of c1,c2ex b6 being natural_transformation of b4,b5 st
( b3 = [[b4,b5],b6] & b4 is_naturally_transformable_to b5 ) ) ) holds
b1 = b2
proof end;
end;

:: deftheorem Def16 defines NatTrans NATTRA_1:def 16 :
for b1, b2 being Category
for b3 being NatTrans-DOMAIN of b1,b2 holds
( b3 = NatTrans b1,b2 iff for b4 being set holds
( b4 in b3 iff ex b5, b6 being Functor of b1,b2ex b7 being natural_transformation of b5,b6 st
( b4 = [[b5,b6],b7] & b5 is_naturally_transformable_to b6 ) ) );

definition
let c1, c2, c3, c4 be non empty set ;
let c5 be Function of c1,c2;
let c6 be Function of c3,c4;
redefine pred = as c5 = c6 means :: NATTRA_1:def 17
( a1 = a3 & ( for b1 being Element of a1 holds a5 . b1 = a6 . b1 ) );
compatibility
( c5 = c6 iff ( c1 = c3 & ( for b1 being Element of c1 holds c5 . b1 = c6 . b1 ) ) )
proof end;
end;

:: deftheorem Def17 defines = NATTRA_1:def 17 :
for b1, b2, b3, b4 being non empty set
for b5 being Function of b1,b2
for b6 being Function of b3,b4 holds
( b5 = b6 iff ( b1 = b3 & ( for b7 being Element of b1 holds b5 . b7 = b6 . b7 ) ) );

theorem Th35: :: NATTRA_1:35
for b1, b2 being Category
for b3, b4 being Functor of b1,b2
for b5 being natural_transformation of b3,b4 holds
( b3 is_naturally_transformable_to b4 iff [[b3,b4],b5] in NatTrans b1,b2 )
proof end;

definition
let c1, c2 be Category;
func Functors c1,c2 -> strict Category means :Def18: :: NATTRA_1:def 18
( the Objects of a3 = Funct a1,a2 & the Morphisms of a3 = NatTrans a1,a2 & ( for b1 being Morphism of a3 holds
( dom b1 = (b1 `1 ) `1 & cod b1 = (b1 `1 ) `2 ) ) & ( for b1, b2 being Morphism of a3 st dom b2 = cod b1 holds
[b2,b1] in dom the Comp of a3 ) & ( for b1, b2 being Morphism of a3 st [b2,b1] in dom the Comp of a3 holds
ex b3, b4, b5 being Functor of a1,a2ex b6 being natural_transformation of b3,b4ex b7 being natural_transformation of b4,b5 st
( b1 = [[b3,b4],b6] & b2 = [[b4,b5],b7] & the Comp of a3 . [b2,b1] = [[b3,b5],(b7 `*` b6)] ) ) & ( for b1 being Object of a3
for b2 being Functor of a1,a2 st b2 = b1 holds
id b1 = [[b2,b2],(id b2)] ) );
existence
ex b1 being strict Category st
( the Objects of b1 = Funct c1,c2 & the Morphisms of b1 = NatTrans c1,c2 & ( for b2 being Morphism of b1 holds
( dom b2 = (b2 `1 ) `1 & cod b2 = (b2 `1 ) `2 ) ) & ( for b2, b3 being Morphism of b1 st dom b3 = cod b2 holds
[b3,b2] in dom the Comp of b1 ) & ( for b2, b3 being Morphism of b1 st [b3,b2] in dom the Comp of b1 holds
ex b4, b5, b6 being Functor of c1,c2ex b7 being natural_transformation of b4,b5ex b8 being natural_transformation of b5,b6 st
( b2 = [[b4,b5],b7] & b3 = [[b5,b6],b8] & the Comp of b1 . [b3,b2] = [[b4,b6],(b8 `*` b7)] ) ) & ( for b2 being Object of b1
for b3 being Functor of c1,c2 st b3 = b2 holds
id b2 = [[b3,b3],(id b3)] ) )
proof end;
uniqueness
for b1, b2 being strict Category st the Objects of b1 = Funct c1,c2 & the Morphisms of b1 = NatTrans c1,c2 & ( for b3 being Morphism of b1 holds
( dom b3 = (b3 `1 ) `1 & cod b3 = (b3 `1 ) `2 ) ) & ( for b3, b4 being Morphism of b1 st dom b4 = cod b3 holds
[b4,b3] in dom the Comp of b1 ) & ( for b3, b4 being Morphism of b1 st [b4,b3] in dom the Comp of b1 holds
ex b5, b6, b7 being Functor of c1,c2ex b8 being natural_transformation of b5,b6ex b9 being natural_transformation of b6,b7 st
( b3 = [[b5,b6],b8] & b4 = [[b6,b7],b9] & the Comp of b1 . [b4,b3] = [[b5,b7],(b9 `*` b8)] ) ) & ( for b3 being Object of b1
for b4 being Functor of c1,c2 st b4 = b3 holds
id b3 = [[b4,b4],(id b4)] ) & the Objects of b2 = Funct c1,c2 & the Morphisms of b2 = NatTrans c1,c2 & ( for b3 being Morphism of b2 holds
( dom b3 = (b3 `1 ) `1 & cod b3 = (b3 `1 ) `2 ) ) & ( for b3, b4 being Morphism of b2 st dom b4 = cod b3 holds
[b4,b3] in dom the Comp of b2 ) & ( for b3, b4 being Morphism of b2 st [b4,b3] in dom the Comp of b2 holds
ex b5, b6, b7 being Functor of c1,c2ex b8 being natural_transformation of b5,b6ex b9 being natural_transformation of b6,b7 st
( b3 = [[b5,b6],b8] & b4 = [[b6,b7],b9] & the Comp of b2 . [b4,b3] = [[b5,b7],(b9 `*` b8)] ) ) & ( for b3 being Object of b2
for b4 being Functor of c1,c2 st b4 = b3 holds
id b3 = [[b4,b4],(id b4)] ) holds
b1 = b2
proof end;
end;

:: deftheorem Def18 defines Functors NATTRA_1:def 18 :
for b1, b2 being Category
for b3 being strict Category holds
( b3 = Functors b1,b2 iff ( the Objects of b3 = Funct b1,b2 & the Morphisms of b3 = NatTrans b1,b2 & ( for b4 being Morphism of b3 holds
( dom b4 = (b4 `1 ) `1 & cod b4 = (b4 `1 ) `2 ) ) & ( for b4, b5 being Morphism of b3 st dom b5 = cod b4 holds
[b5,b4] in dom the Comp of b3 ) & ( for b4, b5 being Morphism of b3 st [b5,b4] in dom the Comp of b3 holds
ex b6, b7, b8 being Functor of b1,b2ex b9 being natural_transformation of b6,b7ex b10 being natural_transformation of b7,b8 st
( b4 = [[b6,b7],b9] & b5 = [[b7,b8],b10] & the Comp of b3 . [b5,b4] = [[b6,b8],(b10 `*` b9)] ) ) & ( for b4 being Object of b3
for b5 being Functor of b1,b2 st b5 = b4 holds
id b4 = [[b5,b5],(id b5)] ) ) );

theorem Th36: :: NATTRA_1:36
canceled;

theorem Th37: :: NATTRA_1:37
canceled;

theorem Th38: :: NATTRA_1:38
canceled;

theorem Th39: :: NATTRA_1:39
for b1, b2 being Category
for b3, b4 being Functor of b1,b2
for b5 being natural_transformation of b3,b4
for b6 being Morphism of (Functors b1,b2) st b6 = [[b3,b4],b5] holds
( dom b6 = b3 & cod b6 = b4 )
proof end;

theorem Th40: :: NATTRA_1:40
for b1, b2 being Category
for b3, b4 being Object of (Functors b1,b2)
for b5 being Morphism of b3,b4 st Hom b3,b4 <> {} holds
ex b6, b7 being Functor of b1,b2ex b8 being natural_transformation of b6,b7 st
( b3 = b6 & b4 = b7 & b5 = [[b6,b7],b8] )
proof end;

theorem Th41: :: NATTRA_1:41
for b1, b2 being Category
for b3, b4, b5, b6 being Functor of b1,b2
for b7 being natural_transformation of b5,b6
for b8 being natural_transformation of b3,b4
for b9, b10 being Morphism of (Functors b1,b2) st b9 = [[b5,b6],b7] & b10 = [[b3,b4],b8] holds
( [b10,b9] in dom the Comp of (Functors b1,b2) iff b6 = b3 )
proof end;

theorem Th42: :: NATTRA_1:42
for b1, b2 being Category
for b3, b4, b5 being Functor of b1,b2
for b6 being natural_transformation of b3,b4
for b7 being natural_transformation of b4,b5
for b8, b9 being Morphism of (Functors b1,b2) st b8 = [[b3,b4],b6] & b9 = [[b4,b5],b7] holds
b9 * b8 = [[b3,b5],(b7 `*` b6)]
proof end;

definition
let c1 be Category;
attr a1 is discrete means :Def19: :: NATTRA_1:def 19
for b1 being Morphism of a1 ex b2 being Object of a1 st b1 = id b2;
end;

:: deftheorem Def19 defines discrete NATTRA_1:def 19 :
for b1 being Category holds
( b1 is discrete iff for b2 being Morphism of b1 ex b3 being Object of b1 st b2 = id b3 );

registration
cluster discrete CatStr ;
existence
ex b1 being Category st b1 is discrete
proof end;
end;

theorem Th43: :: NATTRA_1:43
canceled;

theorem Th44: :: NATTRA_1:44
for b1 being discrete Category
for b2 being Object of b1 holds Hom b2,b2 = {(id b2)}
proof end;

theorem Th45: :: NATTRA_1:45
for b1 being Category holds
( b1 is discrete iff ( ( for b2 being Object of b1 ex b3 being finite set st
( b3 = Hom b2,b2 & card b3 = 1 ) ) & ( for b2, b3 being Object of b1 st b2 <> b3 holds
Hom b2,b3 = {} ) ) )
proof end;

theorem Th46: :: NATTRA_1:46
for b1, b2 being set holds 1Cat b1,b2 is discrete
proof end;

theorem Th47: :: NATTRA_1:47
for b1 being discrete Category
for b2 being Subcategory of b1 holds b2 is discrete
proof end;

theorem Th48: :: NATTRA_1:48
for b1, b2 being Category st b1 is discrete & b2 is discrete holds
[:b1,b2:] is discrete
proof end;

theorem Th49: :: NATTRA_1:49
for b1 being discrete Category
for b2 being Category
for b3, b4 being Functor of b2,b1 st b3 is_transformable_to b4 holds
b3 = b4
proof end;

theorem Th50: :: NATTRA_1:50
for b1 being discrete Category
for b2 being Category
for b3 being Functor of b2,b1
for b4 being transformation of b3,b3 holds b4 = id b3
proof end;

theorem Th51: :: NATTRA_1:51
for b1, b2 being Category st b1 is discrete holds
Functors b2,b1 is discrete
proof end;

registration
let c1 be Category;
cluster strict discrete Subcategory of a1;
existence
ex b1 being Subcategory of c1 st
( b1 is strict & b1 is discrete )
proof end;
end;

definition
let c1 be Category;
func IdCat c1 -> strict discrete Subcategory of a1 means :Def20: :: NATTRA_1:def 20
( the Objects of a2 = the Objects of a1 & the Morphisms of a2 = { (id b1) where B is Object of a1 : verum } );
existence
ex b1 being strict discrete Subcategory of c1 st
( the Objects of b1 = the Objects of c1 & the Morphisms of b1 = { (id b2) where B is Object of c1 : verum } )
proof end;
uniqueness
for b1, b2 being strict discrete Subcategory of c1 st the Objects of b1 = the Objects of c1 & the Morphisms of b1 = { (id b3) where B is Object of c1 : verum } & the Objects of b2 = the Objects of c1 & the Morphisms of b2 = { (id b3) where B is Object of c1 : verum } holds
b1 = b2
proof end;
end;

:: deftheorem Def20 defines IdCat NATTRA_1:def 20 :
for b1 being Category
for b2 being strict discrete Subcategory of b1 holds
( b2 = IdCat b1 iff ( the Objects of b2 = the Objects of b1 & the Morphisms of b2 = { (id b3) where B is Object of b1 : verum } ) );

theorem Th52: :: NATTRA_1:52
for b1 being strict Category st b1 is discrete holds
IdCat b1 = b1
proof end;

theorem Th53: :: NATTRA_1:53
for b1 being Category holds IdCat (IdCat b1) = IdCat b1 by Th52;

theorem Th54: :: NATTRA_1:54
for b1, b2 being set holds IdCat (1Cat b1,b2) = 1Cat b1,b2
proof end;

theorem Th55: :: NATTRA_1:55
for b1, b2 being Category holds IdCat [:b1,b2:] = [:(IdCat b1),(IdCat b2):]
proof end;