I have this question in my textbook:
- Find a basis B of $R^2$ such that the matrix of the linear transformation $T(x, y) = (y, x)$ is diagonal with respect to B, and give the diagonal matrix
I have no idea how to proceed.
This is the only relevant explanation in my textbook:
Maybe I can ask, how did they get that diagonal matrix in the book from the basis?
I can see how they got the standard matrix.
and I can see how they got the basis:
But in the first photo, how do they go from the basis to the diagonal matrix?
EDIT
Is this right?
I have A =
$$\begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}$$
makes sense to me that this is the linear transformation matrix since
$$\begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix} * \begin{bmatrix} 2 \\ 3 \end{bmatrix} = \begin{bmatrix} 3 \\ 2 \end{bmatrix}$$
So finding eigenvalues:
$$(\lambda + 1)(\lambda - 1)$$
so eigenvalues are (1, -1)
Finding eigenvectors:
$$I - A = \begin{bmatrix} 1 & -1 \\ -1 & 1 \end{bmatrix} $$
$$-> \begin{bmatrix} 1 & -1 \\ 0 & 0 \end{bmatrix}$$
$$\begin{bmatrix} x_1 \\ x_2 \end{bmatrix} = \begin{bmatrix} t \\ t \end{bmatrix} = t * \begin{bmatrix} 1 \\ 1 \end{bmatrix} $$
Doing the same thing for eigenvalue = -1 leads me to eigenvector = $\begin{bmatrix} -1 \\ 1 \end{bmatrix}$
So $P = \begin{bmatrix} 1 & -1 \\ 1 & 1 \end{bmatrix}$
And $$P^{-1} = \begin{bmatrix} 1 & -1 & 1 & 0 \\ 1 & 1 & 0 & 1 \end{bmatrix}$$
$$ = \begin{bmatrix} 1 & -1 & 1 & 0 \\ 0 & 2 & -1 & 1 \end{bmatrix}$$
$$\begin{bmatrix} 1 & 0 & \frac{1}{2} & \frac{1}{2} \\ 0 & 1 & \frac{-1}{2} & \frac{1}{2} \end{bmatrix}$$
so $$P^{-1} = \begin{bmatrix} \frac{1}{2} & \frac{1}{2} \\ \frac{-1}{2} & \frac{1}{2} \end{bmatrix}$$
I get the diagonal matrix defined by $$P^{-1} * A * P = \begin{bmatrix} 1 & 0 \\ 0 & -1 \end{bmatrix}$$