Section 1.3
Fun with diagrams
So far we have not been looking at complicated situations with many functions and sets, but once we go into serious business, it will be hard to keep track of all the sets and maps. Diagrams will make this job considerably easier and more intuitive. For instance, if we have maps $f : A \to B$, $g : B \to D$ and $h : A \to C$, $k : C \to D$, we can draw this entire data as
A maps right to B by f and down to C by h. B maps down to D by g, and C maps right to D by k. Commutativity means that g after f equals k after h.
There are two ways to get a map $A \to D$ from this diagram: $g \circ f$ and $k \circ h$. Oftentimes, these two maps will be equal, and in this case, we are going to say that this diagram commutes. In general, a diagram can be much more complicated, and we are going to say that it commutes when all possible ways of composing maps give the same map as long as they have the same domain and target.
For example, consider the following diagram:
The top row is A to B to C by a and c. The bottom row is D to E to F by f and g. Vertical maps b, d, and e connect the corresponding objects.
This diagram commutes when $f \circ b = d \circ a$ and $g \circ d = e \circ c$ and $g \circ f \circ b = g \circ d \circ a = e \circ c \circ a$. But note that the last condition is unnecessary because $f \circ b = d \circ a$ already implies $g \circ f \circ b = g \circ d \circ a$ and $g \circ d = e \circ c$ implies $g \circ d \circ a = e \circ c \circ a$. Therefore the diagram commutes if and only if the two small squares commute.
Let me now prove an interesting proposition.
Let $X$ and $Y$ be sets, and $\pi_1 : X \times Y \to X$ and $\pi_2 : X \times Y \to Y$ be the projection maps. Let $W$ be an arbitrary set and $f : W \to X$ and $g : W \to Y$ be arbitrary maps. Then there exists a unique map $h : W \to X \times Y$ such that $f = \pi_1 \circ h$ and $g = \pi_2 \circ h$, i.e., the following diagram commutes:
W maps by a unique dashed arrow h to X times Y. Composing h with projections pi one and pi two gives the maps f from W to X and g from W to Y.
We first prove existence. Consider the map
$$ h : W \to X \times Y; \quad w \mapsto (f(w), g(w)). $$
Then $\pi_1(h(w)) = \pi_1((f(w), g(w))) = f(w)$ means that $f = \pi_1 \circ h$ and $\pi_2(h(w)) = \pi_2((f(w), g(w))) = g(w)$ means that $g = \pi_2 \circ h$. That is, this $h$ satisfies the condition.
On the other hand, for $h$ to satisfy this condition, $h$ has to be precisely this map. The condition $\pi_1 \circ h = f$ means that the first component of $h(w)$ is $f(w)$, and the other condition $\pi_2 \circ h = g$ means that the second component of $h(w)$ is $g(w)$. Therefore if $h$ satisfies the condition, it needs to send $w$ to $h(w) = (f(w), g(w))$. This shows uniqueness.
Such a property is called a universal property. It gives a universal characterization of this product $X \times Y$. Suppose there is another set $(X \times Y)^\prime$ with maps $\pi_1^\prime : (X \times Y)^\prime \to X$ and $\pi_2^\prime : (X \times Y)^\prime \to Y$ satisfying the same property: for each $f : W \to X$ and $g : W \to Y$ there exists a unique $h : W \to (X \times Y)^\prime$ such that $f = \pi_1^\prime \circ h$ and $g = \pi_2^\prime \circ h$. If we apply this property to $W = X \times Y$ and $f = \pi_1$, $g = \pi_2$, then we get a unique map $\psi : X \times Y \to (X \times Y)^\prime$ such that $\pi_1 = \pi_1^\prime \circ \psi$ and $\pi_2 = \pi_2^\prime \circ \psi$. But if we apply Proposition 1.3.1 to $W = (X \times Y)^\prime$ and $f = \pi_1^\prime$ and $g = \pi_2^\prime$ then we get a unique map $\varphi : (X \times Y)^\prime \to X \times Y$ such that $\pi_1^\prime = \pi_1 \circ \varphi$ and $\pi_2^\prime = \pi_2 \circ \varphi$.
One triangle uses a map psi from X times Y to a second product, while the other uses a map phi in the reverse direction. Both maps preserve the projections to X and Y.
So we have canonically obtained maps $\varphi$ and $\psi$ between $X \times Y$ and $(X \times Y)^\prime$. But I further claim that these maps are inverses to each other, and hence bijections. In view of the remark after Exercise 1.1.L, we only need to show that $\psi \circ \varphi = \id_{X \times Y}$ and $\varphi \circ \psi = \id_{(X \times Y)^\prime}$. Here, we are going to use the uniqueness part of the property. Note that the two diagrams
The first diagram shows X times Y mapping through the second product and back by psi and phi. The second replaces that composite by the identity on X times Y. Both preserve projections to X and Y.
are commutative. By the uniqueness part of Proposition 1.3.1, applied to $W = X \times Y$ and $f = \pi_1$, $g = \pi_2$, we conclude that $\varphi \circ \psi = \id_{X \times Y}$. By a similar argument, but this time applying the property for $(X \times Y)^\prime$, we also see that $\psi \circ \varphi = \id_{(X \times Y)^\prime}$. So we have shown, by just playing around with diagrams, that the two sets $(X \times Y)^\prime$ and $X \times Y$ are related by a unique bijection that commutes with their projection maps. Maybe it seems rather foolish to make this complicated argument, but again, we will revisit this idea as we proceed. The power of the argument shines when there is too much structure in the objects we are studying, and so constructing invertible maps between the objects is too complicated.
It is now time for you to do something similar. The coproduct, or disjoint union, also has a universal property. Surprisingly, you just reverse all the arrows!
Show the following universal property for the coproduct: for arbitrary maps $f : X \to W$ and $g : Y \to W$, there exists a unique map $h : X \amalg Y \to W$ such that $f = h \circ \iota_1$ and $g = h \circ \iota_2$.
X and Y inject into their disjoint union. A unique dashed map h goes from the disjoint union to W, and its composites with the injections are f and g.
Again, you can use the same argument to show that this property determines $X \amalg Y$ up to invertible maps. Products and coproducts can be generalized to limits and colimits, but we won't talk about this. Look them up if you're interested.
Fix sets $A, B, C$ and maps $\alpha : A \to C$ and $\beta : B \to C$. Construct a set $P$ along with maps $\pi_1 : P \to A$ and $\pi_2 : P \to B$ that satisfy the following property: for arbitrary maps $f : W \to A$ and $g : W \to B$ satisfying $\alpha \circ f = \beta \circ g$, there exists a unique map $h : W \to P$ such that $f = \pi_1 \circ h$ and $g = \pi_2 \circ h$.
P maps to A and B by pi one and pi two, and A and B map to C by alpha and beta. For compatible maps f and g from W, a unique dashed h maps W to P.
(This set $P$ is called the fiber product of $A$ and $B$ over $C$.)