Let $T: M_{n,n}(\Bbb R) \to \Bbb R$ be a linear transformation such that $T(XY)=T(YX)$ for any two $n\times n$ matrices $X,\,Y$. How do you prove that $T(K)=a\ \mathrm{trace}(K)$ for some scalar $a$ in $\Bbb R$ for every $K$ in $M_{n,n}(\Bbb R)$?
I know that $\mathrm{trace}(XY)=\mathrm{trace}(X) + \mathrm{trace}(Y)$. My guess is that $\mathrm{trace}(XY)$ must be proportional to $T(XY)$, but I don't know how to state this mathematically.
Hint: Consider when $X$ and $Y$ are matrices of the form $E_{i,j}$ which is the matrix with a one in the $(i, j)$-entry, but zeroes elsewhere. Find out what $E_{i,j}E_{k, l}$ is (there are some possibilities depending on whether the indices are distinct and so on). From this you should be able to derive $T(E_{i,j})$ for every $i, j$ which will allow you to conclude that $T(K) = a\operatorname{trace}(K)$ for some $a \in \mathbb{R}$.