Why $\textbf{AB=BA}$ when $\textbf{B=A^{-1}}$? [duplicate]

Matrix multiplication is not commutative:

$$AB \neq BA$$

So how come that when B is inverse of A $B=A^{-1}$ suddenly the commutative law works since:

$$AB=I_n=BA$$

when $B=A^{-1}$?

I understand there can be exceptions to all rules but why is this case an exception? What is the intuition behind this result?


Solution 1:

The definition of an inverse of $A$ is a matrix $B$ such that

$$AB=BA=I.$$

Such a matrix $B$ of course need not exist, but when it does, $A$ has this special property that we call being "invertible." End of story.