# examples of non-commutative operations

A standard example of a non-commutative operation is matrix multiplication. Consider the following two integer matrices:

 $A=\begin{pmatrix}1&1\\ 0&1\end{pmatrix},\qquad B=\begin{pmatrix}0&1\\ 0&1\end{pmatrix}$

If we compute $AB$ we get

 $AB=\begin{pmatrix}0&2\\ 0&1\end{pmatrix}$

but if we compute $BA$ we have

 $BA=\begin{pmatrix}0&1\\ 0&1\end{pmatrix}.$

Since $AB\neq BA$ we conclude that matrix product is not commutative.

Operations do not necessarily have to operate on numbers. Another classic example is function composition. Let $f$ and $g$ be real functions given by

 $f(x)=x^{2},\qquad g(x)=2x.$

We see that

 $(f\circ g)(x)=f(g(x))=(2x)^{2}=4x^{2},$

but

 $(g\circ f)(x)=g(f(x))=2(x^{2})=2x^{2}.$

Since we got different functions, we conclude that function composition is not commutative.

Title examples of non-commutative operations ExamplesOfNoncommutativeOperations 2013-03-22 15:03:04 2013-03-22 15:03:04 yark (2760) yark (2760) 10 yark (2760) Example msc 20-00