ArticleslgStudy

science

Distributive law between monads

Distributive law between monads is a science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Distributive law between monads rather than just read about it. In short: In category theory, an abstract branch of mathematics, distributive laws between monads are a way to express abstractly that two algebraic structures distribute one over the other. Suppose that (S,μS,ηS) and (T,μT,ηT) are two monads on a category C.

Distributive law between monads — main illustration
Distributive law between monads — illustration

Key takeaways

  • Distributive law between monads belongs to science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Distributive law between monads to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Distributive law between monads from memory before moving on to harder problems.

Reference excerpt

In category theory, an abstract branch of mathematics, distributive laws between monads are a way to express abstractly that two algebraic structures distribute one over the other. Suppose that (S,μS,ηS) and (T,μT,ηT) are two monads on a category C. In general, there is no natural monad structure on the composite functor ST. However, there is a natural monad structure on the functor ST if there is a distributive law of the monad S over the monad T. Formally, a distributive law of the monad S over the monad T is a natural transformation

l:TS→ST such that the diagrams

commute. This law induces a composite monad ST with

as multiplication: STST→SlTSSTT→μSμTST, as unit: 1→ηSηTST.

Examples

Monoids Informally, one might say that the free monoid on a set is given by "the free semigroup, plus an identity element". We can formalise this intuition, using the fact that both the free semigroup and the "free element" functors are monads. Explicitly, consider the monads

T(X):=∑n≥1Xn S(X):=X+1, (here addition denotes disjoint union), with unit maps given by:

ηXT:X→T(X) ηXT(x):=x∈X1 ηXS:X→S(X) ηXS(x):=x∈X. The multiplication map μXS:X+2→X+1 sends both elements of 2 to that of 1, but the multiplication on T is a bit more tricky to describe. First, note that an arbitrary element of T(X) is just a finite (nonempty) string of elements of X. The multiplication map T2(X)→T(X) should therefore take a string of words on X to one word. We choose μXT(list) to be the concatenation of all (finitely many) words in list. What does a distributive law l:TS→ST mean here? It takes a word on the set X+1 to either a word on X, or the disjoint point in 1. We choose the map that interprets the unit element e∈1 as the empty word; explicitly:

l(w)=w−e, where w−e is the word derived from w by removing all instances of e, unless w is all e's, in which case it's defined to be e∈1. The idea, in short, is this: if we view words on X as formal products of elements (i.e., the free semigroup operation), then l encodes that the freely added element e can be incorporated into the semigroup as a unit element (thereby making the structure into a monoid). Let us check that all the diagrams in the definition commute.

μT(X)S∘S(lX)∘lS(X)=lX∘T(μXS) LHS:w↦(w−e′)↦(w−e′−e)↦(w−e′−e) RHS:w↦w[e/e′]↦(w[e/e′]−e), e,e′ being the elements of each copy of 1 in X+1+1, and where w[e/e′] denotes the word w with every instance of e′ replaced by e.

lX∘T(ηXS)=ηT(X)S LHS:w↦w↦w−e RHS:w↦w, and note that for w∈T(X) we have w−e=w, as required.

S(μXT)∘lT(X)∘T(lX)=lX∘μS(X)T LHS:w↦w[(v−e)/v]↦w[(v−e)/v]−e↦concat(w[(v−e)/v]−e) RHS:w↦concat(w)↦concat(w)−e, where: concat(w) is the concatenation of all words in w, i.e. the multiplication on T; and w[(v−e)/v] is the result of replacing every word v in w with (v−e).

lX∘ηS(X)T=S(ηXT) LHS:(x∈X or e∈1)↦(x or e)↦(x or e)−e RHS:(x or e)↦(x or e). In summary, the four commutation requirements encode the following ideas:

"Deleting" elements w−e′ behaves like replacing them with the identity, w[e/e′]. Any word w on X doesn't contain the element e, so w−e=w. In other words, X+1 truly is a disjoint union. In a list of words w=(v1,...,vn), removing any instance of e in vi, removing any remaining "empty word" vi=e, and concatenating the resulting list, yields the same result as first concatenating v1v2...vn then removing all instances of e. x−e=x, as already covered in 2; and e−e=e, meaning we should interpret e as the empty word.

Rings This is the original example given by Beck, and is the motivation for the term "distributive law". Consider the two monads G,M:𝐒𝐞𝐭→𝐒𝐞𝐭 which send a set X to (the underlying set of) the free commutative group and the free monoid on it, respectively. We shall regard the formal group operation as addition, and that of the monoid as multiplication. In this case, both composites GM and MG give the free ring functor. We can now use the fact that the free ring admits a distributive law MG→GM to show that it's also a monad. The distributive law of G over M means exactly that a product of sums (i.e. an element of M(G(X))) can be identified with a sum of products (an element of G(M(X))). Note that we say G(X), the additive group, distributes over M(X), the multiplicative monoid - contrary to the usual convention; see the next section.

Terminology The original description by Beck calls l:TS→ST a distributive law of S over T. However, some authors prefer the reverse terminology, where l is instead said to be a distributive law of T over S; this is because, arguably, the latter convention corresponds more closely to the usual distributive law between multiplication and addition - multiplication is typically said to distribute over addition, by which one means that a product of sums can be rewritten as a sum of products ∏∑→∑∏ (see Examples). Nevertheless, both terminologies are in use in different sources, and the original is what this article uses.

Related notions

BD-law In the case where T=S, the distributive law map reduces to K:T2⇒T2, and one may impose some additional conditions. K is called a BD-law on T if:

(D) K is a distributive law, and (B) it satisfies the Yang-Baxter equation: KT(X)∘T(KX)∘KT(X)=T(KX)∘KT(X)∘T(KX) (as maps T3(X)→T3(X)). A BD-law is a BCD-law if the multiplication on T is "K-commutative", meaning that

(C) μXT∘KX=μXT (as maps T2(X)→T(X)). Condition (B) is called a Yang-Baxter equation because it literally is the Yang-Baxter equation defined on monoid objects, when T:𝐂→𝐂 is viewed as a monoid in the category of endofunctors on 𝐂.

Entwining For P an algebra and C a coalgebra over a shared field k, an entwining between them is a linear map ψ:C⊗P→P⊗C satisfying analogous conditions to those that would be required, were ψ a distributive law. Specifically, the commutation diagram CCP→PC that would be induced by a hypothetical multiplication CC→C is replaced with one for C⊗P→P⊗C⊗C induced by the comultiplication C→C⊗C; likewise, the triangle diagram P→PC is replaced with one of type C⊗P→P⊗k, induced by the counit.

See also Distributive property

References

… excerpt ends here. Continue reading the full article.

Illustrations

Distributive law between monads illustration
Distributive law between monads illustration
Distributive law between monads illustration
Distributive law between monads illustration

Worked examples

Example 1 — a first encounter with Distributive law between monads

Start with the simplest possible case. Write down what Distributive law between monads claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Distributive law between monads before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Distributive law between monads ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Distributive law between monads

In research
Distributive law between monads appears in science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Distributive law between monads in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Distributive law between monads is common in secondary-school and first-year university syllabi. It links to neighbouring topics Adjoint functors, so understanding it makes those chapters shorter.
In everyday life
Look for Distributive law between monads outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Distributive law between monads” →

How to study Distributive law between monads in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Distributive law between monads means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Distributive law between monads out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Distributive law between monads in simple terms?

In category theory, an abstract branch of mathematics, distributive laws between monads are a way to express abstractly that two algebraic structures distribute one over the other. Suppose that (S,μS,ηS) and (T,μT,ηT) are two monads on a category C.

Why does Distributive law between monads matter?

Because it connects several science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Distributive law between monads?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Distributive law between monads.

Tags

  • Adjoint functors

Keep exploring