In mathematics, the commutator gives an indication of the extent to which a certain binary operation fails to be commutative. There are different definitions used in group theory and ring theory.
Contents 
The commutator of two elements, g and h, of a group, G, is the element
It is equal to the group's identity if and only if g and h commute (i.e., if and only if gh = hg). The subgroup of G generated by all commutators is called the derived group or the commutator subgroup of G. Note that one must consider the subgroup generated by the set of commutators because in general the set of commutators is not closed under the group operation. Commutators are used to define nilpotent and solvable groups.
N.B. The above definition of the commutator is used by group theorists. Many other mathematicians define the commutator as
Commutator identities are an important tool in group theory, (McKay 2000, p. 4). The expression a^{x} denotes x^{−1}a x.
Identity 5 is also known as the HallWitt identity. It is a grouptheoretic analogue of the Jacobi identity for the ringtheoretic commutator (see next section).
N.B. The above definition of the conjugate of a by x is used by group theorists. Many other mathematicians define the conjugate of a by x as xax^{−1}. This is often written ^{x}a. Similar identities hold for these conventions.
A wide range of identities are used that are true modulo certain subgroups. These can be particularly useful in the study of solvable groups and nilpotent groups. For instance, in any group second powers behave well
If the derived subgroup is central, then
The commutator of two elements a and b of a ring or an associative algebra is defined by
It is zero if and only if a and b commute. In linear algebra, if two endomorphisms of a space are represented by commuting matrices with respect to one basis, then they are so represented with respect to every basis. By using the commutator as a Lie bracket, every associative algebra can be turned into a Lie algebra. The commutator of two operators defined on a Hilbert space is an important concept in quantum mechanics since it measures how well the two observables described by the operators can be measured simultaneously. The uncertainty principle is ultimately a theorem about these commutators via the RobertsonSchrödinger relation.
The commutator has the following properties:
Liealgebra relations:
The second relation is called anticommutativity, while the third is the Jacobi identity.
Additional relations:
If A is a fixed element of a ring , the first additional relation can also be interpreted as a Leibniz rule for the map given by . In other words: the map D_{A} defines a derivation on the ring .
The following identity involving commutators, a special case of the BakerCampbellHausdorff formula, is also useful:
When dealing with graded algebras, the commutator is usually replaced by the graded commutator, defined in homogeneous components as
Especially if one deals with multiple commutators, another notation turns out to be useful involving the adjoint representation:
Then ad(x) is a derivation and ad is linear, i.e., ad(x + y) = ad(x) + ad(y) and , and a Lie algebra homomorphism, i.e, ad([x,y]) = [ad(x),ad(y)], but it is not always an algebra homomorphism, i.e the identity does not hold in general.
Examples:
The anticommutator of two elements a and b of a ring or an associative algebra is defined by
The anticommutator is used less often than the commutator, but can be used for example to define Clifford algebras and Jordan algebras.
