# Diagrams, Categorical Limits, and Topoi (Part 1)

Definition. A (small) directed graph $G$ is a 3-tuple $(V,E,d)$ where $V$ and $E$ are sets and $d:E\to V\times V$. Similarly, a subgraph $A$ of $G$ is a 3-tuple $(V_A,E_A,d)$ such that $E_A$ is contained in $E$ and $V_A\times V_A\subseteq V\times V$ contains $d(E_A)$.

Definition. If $V\times V$ is replaced with $V\times V / \{(x,y)\sim (y,x)\}$, then the graph is undirected.

Throughout this post, all graphs will be small. Moreover, the first coordinate will be the starting point and the last coordinate will be the end point.

Let $V=\{A,B\}$, $E=\{f\}$, and $d:f\mapsto (A,B)$. Then the (undirected) graph can be represented by the picture
The remaining examples will be directed graphs.
In full abstraction, we cannot visual graphs, but restricting ourselves to the cardinality $2^{\aleph_0}$, it is somewhat possible.

Finite case: Let $V=\{A,B,C\}$, $E=\{f,g,h,i\}$, and $d:f\mapsto (A,B);g\mapsto (A,C); h\mapsto (B,C); i\mapsto (B,A)$. Then the graph can be represented by the picture

Slight warning: This is not a commutative diagram. $g=h\circ f$ is not defined.

$\aleph_0$ case: Let $V=\{A_i\}_{i\in\mathbb{N}}$, $E=\{f,g,h,i\}$, and $d:f\mapsto (A_1,A_2);g\mapsto (A_1,A_2); h\mapsto (A_1,A_1); i\mapsto (A_2,A_3); j\mapsto (A_4,A_5)$. Then the graph $G=(V,E,d)$ can be represented by the picture

In this case, I have illustrated the fact that vertices can be isolated in a graph as well as the fact that subgraphs can be disjoint. Indeed, consider the maps $d_i:E\to V, i=1,2$ obtained by composing $d$ with the two canonical projections; if $A\not\in d_i(E), i=1,2$, then $A$ is called isolated; if $G_1,G_2\subseteq G$ such that $V_{G_1}\cap V_{G_2}=E_{G_1}\cap E_{G_2}=\emptyset$, $G_1$ and $G_2$ are disjoint.

$2^{\aleph_0}$ boring case: Let $V=\{A_i\}_{i\in \mathbb{R}}$, $E=\{f_i\}_{i\in\mathbb{Z}}$, and $d:f_i\mapsto (A_i,A_{i+1})$. Then the graph can be represented by the picture

where the straight line is the $\{A_i\}_{i\in \mathbb{R}}$.
$2^{\aleph_0}$ exotic case: Let $V=\{A_i\}_{i\in \mathbb{C}}$, $E=\{f_i\}_{i\in\mathbb{N}\times [0,2\pi]}$, and $d:f_{(n,\theta)}\mapsto (A_{ne^{i\theta}},A_{(n+1)e^{i\theta}})$. Then the graph can be represented by the picture

where the bottom plane is $V$ and $f_i$ is a single arc in each ring, with the arc pointing outwards from $(0,0)$.

In general, there are infinitely many ways to pictorially represent a graph.

If $G=(V,E,d)$ and $G’=(V’,E’,d’)$, a morphism of graphs $\varphi:G\to G'$ is a pair $\varphi_V:V\to V'$ and $\varphi_E:E\to E'$, written $(\varphi_V,\varphi_E)$, such that the following diagram commutes:

$(\varphi_V\times \varphi_V)d=d’\varphi_E$

Proposition. The collection of graphs form a category $\operatorname{Grph}$ whose objects are graphs and arrows are morphisms of graphs.

Proof. Let $G_i=(V_i,E_i,d_i), i=1,..4$ be graphs. Observe that as sets, we have the composition

$c_V:\hom_{\operatorname{Set}}(V_1,V_2)\times \hom_{\operatorname{Set}}(V_2,V_3)\to \hom_{\operatorname{Set}}(V_1,V_3).$
$c_E:\hom_{\operatorname{Set}}(E_1,E_2)\times \hom_{\operatorname{Set}}(E_2,E_3)\to \hom_{\operatorname{Set}}(E_1,E_3).$

Moreover,

$[c_V(\phi_{V_1},\phi_{V_2}) \times c_V(\phi_{V_1},\phi_{V_2})]d_1=d_3c_E(\phi_{E_1},\phi_{E_2})$

so $c=(c_V,c_E)$ satisfies the composition axiom. Associativity is proven similarly, and for identity, take $(\operatorname{Id}_V,\operatorname{Id}_E)$ to be the set identities.

$\blacksquare$

It is clear $\operatorname{Grph}$ can be defined under any category by simply replacing $\operatorname{Sets}$ with another category.

Now any (small) category has an underlying graph (simply forget compositions and identities), so we have a forgetful functor $F_{\operatorname{Grph}}:\operatorname{Cat}\to \operatorname{Grph}$. Denote the underlying graph of a category $\operatorname{C}$ by $\operatorname{C}_{\operatorname{Grph}}$.

Definition. A diagram of shape $G$ in the category $\operatorname{C}$ is a morphism $D:G\to\operatorname{C}_{\operatorname{Grph}}$.

Now I emphasize the word shape $G$ for two reasons: First is the obvious geometric perspective when given a “nice” graph. Second is the fact that if $G\cong G'$ in $\operatorname{Grph}$, the notion of shape $G$ and shape $G'$ are equivalent. Formally,

Proposition. If $D$ is a diagram of shape $G$ in $\operatorname{C}$ and $G\cong G'$, then there exists a diagram $D'$ of shape $G'$ in $\operatorname{C}$ such that $D(G)=D'(G’)$.

Proof. The claim follows from the diagram

$\blacksquare$

Some cases to illustrate the preceding points:

Small case: Consider the category $1$ with one object $1$ and one morphism $\operatorname{Id}$. Then $1_{\operatorname{Grph}}$ is the graph

Large case: Consider the category $\operatorname{Grp}$ whose objects are groups and arrows are morphisms of groups. An example of a subgraph of $\operatorname{Grp}_{\operatorname{Grph}}$ is a sequence

$1\to A\overset{k}{\to} B\to C\to D\to 1$

Let $X$ denote this subgraph and let $G=(V,E,d)$ be a graph with $V=\{1,2\}$, $E=\{f\}$, and $d:f\mapsto (1,2)$. Define $\phi:G\to X$ by taking $1\mapsto A, 2\mapsto B, f\mapsto k$. Then $\phi$ is a morphism of graphs, hence a diagram of shape $G$ in $X$. Considering the inclusion morphisms $i:X\hookrightarrow \operatorname{Grp}_{\operatorname{Grph}}$, $i\phi$ is a diagram of shape $G$ in $\operatorname{Grp}_{\operatorname{Grph}}$.

Remark. As stated before, graphs can be pictorially represented in infinitely many different ways. For example, the category $1$ can also be represented by

$1\overset{\operatorname{Id}}{\to} 1$

or even

$1\overset{\operatorname{Id}}{\to}1\overset{\operatorname{Id}}{\to}1\overset{\operatorname{Id}}{\to}1$

Due to this degeneracy, for any category $\operatorname{C}$, one can show that if $G$ is any graph, then there is a diagram of shape $G$ in $\operatorname{C}$.

This site uses Akismet to reduce spam. Learn how your comment data is processed.