Categories of graphs - #387
Open
ScriptRaccoon wants to merge 8 commits into
Open
ScriptRaccoon wants to merge 8 commits into
ScriptRaccoon wants to merge 8 commits into
Conversation
…on, aka undirected graphs
…ce this seems to be more standard
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This PR renames some existing categories of graphs, improves the associated terminology, and adds several new ones.
Renamings
The category DiGraph (from #372) is renamed to Quiv, and accodingly, directed graphs are renamed to quivers, aka directed pseudographs. This is much more precise and also a prerequisite for adding more special categories of graphs.
In other words, directed graphs are not allowed to have multiple edges. The description of Bin (from #372) has been changed accordingly. Its objects may be identified with directed graphs.
Conventions
Unfortunately, graph theory has lots of different conventions even for the most basic notions: The term "directed graph" usually allows loops, but the term "graph" usually does not, namely when it refers to "undirected graph", but every book does it differently; category theorists even tend to write "directed graph" for "quiver"; the term "simple graph" has no agreed-upon definition; many graph theorists assume graphs to be finite and/or non-empty, etc. See also nLab.
To prevent any confusion, the categories of graphs introduced in this PR are focussing on their specific models: sets equipped with a relation of a specific type. For example, the objects of Bin are not primarily interpreted as directed graphs. They are just pairs (X,R), where X is a set and R is a binary relation on X. The proofs of the categorical properties are actually much simpler in this language.
To highlight the graph-theoretic interpretations, though, structures now support an
alternative_notationfield. For example, DiGraph is an alternative notation for Bin, and Graph is an alternative notation for Binsymm,irr. It is displayed in the summary on the structure detail page.Sets equipped with an irreflexive binary relation ("directed graphs without loops")
This PR adds the category of sets equipped with an irreflexive binary relation. These model directed graphs without loops, but as mentioned, the proofs are mostly using the language of relations. All properties have been decided.
Even though this was not the initial objective, this category witnesses lots of new combinations, thus contributing to this milestone.
Sets equipped with a symmetric irreflexive binary relation ("undirected graphs")
This PR adds the category of sets equipped with a symmetric irreflexive binary relation. These model undirected graphs (where loops are not allowed, which seems to be more common in the literature, the opposite as for directed graphs!), but as mentioned, the proofs are mostly using the language of relations. All properties have been decided.
Actually, the (currently recorded) properties are exactly the same as for the irreflexive relations, and the proofs are very similar. In a comment I give a proof why the categories are not equivalent.
TODOS