Assume M is a $2 \times 2$ real matrix such that $MX = XM$ for all real $2\times2$ matrices $X$. Show that $M$ must be some real multiple $q$ of $I$.
I can see that this is logical and have tried a few examples where I have multiplied $qI$ by some random $2\times2$ matrix from both sides and get the same matrix in both cases. How would I go about showing this though? Surely a few examples aren't actually showing anything for the general case, right?
Also, does the property shown in the question hold for all square matrices, or just $2\times2$ ones?