48. Associativity

48.1 Definition: associative

A binary operation $\Delta$ is associative if for any elements $x$, $y$, $z$ of $A$,

$$x \Delta (y \Delta z) = (x \Delta y) \Delta z \tag{48.1}$$

48.1.1 Remark In ordinary functional notation (prefix notation), the definition of associative says $\Delta(x,\Delta(y,z) = \Delta(\Delta(x,y,),z))$. In postfix notation: $x\ y\ \Delta\ z\ \Delta = x\ y\ z\ \Delta\ \Delta$.

48.1.2 Example The usual operations of addition and multiplication are associative, but not subtraction; for example, $3- (5- 7)\neq (3- 5)-7$. The operation given in 47.1.2 is not associative; for example, $(a \Delta a ) \Delta c =b \Delta c =a$, but $a \Delta (a \Delta c ) =a \Delta a =b$.

48.1.3 Example For any nonempty set $X$, union and intersection are associative binary operations in $\mathcal{P}X$.

48.1.4 Example For real numbers $r$ and $s$, let $\max:\mathrm{R}\times\mathrm{R}\to\mathrm{R}$ and $\min:\mathrm{R}\times\mathrm{R}\to\mathrm{R}$ be the functions defined by: $\max(r,s)$ is the larger of $r$ and $s$ and $\min(r,s)$ the smaller. If $r=s$ then $\max(r,s)=\min(r,s)=r=s$. These are both associative binary operations on the set $\mathrm{R}$ of real numbers.

48.1.5 Exercise Prove that for any set $S$, union is an associative binary operation on $\mathcal{P}S$. (Answer on page 245.)

48.1.6 Exercise Prove that for any set $S$, intersection is an associative binary operation on $\mathcal{P}S$.

48.1.7 Exercise Show that the right band operation on any set $A$ is associative.

48.1.8 Exercise Find a binary operation $\Delta$ on some set $A$ with the property that, for some element $a\in A$,

$$(a \Delta a) \Delta a) \neq a \Delta (a \Delta a)$$

48.1.9 Exercise Is the binary operation $\Delta$ given by this table associative? Give reasons for your answer.

$$\begin{array}{c|cc} \Delta & a & b \\ \hline a & a & a \\ b & b & a \end{array}$$

48.1.10 Exercise Prove that $\max:\mathrm{R}\times\mathrm{R}\to\mathrm{R}$ is associative (see Example 48.1.4).

48.2 The general associative law

If $\Delta$ is an associative operation on $A$, then it is associative in a more general sense, in that it satisfies the General Associative Law: Any two meaningful products involving $\Delta$ and $a_{1},a_{2},...,a_{n}$ (names of elements of $A$) in that order denote the same element of $A$.

48.2.1 Example If $a \Delta (b \Delta c ) = (a \Delta b ) \Delta c$, then all five meaningful ways of writing the product of four elements are the same:

$$\begin{aligned} a \Delta (b \Delta (c \Delta d)) &= a \Delta ((b \Delta c) \Delta d) = (a \Delta b) \Delta (c \Delta d) \\ &= ((a \Delta b) \Delta c) \Delta d = (a \Delta (b \Delta c)) \Delta d \end{aligned}$$

Pages 70–71 of the book (PDF).