Let \(F\) be a field and let \(n\) be a positive integer (\(n \geq 2\)). Let \(V\) be the vector space of all \(n \times n\) matrices over \(F\). Which of the following sets of matrices \(A\) in \(V\) are subspaces of \(V\)?
all invertible \(A\);
all non-invertible \(A\);
all \(A\) such that \(AB = BA\), where \(B\) is some fixed matrix in \(V\);
all \(A\) such that \(A^2 = A\).
Solution
Only (c) is always a subspace.
1. The invertible matrices are not a subspace.
The zero matrix is not invertible, so the set does not contain the zero vector of \(V\).
2. The non-invertible matrices are not a subspace when \(n\ge2\).
Let \[ A=\operatorname{diag}(1,0,1,\ldots,1), \qquad C=\operatorname{diag}(0,1,0,\ldots,0). \] Both are singular, but \(A+C=I_n\) is invertible.
3. The matrices commuting with a fixed matrix \(B\) form a subspace.
If \(AB=BA\) and \(CB=BC\), then for scalars \(r,s\), \[ (rA+sC)B=rAB+sCB=rBA+sBC=B(rA+sC). \] The zero matrix also commutes with \(B\).
4. The idempotent matrices are not a subspace.
Both \(0\) and \(I_n\) are idempotent, but for a scalar \(c\) with \(c^2\ne c\) the matrix \(cI_n\) is not idempotent. Over any field with such a scalar this already disproves closure under scalar multiplication. In the field with two elements, take the two idempotents \[ E_{11},\qquad E_{22}; \] for \(n\ge2\); their sum is idempotent, so instead use \[ A=\begin{bmatrix}1&1\\0&0\end{bmatrix}, \qquad C=\begin{bmatrix}0&0\\1&1\end{bmatrix} \] inside the upper-left \(2\times2\) block. Both satisfy \(A^2=A\) and \(C^2=C\), while \((A+C)^2=0\ne A+C\) in characteristic \(2\). Thus the set is not a subspace over any field.