Closure | Associativity | Identity | Invertibility | |
---|---|---|---|---|
Magma | Required | |||
Semigroup | Required | Required | ||
Monoid | Required | Required | Required | |
Group | Required | Required | Required | Required |
A magma consists of a set equipped with a single binary operation. The binary operation must be closed by definition but no other properties are imposed.
(See the definition of closure below)
A magma is a set M matched with an operation, •, that sends any two elements a, b ∈ M to another element, a • b. The symbol, •, is a general placeholder for a properly defined operation. To qualify as a magma, the set and operation (M, •) must satisfy the following requirement (known as the magma or closure axiom):
For all a, b in M, the result of the operation a • b is also in M.
And in mathematical notation:
A semigroup is an associative magma.
A monoid is a semigroup with an identity element.
A monoid in which each element has an inverse is a group.
A set is closed under an operation if performance of that operation on members of the set always produces a member of that set. For example, the positive integers are closed under addition, but not under subtraction: 1 - 2 is not a positive integer even though both 1 and 2 are positive integers.
Given a set S, for all , the equation
holds.
Given a set S, there exists an element e in S such that for every element a in S, the equations e • a = a • e = a hold.
We say that 'e' is an identity element.
For each a in a set S, there exists an element b in S, commonly denoted a−1 (or −a, if the operation is denoted "+"), such that a • b = b • a = e, where e is the identity element.