Why does matrix multiplication usually fail to be commutative?

Created from Britannica articles using AI. AI can make mistakes, so verify using Britannica articles.

In linear algebra, matrix multiplication is generally not commutative because matrices represent linear transformations of space.12

When you multiply two matrices, you are essentially performing one transformation followed by another. Because the order in which these transformations are applied matters, the resulting transformation—and thus the product of the matrices—is typically different if the order is reversed. In mathematical terms, if S and T are square matrices, the product ST represents the result of applying transformation T followed by transformation S, which is rarely equal to TS.2

While ordinary numbers follow the commutative law (ab=ba), matrix multiplication is a distinct algebraic system where this property does not hold. An exception exists for diagonal matrices, where the multiplication of two such matrices is commutative.13