In mathematics, a binary operation * on a set S is called associative if for all x, y and z in S, (x * y) * z = x * (y * z).

The most commonly known examples of associativity are addition and multiplication of natural numbers; for example:

  • (7 + 3) + 9 = 7 + (3 + 9), since the expression on the left evaluates to 10 + 9 = 19, which the expression on the right evaluates to 7 + 12 = 19, the same value;
  • (10 × 5) × 3 = 10 × (5 × 3), since the expression on the left evaluates to 50 × 3 = 150, while the expression on the right evalutes to 10 × 15 = 150.

Other examples of associative binary operations include addition and multiplication of real numbers, complex numbers and square matrices; addition of vectors; and intersection and union of sets. Also, if M is some set and S denotes the set of all functions from M to M, then the operation of functional composition on S is associative.

On the other hand, exponentiation is not associative; eg 2^(1^3)=2 but (2^1)^3=8. But the usual superscript notation tends to prevent questions of order arising.

A set with an associative binary operation on it is called a semigroup; monoids and groupss are examples of semigroups.

See also Commutativity, Distributive property, Identity element\n