This entry is about the notion of monad in category theory and categorical algebra. For other notions see monad (disambiguation).
internalization and categorical algebra
algebra object (associative, Lie, …)
Definitions
Transfors between 2-categories
Morphisms in 2-categories
Structures in 2-categories
Limits in 2-categories
Structures on 2-categories
A monad is a structure that is a lot like a monoid, but that lives in a bicategory rather than a monoidal category. In other words, the concept of a monad is a vertical categorification of that of a monoid.
Monads are among the most pervasive structures in category theory and its applications (notably to categorical algebra). For their applications to computer science, see monads in computer science.
Many of these applications use monads in the bicategory Cat, which is called a monad on a category. These are central to the category-theoretic account of universal algebra, as well as underlying the theory of simplicial objects and thus, via the Dold-Kan correspondence, much of homological algebra.
A monad in a bicategory is given by
an object , together with
an endomorphism , and
such that the diagrams
commute (where certain coherence isomorphisms have been omitted).
The name “monad” and the terms “unit”, “multiplication” and “associativity” bear a clear analogy with monoids (but see also at monad (disambiguation)). Indeed, one can define a monad on an object of a bicategory as just a monoid object in the endomorphism category . Alternatively, monads can be taken as more fundamental, and a monoid in a monoidal category can be defined as a monad in , the one-object bicategory corresponding to .
A third and somewhat less obvious definition says that a monad in is a lax 2-functor from the terminal bicategory to : the unique object of is sent to the object , the morphism becomes , and and arise from the coherent 2-cells expressing lax functoriality. This in turn is equivalent to saying that a monad is a category enriched in a bicategory with a single object and single morphism. Among higher-category theorists, it’s tempting to suggest that this is the most fundamental definition, and the most basic reason for the ubiquity and importance of monads. Regardless of this, however, the earlier more elementary definitions are both practically and pedagogically essential.
Finally, a monad can be defined in terms of the “Kleisli operation” taking any map to a map ; see extension system.
We can picture a monad in as an image of the third oriental in . See the remarks at monoidal category.
The data of and axioms for a monad can be expressed graphically as string diagrams. Writing for the monad in question (this notation being the standard one when ), these data can be represented as
Thanks to the distinctive shapes, one can usually omit the labels:
The axioms then appear as:
Monads in are sometimes, mostly in older literature, also called triples (alluding to the triple of data ), following Eilenberg and Moore. In even older literature, they are also referred to as standard constructions, the original term used by Godement when he introduced the idea, or fundamental constructions. For terminological remarks by Ross Street see category-list here.
Given the equivalence between monads in and lax functors it is straightforward to define the bicategory of monads in to be the lax functor category , which consists of lax functors, lax transformations and modifications.
Spelling this out, we see that an object of is a monad in . A morphism of monads is given by 1-cell together with a 2-cell satisfying
Finally, a 2-cell is given by a 2-cell satisfying
Given that a monad in a bicategory is nothing but a monoid object in a hom-category , it is natural to consider a module over this monoid: a module for a monad. This notion of module is more general than a module in a monoidal category, however, since it need not live in but can be in (for left modules) or (for right modules).
In a Cat-like bicategory, left modules over a monad are usually known as algebras over the monad. This terminology is confusing from the point of view of monads as monoids, but is justified because in Cat itself, such algebras with domain 1 are just algebras for a monad in the classical sense. Such algebras are a powerful tool to encode general algebraic structures; this is the topic of universal algebra. The algebras over a monad form its Eilenberg-Moore category, which is characterized by a universal property.
Some monads arise from operads, in which case algebras for the monad are the same as algebras for the operad. A Lawvere theory is another special sort of monad in .
Every adjunction induces a monad and a comonad . There is in general more than one adjunction which gives rise to a given monad this way, in fact there is a category of adjunctions for a given monad. An adjunction inducing a monad is called a resolution of . The initial object in that category is the adjunction over the Kleisli category of the monad and the terminal object is that over the Eilenberg-Moore category of algebras. (e.g. Borceux, vol. 2, prop. 4.2.2) The latter is called the monadic adjunction.
Moreover, passing from adjunctions to monads and back to their monadic adjunctions constitutes itself an adjunction between adjunctions and monads, called the semantics-structure adjunction.
Many of these monads also have standard usages as monads in computer science.
The free-forgetful adjunction between pointed sets and sets induces an endofunctor which adds a new disjoint point. This is called the maybe monad in computer science.
The free-forgetful adjunction between monoids and sets induces an endofunctor defined by
giving the free monoid monad. This also goes by the name list monad or Kleene-Star? in computer science. The components of the unit give inclusions sending each element of to the corresponding singleton list. The components of the multiplication are the concatenation functions, sending a list of lists to the corresponding list (Known as flattening in computer science). This monad can be defined in any monoidal category with coproducts that distribute over the monoidal product.
For a fixed set of “states” , the ()-adjunction induces a monad on called the state monad. This is a commonly used monad in computer science. In functional programming languages such as Haskell, states can be used to model “side effects” of computations.
The contravariant power set-functor is its own right adjoint, giving . Note that inducing a double power set monad taking a set to . The components of the unit are the principal ultrafilter functions which send an element to the set of subsets of that contain . The components of the multiplication is the inverse image function for the map ; which can be painfully stated as: the function taking a set of sets of sets of subsets to the set of subsets of with the property that one of the sets of sets of subsets is the set of all sets of subsets of that include that particular subset as an element.
Replacing the two element power object with any other set gives similar monads. In computer science contexts these are known as continuation monads. This construction can also be generalised for any other bi-closed monoidal category. For example there is a similar double dual monad on .
function monad (also “reader monad”, cf. coreader comonad)
The free-forgetful adjunction between sets and the category of -modules. This induces the free -module monad . The free abelian group monad and free vector space monad are special cases.
The free-forgetful adjunction between sets and the category of groups gives the free group monad that sends to the set of finite words in the letters together with inverses .
There is a forgetful functor taking a topological space to its underlying set. It is right adjoint to the discrete space functor taking a set to its discrete topology. There is also an adjoint pair between the category of compact Hausdorff topological spaces and the category of topological spaces, where is the Stone-Cech compactification. The composites of these two adjoint pairs gives a monad sending a set to its underlying set of the Stone-Cech compactification of its discrete space. It is also known as the ultrafilter monad as can be thought of as the functor taking a set to its set of ultrafilters.
Monads are often considered in the 2-category Cat where they are given by endofunctors with a monoid structure on them. In particular, monads in Cat on Set are equivalent to the equational theories studied in universal algebra. In this context, a monad abstracts the concept of an algebraic theory (such as “group” or “ring”), giving a general notion of extra structure on an object of a category.
Classically, if is an algebraic theory (e.g. the theory of groups), a -structure on a set tells us how to interpret various terms (e.g. ) formed from elements of the set, subject to certain axioms (e.g. ). A monad collects this up into a functor . For a set , is the set of all terms of the theory formed from elements of , with terms identified if axioms force them to be equal. For groups, is thus the (underlying set of the) free group of formal words from ; the fact that gives free structures turns out to be typical.
To capture the theory fully, we need to include a little more data: a natural map recording how each gives a trivial term , and a map recording how further terms built from terms are already present as terms in .
Given a monad in Cat on a category , one can always produce a canonical resolution of any object of .
Monads on posets are particularly simple (in particular, they are always idempotent). In fact, monads on power sets are extremely common throughout mathematics; they are known in less categorially-inclined circles as Moore closures, and there are many examples there.
An internal monad on the subobject classifier of a topos is a Lawvere-Tierney topology on .
If is a category with finite limits, then a monad in the bicategory of spans in is the same thing as an internal category in .
A monad in the bicategory Prof of profunctors on a category can be identified with an identity-on-objects functor .
There is a vertical categorification of monads to (∞,1)-categories. See (∞,1)-monad.
in section 3 of
adjunction, comonad, adjoint monad, algebra over a monad, module over a monad, monad with arities, distributive law, monoidal monad, cartesian monad
monad 2-monad/doctrine / (∞,1)-monad
Original texts:
Fred Linton, An outline of functorial semantics, in Seminar on Triples and Categorical Homology Theory, Lecture Notes in Mathematics 80, Springer (1969) 7-52 [doi:10.1007/BFb0083080]
Ross Street, The formal theory of monads, Journal of Pure and Applied Algebra 2 2 (1972) 149-168 [doi:10.1016/0022-4049(72)90019-9]
Saunders MacLane, Ch. VI of: Categories for the Working Mathematician, Graduate Texts in Mathematics 5 Springer (1971) [doi:10.1007/978-1-4757-4721-8]
Michael Barr, Charles Wells, Chapter 3 of: Toposes, Triples, and Theories, Grundlehren der math. Wissenschaften 278, Springer (1983) [TAC:12]
H. Applegate, M. Barr, J. Beck, F. W. Lawvere, F. E. J. Linton, E. Manes, M. Tierney, F. Ulmer: Seminar on triples and categorical homology theory, ETH 1966/67, edited by Beno Eckmann and Myles Tierney, LNM 80, Springer (1969), reprinted as: Reprints in Theory and Applications of Categories 18 (2008) 1-303 [TAC:18, pdf]
Stephen Lack, Ross Street, The formal theory of monads II, Journal of Pure and Applied Algebra
175 1–3 (2002) 243-265 [doi:10.1016/S0022-4049(02)00137-8]
Textbook accounts:
Introductions:
The Catsters, Monads (five short video lectures)
John Baez, Universal Algebra and Diagrammatic Reasoning (Introductory slides).
Emily Riehl, p. 154 of: Category Theory in Context (2017)
Paolo Perrone, Notes on Category Theory with examples from basic mathematics, Chapter 5. (arXiv)
More on the relation to universal algebra:
Martin Hyland and John Power, The category theoretic understanding of universal algebra: Lawvere theories and monads (pdf).
Anthony Voutas, The basic theory of monads and their connection to universal algebra, (2012) [pdf, pdf]
An elementary proof of the equivalence between infinitary Lawvere theories and monads on the category of sets is given in Appendix A of
T. M. Fiore, N. Gambino, J. Kock, Monads in double categories, arxiv/1006.0797
Gabriella Böhm, Stephen Lack, Ross Street, Weak bimonads, arxiv/1002.4493
Last revised on March 2, 2023 at 17:09:06. See the history of this page for a list of all contributions to it.