2
$\begingroup$

In the free monoid monad $(T, \eta, \mu)$ in category $Set$:

$T: Set\to Set$ is a endofunctor, is the composition of the free monoid functor $List:Set→Mon$ and the forgetful functor $U:Mon→Set$. $TA$ is the set of finite lists of elements in set $A$.

$\eta_A: A\to TA$ sends each element $a$ of set $A$ to the corresponding singleton list $[a]$.

What does the multiplication operation $\mu$ of a monad mean? Specifically, what does $\mu_A: T^2A \to TA$ do/mean?

Thanks.

$\endgroup$
2
  • $\begingroup$ It means union. $\endgroup$
    – k.stm
    Commented Jul 23, 2019 at 17:30
  • $\begingroup$ Thanks. Can you be more specific? $\endgroup$
    – Tim
    Commented Jul 23, 2019 at 18:47

1 Answer 1

4
$\begingroup$

The set $T(T(X))$ is the set of lists of lists and the natural transformation $\mu$ is just merging the lists of lists into one single list, also known as concatenation.

To be more specific, an element of $T(T(X))$ is something like $L = [[x_{1,1},x_{1,2},\cdots,x_{1,n_1}],\cdots, [x_{k,1},\cdots,x_{k,n_k}]]$, with $k,n_1,\cdots,n_k \in \mathbb{N}$, (when $n_i$<1 lets say the list is empty). Then $\mu(L) = [x_{1,1},\cdots,x_{k,n_k}]$.

To give an example lets say $X = \{a,b,c\}$, then $\mu([[a,a,a],[],[a,b,b,c],[c,a,b]]) = [a,a,a,a,b,b,c,c,a,b]$.

$\endgroup$
2
  • $\begingroup$ Thanks. Can you give some example? $\endgroup$
    – Tim
    Commented Jul 23, 2019 at 20:35
  • $\begingroup$ I changed the answer to give more details. $\endgroup$ Commented Jul 23, 2019 at 20:49

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .