[Haskell-cafe] What are "free" Monads?
Günther Schmidt
gue.schmidt at web.de
Sat Feb 27 04:10:48 EST 2010
Hello Daniel,
that looks lovely, but it doesn't help me much :)
Günther
Am 27.02.10 10:06, schrieb Daniel Peebles:
> Given any functor you can get a monad for free!
>
> data Free f a = Either a (f (Free f a))
>
> Not sure about unfree, but there are cofree comonads that are pretty
> closely related, and give you a comonad given a functor:
>
> data Cofree f a = (a, f (Cofree f a))
>
> I'm sure the more categorically minded can tell you way more.
>
> Hope this helps,
> Dan
>
> 2010/2/27 Günther Schmidt <gue.schmidt at web.de <mailto:gue.schmidt at web.de>>
>
> Hello,
>
> I see the term "free monad" quite a lot, but don't really see an
> explanation what a free monad is. What sets a monad free and why
> in this day and age are there unfree monads?
>
> Günther
>
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org <mailto:Haskell-Cafe at haskell.org>
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20100227/6420c92d/attachment.html
More information about the Haskell-Cafe
mailing list