Monoid

From Wikipedia, the free encyclopedia
Jump to navigation Jump to search

In abstract algebra, a monoid is a set of elements with two key properties

  1. It can be combined associatively; e.g.
  2. There exists an identity element; e.g. , or

In computing science common monoids include addition, multiplication, or, and. These properties are useful for various problems e.g. they allow a large set of data to be divided, processed in parallel and combined. As each part produces a Monoid, the final combined result will be the same. This also works with more complex Monoids e.g. a map of word counts.

Other websites[change | change source]

Haskell/Monoids at Wikibooks