4 ms·
> What I meant was something different. The difference is that saying that "IO is a monad" is wrong in the mathematical sense too. It's relatively common to re
by mmarx 11y ago
> What I meant was something different. The difference is that saying that "IO is a monad" is wrong in the mathematical sense too.
It's relatively common to refer to the underlying set as a monoid (or whatever structure you're talking about) if it's clear from the context what the operations are, though.
> The set may, at best, be "monoidal" (i.e. there exists associative binary operator <> and a set member ZERO such that for all elements of the set, ZERO <> x == x <> ZERO == x).
That's a pretty useless definition, though, as every non-empty set trivially satisfies that condition (just pick any element as the zero element, and let the binary operation be the constant mapping to that element). Also, “monoidal” usually means a monoidal category, which is something very different from the underlying set of a monoid altogether.
- spion 11y ago> It's relatively common to refer to the underlying set as a monoid (or whatever structure you're talking about) if it's clear from the context what the operations are, though. Relatively common even outside Haskell?
- mmarx 11y ago> Relatively common even outside Haskell? It's common throughout mathematics. So common, in fact, that there's even a wikipedia article on the phenomenon[0]. “Common examples occur when speaking of compound mathematical objects. […] Similarly, one often refers to a group (G, \star) as simply G when the group operation is clear from context.” [0] https://en.wikipedia.org/wiki/Abuse_of_notation https://en.wikipedia.org/wiki/Abuse_of_notation
- spion 11y agoFair enough. But I don't think its surprising that it may lead to confusion when beginners study the subject.