forked from HoTT/Coq-HoTT
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Patrick Nicodemus
committed
Mar 3, 2025
1 parent
b14f29a
commit 150c763
Showing
6 changed files
with
45 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
Require Import Basics.Overture. | ||
Require Import WildCat.Core WildCat.NatTrans WildCat.FunctorCat. | ||
|
||
Record Category := { | ||
category_carrier :> Type; | ||
isgraph_category_carrier :: IsGraph category_carrier; | ||
is01cat_category_carrier :: Is01Cat category_carrier; | ||
is2graph_category_carrier :: Is2Graph category_carrier; | ||
is1cat_category_carrier :: Is1Cat category_carrier (* This can be seen as the "mixin" in the sense of packed classes. *) | ||
}. | ||
|
||
Instance isgraph_Cat : IsGraph Category := { Hom A B := Fun11 A B }. | ||
|
||
Instance Is2GraphCategory : Is2Graph Category := fun (A B : Category) => {| | ||
Hom (F G : Fun11 A B) := NatTrans F G | ||
|}. | ||
|
||
Instance is3graph_Cat : Is3Graph Category := fun (A B : Category) => _. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
Require Import Basics.Overture. | ||
Require Import WildCat.Core WildCat.NatTrans WildCat.FunctorCat. | ||
|
||
Record Graph := { | ||
graph_carrier :> Type; | ||
isgraph_graph_carrier :: IsGraph graph_carrier | ||
}. | ||
|
||
Instance is0Graph_Graph : IsGraph Graph := { | ||
Hom A B := Fun01 A B | ||
}. | ||
|
||
Instance Is2GraphGraph : Is2Graph Graph := | ||
fun A B => {| Hom F G := Transformation (fun01_F F) (fun01_F G)|}. | ||
|
||
(** There is a (0,1)-category of graphs under composition. *) | ||
Instance is01cat_Graph : Is01Cat Graph := { | ||
Id A := {| fun01_F := idmap; fun01_is0functor := _ |}; | ||
cat_comp A B C G F := | ||
{| fun01_F := compose G F ; fun01_is0functor := _ |} | ||
}. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters