Dimension of Null Space of a given linear transformation Let $A =\begin{bmatrix}2 & -1\\-1 & 2\end{bmatrix}$
Define Linear Transformation $T$ as $AX - XA$ where $X$ is a $2$ x $2$ matrix. Find dimension of Null space of $T$?
My approach: Let $X = \begin{bmatrix}a & b\\c & d\end{bmatrix}$ Then simplifying the expression for T.
$AX = \begin{bmatrix}2 & -1\\-1 & 2\end{bmatrix} \times \begin{bmatrix}a & b\\c & d\end{bmatrix} = \begin{bmatrix}2a -c & 2b - d\\-a + 2c & -b+2d\end{bmatrix}$ 
and
$XA = \begin{bmatrix}a & b\\c & d\end{bmatrix} \times \begin{bmatrix}2 & -1\\-1 & 2\end{bmatrix} = \begin{bmatrix}2a - b & -a+2b\\2c-d & -c+2d\end{bmatrix}$
So $AX - XA = \begin{bmatrix}2a -c -2a + b& 2b - d +a-2b\\-a + 2c -2c +d & -b+2d +c -2d\end{bmatrix}$
Simplying it will give
$AX -XA = \begin{bmatrix}b -c & a - d\\d-a & c-b\end{bmatrix}$
Now null space is when $TX = 0$
so comparing element by element in $AX-XA = 0$ 
$\begin{bmatrix}b -c & a - d\\d-a & c-b\end{bmatrix} = \begin{bmatrix}0 & 0\\0 & 0\end{bmatrix}$
we get $b = c$ and $a = d$ for matrices which will belong to $T's$ null space.
So $X = \begin{bmatrix}a & b \\b & a\end{bmatrix}$ will be mapped to $0$. $X$ could be written as
$X = a\times\begin{bmatrix}1  & 0\\0 & 1\end{bmatrix} + b \times\begin{bmatrix}0 & 1\\1 & 0\end{bmatrix}$.
So the Dimension of Null space should be $2$. 
Am I correct? I faced this problem in math subject gre paper and linear algebra is my weakest topic so if anyone could help me with this I would be really thankful.
 A: This given solution seems fine.  So, +1, endorsed!
Here's another way of doing these calculations which some may find somewhat easier; also I think it lends further insight into the problem:
We may generalize and write
$A = \begin{bmatrix} a & b \\ b & a \end{bmatrix} = aI + bP, \tag 1$
where
$P = \begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}; \tag 2$
then since $I$ commutes with any matrix $X$,
$IX = XI, \tag 3$
it is easy to see that
$T(X) = AX - XA = b(PX - XP); \tag 4$
this always vanishes for $b = 0$ and for arbitrary $b \ne 0$ provided
$PX - XP = 0 \Longrightarrow PX = XP; \tag 5$
with
$X = \begin{bmatrix} x_1 & x_2 \\ x_3 & x_4 \end{bmatrix}, \tag 6$
(5) becomes
$\begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix} \begin{bmatrix} x_1 & x_2 \\ x_3 & x_4 \end{bmatrix} = \begin{bmatrix} x_1 & x_2 \\ x_3 & x_4 \end{bmatrix} \begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}; \tag 7$
that is,
$\begin{bmatrix} x_3 & x_4 \\ x_1 & x_2 \end{bmatrix} = \begin{bmatrix} x_2 & x_1 \\ x_4 & x_3 \end{bmatrix}, \tag 8$
from which
$x_1 = x_4, \; x_2 = x_3; \tag 9$
we thus see that
$X = \begin{bmatrix} x_1 & x_2 \\ x_2 & x_1 \end{bmatrix} = x_1I + x_2P; \tag{10}$
comparing this to (1), we see that $X$ is in the same general family as $A$, and that if $b \ne 0$
$\dim \ker T = 2; \tag{11}$
but
$\dim \ker T = 4 \tag{11}$
when $b = 0$.
