A category consists of
A class of mathematical objects (such as groups, rings or metric spaces).
For each pair of objects , a set of morphisms from to . We will write or to indicate that .
For each object , a morphism (called the identity morphism).
A composition rule for morphisms. This should define, for every pair of morphisms , a new morphism .
These must satisfy the following properties:
For every morphism , we have .
For every triple of morphisms , we have .
There is a category of groups. The objects are groups, and the morphisms are group homomorphisms. The identity morphism is just the identity function , which is a group homomorphism by a trivial argument. The composition rule is just ordinary composition of functions. For this to be valid, we need to check that the composite of any two group homomorphisms is another group homomorphism, but this is easy. Properties (e) and (f) are also straightforward.
Most of our other examples will have the same nature: the objects will be sets with some kind of added structure, and the morphisms will be functions that preserve that structure in some sense. The only point of any real content will be to check that if we compose two structure-preserving maps, then the composite also preserves structure in the same sense.
Two examples considered later will be a bit different: the category of topological spaces and homotopy classes of continuous functions, and the category of chain complexes and chain-homotopy classes of chain maps. In these examples we start with a category as in (a), and define an equivalence relation on each morphism set , and put . We then want to say that we have a new category with the same objects as and morphism sets . For this to work, we need to check that the equivalence relations are compatible with composition in an appropriate sense. See Definition 9.9 for an example of this.
Some other algebraic categories:
The category of abelian groups and group homomorphisms. In abelian groups, we will always write the group operation as addition, the identity element as and the inverse of as . Thus, the morphisms from to are functions satisfying for all . (This implies and , by standard arguments.)
The category of rings and ring homomorphisms.
The categories , and of vector spaces over , and respectively. In each case, the morphisms are maps that are linear over the relevant field.
Underlying all of these, we have the category : the objects are just sets, and the morphisms are just functions.
We can also consider subcategories defined by various finiteness conditions. For example, we have the category : the objects are finite abelian groups, and the morphisms are just group homomorphisms between finite abelian groups.
In some sense, the main project of algebraic topology is to compare these algebraic categories with various topological categories.
We have a category : the objects are metric spaces, and the morphisms are continuous maps. To validate this, we need to know that composites of continuous maps are continuous, which is Proposition 3.24 above, or [MS, page 54]. It is sometimes also useful to consider a slightly different category : the objects are again metric spaces, but the morphisms are
It is straightforward to check that if and then , so this definition does indeed give a category. Lemma 3.5 tells us that .
Similarly, there is a category whose objects are topological spaces, and whose morphisms are continuous maps.
We next need to discuss how to compare different categories. The key concept here is as follows:
Let and be categories. A functor from to consists of
A rule giving an object for every object ; and
A rule giving a morphism for each morphism
such that
For each , we have
For every pair of morphisms in , we have . In other words, the following diagram should commute:
We will sometimes write (or or or some similar notation) instead of .
For any metric space , we let denote the same set regarded as a topological space using the metric topology. If then is just a continuous map from to and so can also be regarded as an element of . We define . This gives a functor .
For any set , we have another set . We would like to make this construction into a functor . Given a morphism (i.e. a function ), we need to define a corresponding function , or in other words . Thus, given a function , a point and a number , we need to define a point . This must have the form for some and . The only element of that we can produce from these ingredients is , so we need to take . We must have , so in the case we need to take , so the simplest thing is to take in all cases. We therefore arrive at the definition , or in other words . This gives
Also, if we have functions , then
Thus, we have and . We have therefore succeeded in defining a functor.
For any abelian group we note that the subset is a subgroup of . If is a homomorphism, then for all , so , so we have a function , which is again a homomorphism. It is easy to see that and , so we have defined a functor . This satisfies and , for example. We can also define . Given a coset , we would like to define . This is well-defined, because if then , so , so . One can check that this gives a homomorphism , and that and . Thus, we have defined another functor . This satisfies and , for example.
Let be a category, and let be a morphism in . An inverse for is a morphism such that and . We say that is an isomorphism if it has an inverse. We say that and are isomorphic if there exists an isomorphism from to . We will usually write to indicate that and are isomorphic.
If has an inverse, then it is unique.
Let and be inverses for . Then
∎
Because of the lemma, we can write for the inverse of without creating any ambiguity.
In the category , the isomorphisms are just group isomorphisms as usually defined in abstract algebra. In the category , the isomorphisms are just bijections. In the categories and , the isomorphisms are homeomorphisms.
For every object , the identity morphism is an isomorphism.
If is an isomorphism, then so is .
If and are isomorphisms, then so is .
is an inverse for itself.
is an inverse for .
is an inverse for .
∎
Let , and be objects in a category .
If then
If and then .
Immediate from the proposition. ∎
Let be a functor, and let be an isomorphism in . Then the morphism is an isomorphism in , with inverse .
By the definition of an inverse, we have and . Using the functor axioms we obtain
These prove that is an inverse for , as required. ∎
Let be a functor, and let and be objects of . If in , then in .
Immediate from the proposition. ∎
We will also need a weaker concept, which is only half as good as being isomorphic.
Let and be objects in a category . We say that is a retract of if there exist morphisms with . (We make no assumption about .) Any pair with this property will be called a retraction pair for .
Let and be groups. We can define homomorphisms
by and . These satisfy , so is a retract of in .
We can define continuous maps by and . These satisfy , so is a retract of in .
Let and be nonempty finite sets with . We claim that is a retract of in the category . Indeed, we can list the elements as and with . We can then define by . In the opposite direction, we define by
We then have , as required.
We will mostly be interested in cases where we can prove that is not a retract of . The main tool for this is as follows:
Let be a category in which the objects are sets with extra structure, and the morphisms are the functions that preserve that structure. (This covers all the examples that we have discussed so far.) Let be a retraction pair in . Then is injective, and is surjective.
We can ignore the structure-preserving properties of and ; we just need to know that we have functions and satisfying for all . In particular, this shows that can be written as for some (namely ), so is surjective. Now suppose we have with . By applying to both sides we obtain , but and so we get . This proves that is injective. ∎
Let and be groups.
If is nonabelian and is abelian, then is not a retract of .
If is infinite and is finite, then is not a retract of .
If and , then is not a retract of .
Suppose that is a retraction pair. Then is injective, so is isomorphic to , which is a subgroup of . By the contrapositive, if is not isomorphic to any subgroup of , then cannot be a retract of . In case (a), every subgroup of is abelian, so cannot be isomorphic to any subgroup of . In case (b), every subgroup of is finite, so cannot be isomorphic to any subgroup of . In case (c), the group contains an element of order precisely two, but all elements of have order or , so again cannot be isomorphic to any subgroup of . ∎
Let be a functor, and let and be objects of . If is a retract of in , then is a retract of in . Thus, by the contrapositive, if is not a retract of , then cannot be a retract of .
If is a retract of , then we can choose a retraction pair with . This gives maps with , proving that is a retract of . ∎
As a basic example of how this can be used, we have the following:
Let and be topological spaces such that is finite and . Then is not a retract of .
If was a retract of , then would be a retract of , so in particular, we would have an injective function . This is impossible because . ∎