Hello again! Last time I got to talking about these mathematical things called “categories.” If you’ve ever taken a class in higher math, whatever that means, you should know by now that whenever we define a new mathematical object, the next step is to define what it means to talk about “functions” between them. In abstract algebra, these are our “- homomorphisms;” in topology, our continuous functions, etc. You get the idea. What would it mean to then talk about a “structure-preserving function” between two categories, say C and D? Remember, we have to deal with the objects AND the morphisms in both categories. A “function” from C to D should therefore send objects of C to objects of D, and morphisms in C to those in D. Obviously, these “functions” of objects and arrows can’t be completely independent of each other. If they’re going to be useful in any way (i.e. preserve stuff like function composition and things like the identity map).
Cutting to the chase, these categorical functions are called functors. You’ve actually probably seen these before (if you’re a math/ physics major/ person who has played with abstract algebra). Let’s play around in groups (i.e. Grp). Recall that a group is a set with a certain operation defined on it, and that group homomorphisms are set functions that respect the group operations of the domain and codomain. Thus for each group , we can associate the set which is just the underlying set of . Similarly, we can associate to every group homomorphism the set function . For example, if we take (technically I should write these as cosets, but it’s all the same up to isomorphism anyway), the cyclic group of order 3, Then . Clearly, if and are two group homomorphisms, it follows that , so that respects “compositions of arrows.” Also, remember those identity maps for every object? If is any group and the identity homomorphism, , so that respects the identity map. Thus is a pretty convenient thing.
Now specifically, a (covariant) functor associates to every object of C an object of D, and to every morphism of C a morphism of D. Furthermore, we need to have for every pair of composable morphism and of C, . Lastly, for every object in we have . We say that is contravariant if (for the same and in the last sentence) .
Sooo now that we have this definition, it’s immediate that the “function” is a covariant functor, which is called the underlying set functor or the forgetful functor (which is a much cooler name, let’s be honest). One can, of course, do the same thing for the category of rings, of topological spaces, etc.
Some other interesting examples are
- The fundamental group functor that sends each pointed topological space to its fundamental group . If is a continuous (basepoint preserving) function, then is just the pushfoward map, i.e. it sends loops in based at to loops in with basepoint .
- The dual vector space functor that sends each vector space (over some field to its algebraic dual . If is a linear transformation, then is the linear transformation that sends each functional to .
You can even compose functors, if the source/ target categories match up. As an example, if is the dual space functor from above, the functor sends each vector space to its double dual.
As mathematicians are wont to do, whenever we define some kind of mathematical object, the next step is (just about always) to define some concept of morphisms between them. E.g. groups and group homorphisms, smooth manifolds and smooth maps, topological spaces and continuous functions, etc. So now suppose we have two functors between two categories C and D. We say that (always use the squiggle arrow, it’s much cooler) is a natural transformation if for every object in Ob(C) there is a function such that for any morphism in C,
This is best shown with a commutative diagram (I guess I’ll have to do a post on those at some point too…). Those maps are called the components of the natural transformation. If all the are isomorphisms, then we say that $\latex \eta$ is a natural isomorphism.
So I feel obliged to make a quick remark here. People often say that abstract algebra (and category theory) are especially hard because there are just sooo many definitions to remember. This is in fact the case. Suck it up. Reading a sophisticated piece of work requires a large vocabulary, regardless of the discipline.
If you think about it, for any category C, there is an identity functor that just sends every object to itself and every morphism to itself. Usually, people just write this as or as .
Ever heard that any (finite dimensional) vector space is naturally isomorphic to its double dual? What’s really going on here is that there is a natural isomorphism of functors on the full subcategory (of all vector spaces over a field F) of finite dimensional vector spaces over that field. Here, the components of the natural transformation for any vector space , is that linear transformation that sends (where ) is a linear functional). Just a bit of works shows that this is actually an isomorphism.
Stepping up the abstraction (again):
So we’ve defined functors, natural transformations, and categories. We can actually go pretty meta and define categories like “the category of (small) categories” (I’ll define small at some other time; it’s a technical condition that let’s us get around things like Russell’s Paradox), and things like “the category of functors between two categories, functors which are paired in a really useful way (an adjunction), etc. There’s a ton to explore.