Semigroup

A set equipped with an associative binary operation
Semigroup

A semigroup is a SS together with an associative :S×SS\cdot : S \times S \to S, meaning that for all a,b,cSa,b,c \in S, (ab)c  =  a(bc). (a\cdot b)\cdot c \;=\; a\cdot(b\cdot c).

Semigroups are the weakest common algebraic setting in which repeated products are unambiguous (associativity lets you omit parentheses). A is a semigroup with an identity element, and a is a monoid in which every element has an inverse.

Examples:

  • (N,+)(\mathbb{N},+) is a semigroup (addition is associative).
  • (N1,×)(\mathbb{N}_{\ge 1},\times) is a semigroup (multiplication is associative).
  • The set of all n×nn\times n real matrices under matrix multiplication is a semigroup.
  • (Edge case) If one allows empty algebraic structures, the empty set has a unique binary operation ×\,\emptyset\times\emptyset\to\emptyset\, and is a semigroup, but it cannot be a monoid (no identity element exists).