# Find a matrix $P$ that orthogonally diagonalizes $A$ and determine $P^{-1}AP$

I'm completely lost on how to finish this problem. The problem from the book is

Find a matrix $P$ that orthogonally diagonalizes $A$ and determine $P^{-1}AP$

and my matrix is the $2 \times 2$ matrix $$\begin{pmatrix} 6 & 2\sqrt{3} \\ 2\sqrt{3} & 7 \end{pmatrix}$$

So far I've found the characteristic equation to be $x^2-13x+30 = 0$ and have factored it to be $(x-10)(x-3)=0$ and then found the eigenvalues of $\lambda=3, 10$. My diagonal matrix then is $$D=\begin{pmatrix} 3 & 0 \\ 0 & 10 \end{pmatrix}.$$

From this I'm supposed to find $P$ and $P^{-1}$, my values for $P$ have been wrong this whole time and I end up with $$P=\begin{pmatrix} 2\frac{\sqrt{3}}{3} & 1 \\ \frac{\sqrt{3}}{4} & 1 \end{pmatrix}$$

The book says $$P=\begin{pmatrix} -\frac{2}{\sqrt{7}} & \frac{\sqrt{3}}{\sqrt{7}} \\ \frac{\sqrt{3}}{\sqrt{7}} & \frac{2}{\sqrt{7}} \end{pmatrix}.$$

I tried using the formula $\frac{\vec{v_1}}{||\vec{v_1}||}$ that looked relevant to this from the book, but I didn't end up with what the book had.

I really appreciate any help!

-Frank

Hint: Find the eigenvectors that correspond to $\lambda=3,10$ and then normalize them by dividing by their norm - this is necessary to produce an orthogonal matrix, which has orthonormal columns (column vectors that form an orthogonal set and are unit vectors). Refer to my answer on the following post for the form of $P$: Some techniques to test for diagnalizibility for some random Matrix, lets say A?

• Thank you for your response! I tried normalizing them, but I end up with {{2(sqrt(3))/3(sqrt(5)), 1/3(sqrt(5))}, {(sqrt(3)/4(sqrt(19/16)), (1/4(sqrt(19/16))}}. Unfortunately, the theorems are hard for me to relate to solving these (I'm not very good at this course -_-). Do I have to normalize the column vectors from my original matrix or is it possible that I row reduced incorrectly? (I've started over about 10 times and keep ending up with the same values, but maybe I missed something?) – Frank A. May 25 '14 at 6:28
• You might not have the correct eigenvectors...try solving the equation $$A\vec{v} = \lambda \vec{v} \iff (A - \lambda I)\vec{v} = \vec{0}$$ with each eigenvalue for $\vec{v}$. @FrankA. – afedder May 25 '14 at 6:33
• @FrankA. The eigenvectors end up being $\vec{v_1}=\left(\frac{\sqrt{3}}{2},1\right)$, which corresponds to $\lambda_1 = 10$, and $\vec{v_2}=\left(-\frac{2}{\sqrt{3}},1\right)$, corresponding to $\lambda_2 = 3$...so you can check your answers. – afedder May 25 '14 at 6:41
• Hey, thanks again for your response! I'm not sure what I'm doing, but for lambda = 3 I end up getting -3 -2(sqrt(3)) on the top and 0 0 on the bottom. Then I take -3x-2(sqrt(3))y = 0 and after solving for x I get x = (-2(sqrt(3))/3)y. I'm not sure where I went wrong, but just wanted to run that by you. I do get the same value for lambda = 10 though. – Frank A. May 25 '14 at 6:52
• If you're saying you obtain $$\begin{pmatrix} -3 & -2\sqrt{3} \\ 0 & 0 \end{pmatrix}$$ upon row-reduction, then this is the same as saying that any eigenvector corresponding to eigenvalue $3$ is a scalar multiple of $\left(-\frac{2}{\sqrt{3}},1\right)$. Note that $\frac{2\sqrt{3}}{3} = \frac{2}{\sqrt{3}}$. @FrankA. – afedder May 25 '14 at 6:54

"$P$ orthogonally diagonalizes $A$" means that $P$ is an orthogonal matrix. So, you need to normalise your eigenvectors to unit lengths.

• Hi, thank you so much for your response! I tried normalizing them, but I end up with {{2(sqrt(3))/3(sqrt(5)), 1/3(sqrt(5))}, {(sqrt(3)/4(sqrt(19/16)), (1/4(sqrt(19/16))}}. To make them unit vectors they have to = 1, but I'm not sure how to normalize them. I tried looking up examples and haven't found any that make sense to me. Am I supposed to normalize the vectors after I put them into P? – Frank A. May 25 '14 at 6:24
• @FrankA. You calculated the eigenvectors wrongly. E.g. $A-3I$ is an entrywise positive matrix. So, in order that $(A-3I)v=0$, the eigenvector $v$ must contain one positive entry and one negative entry. Yet, all entries of your eigenvector for $\lambda=3$ are positive. The eigenvector corresponding to $\lambda=10$ is wrong too. – user1551 May 25 '14 at 6:41

You have $$A = \begin{bmatrix} 6 & 2\sqrt{3} \\ 2\sqrt{3} & 7 \end{bmatrix}$$ and you want an orthogonal $P$ such that $P^{-1} A P = \operatorname{diag}(\lambda_1, \lambda_2)$ is diagonal. So, let us denote $$P = \begin{bmatrix} c & s \\ -s & c \end{bmatrix},$$ where $c^2 + s^2 = 1$ (in other words, $c$ and $s$ are cosine and sine of some angle). Notice that $P^{-1} = P^T$.

Now, \begin{align*} \begin{bmatrix} 10 \\ & 3 \end{bmatrix} &= P^T A P = \begin{bmatrix} c & -s \\ s & c \end{bmatrix} \begin{bmatrix} 6 & 2\sqrt{3} \\ 2\sqrt{3} & 7 \end{bmatrix} \begin{bmatrix} c & s \\ -s & c \end{bmatrix} \\ &= \begin{bmatrix} 6 c^2-4 \sqrt{3} c s+7 s^2 & 2 \sqrt{3} c^2-c s-2 \sqrt{3} s^2 \\ 2 \sqrt{3} c^2-c s-2 \sqrt{3} s^2 & 7 c^2+4 \sqrt{3} c s+6 s^2 \end{bmatrix}. \end{align*}

From the top right element, we see that $$2 \sqrt{3} c^2 - cs - 2\sqrt{3}s^2 = 0.$$ It is easy to see that $c,s \ne 0$, so we can divide by $c^2$ and use that $t = s/c$ is tangent of the same angle of which $c$ and $s$ are cosine and sine: $$2 \sqrt{3} - t - 2\sqrt{3}t^2 = 0.$$ Solving the quadratic equation, we see that $$t_1 = -\frac{2}{\sqrt{3}}, \quad t_2 = \frac{\sqrt{3}}{2}.$$ Pick any of these two, get $c$ and $s$, and you'll get $P$ and the eigenvalues.

Generally, it is wise to get $c,s$ from $t$ directly, without the arc-functions, but it shouldn't matter in this case.