-
Notifications
You must be signed in to change notification settings - Fork 58
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make pointed-set categories and schemas actually pointed #857
Open
KevinDCarlson
wants to merge
1
commit into
main
Choose a base branch
from
ptSetToPtd
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+39
−22
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ export ThCategory, FreeCategory, Ob, Hom, dom, codom, id, compose, ⋅, | |
ThCopresheaf, FreeCopresheaf, El, ElExpr, ob, act, | ||
ThPresheaf, FreePresheaf, coact, | ||
ThMCategory, FreeMCategory, Tight, reflexive, transitive, | ||
ThPointedSetCategory, FreePointedSetCategory, zeromap | ||
ThPointedCategory, FreePointedCategory, zeromap, ZeroOb | ||
|
||
import Base: inv, show | ||
|
||
|
@@ -200,21 +200,27 @@ abstract type TightExpr{T} <: GATExpr{T} end | |
end | ||
|
||
""" | ||
Theory of a pointed set-enriched category. | ||
We axiomatize a category equipped with zero morphisms. | ||
Theory of a pointed category. | ||
We axiomatize a category equipped with a zero object and zero morphisms. | ||
At the moment, the zero object is technically only required to be | ||
a weak zero object; we don't ban nonzero maps to and from it. | ||
|
||
A functor from an ordinary category into a freely generated | ||
pointed-set enriched category, | ||
equivalently, a pointed-set enriched category in which no two nonzero maps | ||
pointed category, | ||
equivalently, a pointed category in which no two nonzero maps | ||
compose to a zero map, is a good notion | ||
of a functor that's total on objects and partial on morphisms. | ||
of a partial functor. | ||
""" | ||
@theory ThPointedSetCategory{Ob,Hom} <: ThCategory{Ob,Hom} begin | ||
@theory ThPointedCategory{Ob,Hom} <: ThCategory{Ob,Hom} begin | ||
ZeroOb()::Ob | ||
zeromap(A,B)::Hom(A,B)⊣(A::Ob,B::Ob) | ||
compose(zeromap(A,B),f::(B→C))==zeromap(A,C)⊣(A::Ob,B::Ob,C::Ob) | ||
compose(g::(A→B),zeromap(A,B))==zeromap(A,C)⊣(A::Ob,B::Ob,C::Ob) | ||
|
||
#f == g ⊣ (A::Ob,f::Hom(A,ZeroOb()),g::Hom(A,ZeroOb())) | ||
#f == g ⊣ (B::Ob,f::Hom(ZeroOb(),B),g::Hom(ZeroOb(),B)) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why have commented out axioms? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Documentation on your documentation. |
||
end | ||
|
||
@syntax FreePointedSetCategory{ObExpr,HomExpr} ThPointedSetCategory begin | ||
@syntax FreePointedCategory{ObExpr,HomExpr} ThPointedCategory begin | ||
compose(f::Hom,g::Hom) = associate_unit(normalize_zero(new(f,g; strict=true)), id) | ||
end |
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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Our convention for term constructors in
Catlab.Theories
is that they are lowercase.