Reserved Infix"~>" (at level 90, right associativity).
Class Category := {
obj : Type;
uhom := Type : Type;
hom : obj -> obj -> uhom where"a ~> b" := (hom a b);
homset :: ∀ X Y, Setoid (X ~> Y);
id {x} : x ~> x;
compose {x y z} (f: y ~> z) (g : x ~> y) : x ~> z where"f ∘ g" := (compose f g);
compose_respects x y z :: Proper (equiv ==> equiv ==> equiv) (@compose x y z);
dom {x y} (f: x ~> y) := x;
cod {x y} (f: x ~> y) := y;
id_left {x y} (f : x ~> y) : id ∘ f ≈ f;
id_right {x y} (f : x ~> y) : f ∘ id ≈ f;
comp_assoc {x y z w} (f : z ~> w) (g : y ~> z) (h : x ~> y) :
f ∘ (g ∘ h) ≈ (f ∘ g) ∘ h;
comp_assoc_sym {x y z w} (f : z ~> w) (g : y ~> z) (h : x ~> y) :
(f ∘ g) ∘ h ≈ f ∘ (g ∘ h)
}.
DelimitScope category_scope with category. DelimitScope object_scope with object. DelimitScope morphism_scope with morphism.
GlobalProgramInstance iso_id {x : C} : x ≅ x := {
to := id;
from := id
}.
Next Obligation. nowrewrite id_left. Qed.
Next Obligation. nowrewrite id_left. Qed.
GlobalProgramDefinition iso_sym {x y : C} `(f : x ≅ y) : y ≅ x := {|
to := from f;
from := to f;
iso_to_from := iso_from_to f;
iso_from_to := iso_to_from f
|}.
GlobalProgramDefinition iso_compose {x y z : C} `(f : y ≅ z) `(g : x ≅ y) :
x ≅ z := {|
to := to f ∘ to g;
from := from g ∘ from f
|}.
Next Obligation. rewrite <- comp_assoc. rewrite (comp_assoc (to g)). rewrite iso_to_from. rewrite id_left. apply iso_to_from. Defined.
Next Obligation. rewrite <- comp_assoc. rewrite (comp_assoc (from f)). rewrite iso_from_to. rewrite id_left. apply iso_from_to. Defined.
GlobalProgramInstance isomorphism_equivalence : Equivalence Isomorphism := {
Equivalence_Reflexive := @iso_id;
Equivalence_Symmetric := @iso_sym;
Equivalence_Transitive := fun _ _ _ g f => iso_compose f g
}.
Lemma iso_compose' {x y z : C} `(f : y ≅ z) `(g : x ≅ y) : x ≅ z. Proof. rewrite g. Abort.
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.