# How to read commutative diagrams

In algebra, we often consider multiple algebraic objects and structure-preserving maps between them at once. After a while, having to write out something like this gets quite cumbersome:

Let and be groups and a group homomorphism. Let be the canonical quotient homomorphism, so that maps each to the coset . There exists a unique injective group homomorphism such that .

With the language of *diagrams*, however, we can write the above as
follows:

Our goal in this post is to introduce this language, focusing largely on
*commutative* diagrams.

## 1. Arrows

The simplest diagram is of the form

which is just another way of writing . In addition, we
stipulate that
be *structure-preserving*. If
and are
groups, then
is assumed to be a group homomorphism. If and are
vector spaces over the same
field , then is assumed to be a -linear transform.
If and are metric
spaces (or topological
spaces), then is assumed to be a continuous function.

If
and carry different structures, then we think of as a
function between sets, unless otherwise specified. In other words, we
*forget* the extraneous structures of both and and
simply consider them as sets, on which “structure-preserving” maps are
simply functions. For example, if is a group and a
vector space, then the above diagram merely implies that is a
function from to .

Sometimes, and might carry common structures. For example, we assume that is a group and is a vector space and write

in the category of groups.

Here we take to be a function from to such that for all . This is because the vector space can also be thought of as an abelian group with respect to the vector addition operation. Once we consider both and as groups, then ought to be a group homomorphism as per the stipulation in the previous paragraph, which corresponds precisely to the assumption we have just made.

The composition of two structure preserving maps and is denoted as follows:

If we want to label the composition in the diagram as well, then we can draw an extra arrow:

Note the order of writing. To denote , we must write
in the first arrow, as means
*input** to , and then input the output to . *The
orientation of the arrows does not matter, so long as the labels are
written down in the correct order. For example, the above diagram can
also be written as follows:

We stress that we want *every* arrow to be structure-preserving.
Fortunately, most classes of structure-preserving maps that we care
about in mathematics behave nicely under function composition. The
composition of two group homomorphisms is a group homomorphism; the
composition of two linear transformations is a linear transformation;
the composition of two continuous functions is a continuous function.

We
conclude this section by introducing three particular kind of arrows.
The *hook-arrow* indicates that the
structure-preserving map in question is injective, the *two-headed
arrow * indicates that the structure-preserving
map in question is surjective, and indicates
that the structure-preserving map is an
isomorphism. (Formally,
and correspond to
mono and
epi, respectively, but you
needn’t worry about these until you take a graduate course in algebra or
topology.) of For example, if are groups, then the diagram

indicates that is an injective group homomorphism, is a surjective group homomorphism, and is a group isomorphism. Using these arrows is not mandatory: we indicate the extra properties of mappings only when the additional information serves a purpose.

## 2. Commutative Diagrams

What if we have multiple arrows on the same algebraic object? As a motivation, we recall the following result from class:

First isomorphism theorem for groups. Let and be groups and a group homomorphism. Let be thecanonical quotient homomorphism, so that maps each to the coset . There exists a unique injective group homomorphism such that .

A diagrammatic representation of the above statement is as follows; note the arrows that indicate the surjectivity of and the injectivity of , respectively:

An important feature of the above diagram is that there are two way to get from to by following the arrows: and . Since the first isomorphism theorem establishes that , both directions yield the same composite map. Indeed, if we pick , then following the first arrow yields , and following the second sequence of arrows yields ; both are the same element of .

A diagram is said
to be *commutative* if all sequences of arrows from one algebraic object
to another algebraic object yield the same composite map.

We note that the above diagram says nothing about the uniqueness of . To remedy this, we modify the diagram as follows:

The dashed arrow

indicates that is the *unique*
structure-preserving map that makes the diagram commute, given all the
other arrows in the diagram. Indeed, the first isomorphism theorem
states that, given two group homomorphisms and
, there exists a unique group
homomorphism such that
, viz., the diagram commutes.

Important: the arrow

does not mean that is the unique injective structure-preserving map that makes the diagram commute; it indicates that is the unique structure-preserving map that (1) makes the diagram commute and (2) also happens to be injective.

Just to drive home the point, here is an extension of the first isomorphism theorem for groups:

Universal property of quotient maps.Let and be groups, a group homomorphism, and a normal subgroup of such that . There exists a unique group homomorphism such that . In other words, is the unique structure-preserving map that makes the following diagram commute:Yet another way of describing the situation is to say that

factors through. We also remark that is injective if and only if .

Note that the above diagram is nearly identical to the diagram for the first isomorphism theorem, except that injectivity is now dropped. Indeed, the first isomorphism theorem is a special case of the universal property of quotient maps.

Exercise.The universal property of quotient maps is extremely general. If you are familiar with the theory of quotient vector spaces, then try to formulate a similar universal property for this context. Try also in the context of quotient sets; here you have to translate the kernel condition into something else, as functions between sets do not have kernels. (See my blog post on naïve set theory for the answer.) Once you figure out a formulation for quotient sets, try writing one down for quotient topological spaces.

You might think after reading the above exercise that diagrams carry a
deep meaning, but let me assure you that **they do not**. While it is
incredible that many results in different fields of mathematics take the
same *shape*, the magical nature lies in mathematics itself, not the
diagrams. The diagrams are just a language, part of what is
affectionately known as *abstract
nonsense*.

## 3. Application: Free Vector Spaces

To illustrate the utility of commutative diagrams, we consider a
linear-algebraic example. Recall that a *basis* of a vector space
(over a field ) is a collection of vectors such that every vector in is a
finite -linear combination of vectors in .
This suggests that we should be able to *create* a vector space out of
any nonempty set by defining
“finite linear combinations” of the elements of . Taking a finite
linear combination of elements of over a field is
equivalent to assigning scalars from to finitely many elements
of and declaring all other elements of to be zero. In
other words:

Let be a field and a nonempty set. The

free-vector space overis the set of all functions such that the setis finite. The vector addition and scalar multiplication are defined as follows:

and for all .

We write to denote the free -vector space over .

As a simple example, we take the set and consider the free -vector space . Then is simply the set of functions that assign a real number to “-axis” and another real number to “-axis”. In other words, ought to be linear isomorphic to . And this is true. We define two maps by setting

and

and define a linear transformation by setting . It is not hard to check that is a bijective linear transformation, whence .

We now recall from linear algebra that
verifying a property of a linear transformation often amounts to
checking it on the basis vectors. Indeed, even the construction of a
linear transformation can be done this way. Let and be
vector spaces over a field and let be a basis of . A function
can be *linearly
extended* to a linear transformation by declaring that

whenever is a finite linear combination of the basis elements . We abstract this property as follows:

Universal property of free vector spaces.Let be a field and be a nonempty set. Define thecanonical injection mapby settingGiven a function into a vector space over , there exists a unique linear transformation such that . In other words, is the unique linear transformation that makes the following diagram commute:

Yet another way of describing the situation is to say that

factors through.

**Proof.** By definition, is a basis of
. We define a function by setting . We now take
to be a linear extension of , whence the commutativity of
the diagram follows at once.

Another intuitive fact from linear algebra is that a function that maps basis elements to basis elements can also be linearly extended to a linear transformation. This can be abstracted as follows:

Universal property of free vector spaces II.Let be a field and and be nonempty sets. Given a function , there is a unique linear transformation that makes the following diagram commute:In other words, is the unique linear transformation such that .

The statement * is the unique linear transformation such that
* does not make it
clear how the above statement is an abstraction of the property we have
discussed. The diagram, however, suggests the following: when we think
of and as basis elements of and
, then we can extend to construct
.

More importantly, it is not clear how such a statement should be proved at first sight. With the aid of commutative diagrams, however, we can write down a slick proof.

**Proof. **Consider first the following
diagram, without the map that we wish to construct:

The composite map is a map from the *set*
into the *vector space* . In particular,
the following diagram commutes:

Let’s just focus on the top half of the diagram for now:

By the universal property of free vector spaces, there exists a unique linear transformation such that the following diagram commutes:

Now, let’s fill in the rest of the diagram:

The bottom half commutes, and the top half commutes, and so the whole diagram commutes. (Check this if you’re not sure.) Moreover, the uniqueness of depends on , which, in turn, is determined uniquely by and . Therefore, given , , and , we have constructed a unique linear transformation such that the following diagram commutes:

We have obtained the final diagram by simply dropping the auxiliary diagonal arrow.

Note that the meat of the proof is contained in one diagram:

Even though we have written out the proof in detail, we didn’t have to: the whole proof is contained in this one diagram.

Once you get
comfortable with summarizing proofs with diagrams, you will be ready to
tackle *proofs by diagram
chasing*,
which is a general technique in algebra and topology that renders many
lengthy construction arguments completely trivial.

*Thanks to
higgsss for
corrections!*