# How lucky is it that direct limits of algebras are algebras on the direct limit of the underlying sets?

One can describe direct and inverse limits of sets (which correspond respectively to colimits and limits of a certain functor, $I\to Set$, $I^{op}\to Set$ respectively, where $I$ is a directed partially ordered set).

But we also want to describe those limits for algebras, such as groups, rings, modules etc.

For these algebras, the forgetful functor $U: \mathcal{C}\to Set$ ($\mathcal{C} = \mathbf{Grp}, \mathbf{Rng}, R-\mathbf{Mod}$, etc.) is right-adjoint to the "free-object" functor, and so naturally it commutes with limits, in particular the underlying set of a profuct of algebras is the product of the underlying sets, the terminal object (when it exists) has a singleton as underlying set, etc. And for inverse limits, it is also normal that the underlying set of the inverse limit of a system of algebras is the inverse limit of the underlying sets.

But $U$ has in general no right-adjoint and so isn't left adjoint; so there's no reason to expect that it'd commute with colimits. In fact, very often, it doesn't : in $\mathbf{Grp}$ the coproduct is the free product, in $R-\mathbf{Mod}$, it's the product, etc. And sometimes, colimits don't even exist (while they do in $Set$) : coproducts sometimes don't exist. (EDIT: As pointed out in the comments, this last remark is actually wrong; varieties of algebras are cocomplete)

However, direct limits (which are actually colimits, as I already mentioned) always exist in varieties of algebras which are the "natural" categories of algebras, and in these, $U$ commutes with said direct limits (see Grätzer, Universal Algebra for instance, for a treatment of direct and inverse limits), which feels like it's just a lucky thing.

But how lucky is it ? Is there a more general phenomenon that I'm not seeing that makes this happen or is it just "$U$ commutes with direct limits" ? Is there a more general class of colimits that are preserved by $U$ ?

• Actually, varieties of algebras are cocomplete (i.e. they have all small colimits), even though $U$ does not necessarily preserve them. – Arnaud D. Aug 8 '17 at 13:10
• @ArnaudD. My bad, I didn't know that. Could you provide a link or a reference ? – Max Aug 8 '17 at 13:10
• This should be helpful. – user60589 Aug 8 '17 at 15:43
• @user60589 : I barely know monads, but I know they can serve as a way to categorify universal algebra. Is this the case ? Can one use the answer provided there to answer my question ? – Max Aug 8 '17 at 16:15
• ArnaudD. : nevermind, I managed to prove it (in a nonconstructive manner, using other posts' mentioning Freyd's criterion for representability – Max Aug 8 '17 at 18:09

If you have an adjunction where $F\colon \mathcal{C} \to \mathcal{D}$ is left adjoint to $U$, then $U\circ F$ is an monad. And the category of algebras over this monad is equivalent to $\mathcal{D}$.
If the monad $U\circ F$ preseves certain kind of colimits, then $U$ also does.
So in your case the monad would be the free functor, like free group, free $R$-module. So you just need to check that the free group functor commutes with certain colimits on the level of sets. (I.e. for groups: the colimit of sets over a poset $I$ is the same as the colimit of sets words in these sets over $I$.
• You second sentence is wrong : there always is a functor $\mathcal D \to \operatorname{Alg}(UF)$ but it is not always an equivalence; when it is we say that $U$ is monadic and there is a useful criterion that allows us to detect monadicity (it is called Beck monadicity theorem). If your claim was true, every group would be free, every ring would be free, every module would be free, etc. – Pece Aug 10 '17 at 13:00