Question

# Let W be the subspace of all diagonal matrices in M_{2,2}. Find a bais for W. Then give the dimension of W. If you need to enter a matrix as part of your answer , write each row as a vector.For example , write the matrix

Matrices
Let W be the subspace of all diagonal matrices in $$M_{2,2}$$. Find a bais for W. Then give the dimension of W.
If you need to enter a matrix as part of your answer , write each row as a vector.For example , write the matrix

2021-01-29
Step 1
Given that W is the subspace of all diagonal matrices in $$M_{2,2}$$
The objective is to a basis for W.
Step 2
Consider the given vector space W of all diagonal matrices in $$M_{2,2}$$
Therefore,
$$W=\left\{\begin{bmatrix}a & 0 \\0 & b \end{bmatrix}, \text{a and b can be any real number}\right\}$$
Let E be basis for W.
Therefore,
$$\begin{bmatrix}a & 0 \\0 & b \end{bmatrix}=a\begin{bmatrix}1 & 0 \\0 & 0 \end{bmatrix}+b\begin{bmatrix}0 & 0 \\0 & 1 \end{bmatrix}$$
Now, let $$\lambda_1$$ and $$\lambda_2$$ be any two scalars such that:
$$\lambda_1\begin{bmatrix}1 & 0 \\0 & 0 \end{bmatrix}+\lambda_2\begin{bmatrix}0 & 0 \\0 & 1 \end{bmatrix}=[]$$
$$\begin{bmatrix}\lambda_1 & 0 \\0 & 0 \end{bmatrix}+\begin{bmatrix}0 & 0 \\0 & \lambda_2 \end{bmatrix}=\begin{bmatrix}0 & 0 \\0 & 0 \end{bmatrix}$$
$$\begin{bmatrix}\lambda_1 & 0 \\0 & \lambda_2 \end{bmatrix}=\begin{bmatrix}0 & 0 \\0 & 0 \end{bmatrix}$$
Equating the elements:
$$\lambda_1=0 ,\lambda_2=0$$
Therefore, $$\begin{bmatrix}1 & 0 \\0 & 0 \end{bmatrix}$$ and $$\begin{bmatrix}0 & 0 \\0 & 1 \end{bmatrix}$$ are linear independent.
Hence, the basis of W is $$E=\left\{\begin{bmatrix}1 & 0 \\0 & 0 \end{bmatrix},\begin{bmatrix}0 & 0 \\0 & 1 \end{bmatrix}\right\}$$ and dimension is 2.