commutative monoid

Commutative Monoid

Commutative Monoid

Mathematically a commutative Monoid is a Semigroup M along with an identity element u, such that

(∃u M) => (∀m M)(u+m = m+u = m)

When such an identity element u exists, it is necessarily unique.

Important

Contract: Commutative Monoid initializer parameters must have

  • add closed commutative and associative on reps

  • zero an identity on reps, rep+zero == rep == zero+rep