0

refer to this topic

I have matrix $A=\begin{pmatrix}3&2&2\\2&3&2\\2&2&7\end{pmatrix}$ , $D=\begin{pmatrix}1&0&0\\0&3&0\\0&0&9\end{pmatrix}$ and $P=\begin{pmatrix}1&1&1\\-1&1&1\\0&-1&2\end{pmatrix}$

By $B\equiv P\sqrt{D}$, I got $B=\begin{pmatrix}1&1&1\\-1&1&1\\0&-1&2\end{pmatrix} \begin{pmatrix}1&0&0\\0&\sqrt3&0\\0&0&3\end{pmatrix}$

So $B= \begin{pmatrix}1&\sqrt3&3\\-1&\sqrt3&3\\0&-\sqrt3&6\end{pmatrix} $

However when I plug $B$ into $BB^T$ I didn’t get the matrix $A$.

2 Answers2

2

Your $P$ isn't orthogonal. Sure, the columns are all pairwise orthogonal, but the rows aren't. Or, more pecisely, the columns are orthogonal but not orthonormal. This doesn't make $A = PDP^{-1}$ an incorrect diagonalisation, but does mean that $A \neq PDP^T$, as $P^{-1}\neq P^T$.

You need to make each column of $P$ into a unit vector. Which is to say, you need $$ P = \begin{pmatrix}\frac{1}{\sqrt2}&\frac1{\sqrt3}&\frac1{\sqrt6}\\ -\frac1{\sqrt2}&\frac1{\sqrt3}&\frac1{\sqrt6}\\ 0&-\frac1{\sqrt3}&\frac2{\sqrt6}\end{pmatrix} $$ This way we actually do have $P^{-1} = P^T$, which means that $A = PDP^{-1}$ is indeed equal to $PDP^T$, and your $B = P\sqrt D$ will work.

Arthur
  • 199,419
  • $P$ is formed from the three eigenvectors of A and $P$ is supposed to be orthogonal – Brian Wu Dec 03 '19 at 08:12
  • 1
    @BrianWu Yes, you're right, it is supposed to be orthogonal. Note, however, that an orthogonal matrix doesn't just mean that the columns are orthogonal (that happens automatically with a symmetric matrix with distinct eigenvalues). An orthogonal matrix is alos required to have unit length columns. You will note that in my $P$, the columns are still eigenvectors. They are, in fact, the same eigenvectors, just scaled down so that they all have length $1$. – Arthur Dec 03 '19 at 08:19
  • @BrianWu Note that, somewhat confusingly, an orthogonal matrix is not just required to have orthogonal columns, but orthonormal ones. So although your matrix has orthogonal columns, it is not an orthogonal matrix, since the columns aren't orthonormal. – YiFan Tey Dec 03 '19 at 12:32
0

$$ P^T H P = D $$ $$\left( \begin{array}{rrr} 1 & 0 & 0 \\ - \frac{ 2 }{ 3 } & 1 & 0 \\ - \frac{ 2 }{ 5 } & - \frac{ 2 }{ 5 } & 1 \\ \end{array} \right) \left( \begin{array}{rrr} 3 & 2 & 2 \\ 2 & 3 & 2 \\ 2 & 2 & 7 \\ \end{array} \right) \left( \begin{array}{rrr} 1 & - \frac{ 2 }{ 3 } & - \frac{ 2 }{ 5 } \\ 0 & 1 & - \frac{ 2 }{ 5 } \\ 0 & 0 & 1 \\ \end{array} \right) = \left( \begin{array}{rrr} 3 & 0 & 0 \\ 0 & \frac{ 5 }{ 3 } & 0 \\ 0 & 0 & \frac{ 27 }{ 5 } \\ \end{array} \right) $$ $$ Q^T D Q = H $$ $$\left( \begin{array}{rrr} 1 & 0 & 0 \\ \frac{ 2 }{ 3 } & 1 & 0 \\ \frac{ 2 }{ 3 } & \frac{ 2 }{ 5 } & 1 \\ \end{array} \right) \left( \begin{array}{rrr} 3 & 0 & 0 \\ 0 & \frac{ 5 }{ 3 } & 0 \\ 0 & 0 & \frac{ 27 }{ 5 } \\ \end{array} \right) \left( \begin{array}{rrr} 1 & \frac{ 2 }{ 3 } & \frac{ 2 }{ 3 } \\ 0 & 1 & \frac{ 2 }{ 5 } \\ 0 & 0 & 1 \\ \end{array} \right) = \left( \begin{array}{rrr} 3 & 2 & 2 \\ 2 & 3 & 2 \\ 2 & 2 & 7 \\ \end{array} \right) $$

One way to finish from $ Q^T D Q = H ,$ is to force the middle to be the identity matrix, so $R$ soves $D = R^T R, $ then $H = Q^T R^T RQ.$ Might as well take $R$ diagonal, the square roots of the diagonal elements in $D.$ Note that my $Q$ has determinant $1,$ so

$$ RQ = \left( \begin{array}{rrr} \sqrt 3 & \frac{ 2 }{ \sqrt 3 } & \frac{ 2 }{ \sqrt 3 } \\ 0 & \frac{\sqrt 5}{ \sqrt 3} & \frac{ 2 }{ \sqrt {15} } \\ 0 & 0 & \frac{3 \sqrt 3}{\sqrt 5} \\ \end{array} \right) $$

For you, the matrix on the right is $B^T,$ so $B^T = RQ$ and $B = (RQ)^T$

Will Jagy
  • 139,541