1
$\begingroup$

I cannot find where I have made a computational error in applying the spectral method for solving $Ax=b$.

I am given $A = \begin{pmatrix} 7 &-2 & 1 \\ -2 & 10 & -2 \\ 1 & -2 & 7 \end{pmatrix}, b = \begin{pmatrix} 6 \\ 12 \\ 18 \end{pmatrix}$.

I've started by computing the eigenvalues and eigenvectors, I have the eigenvalues $r_1 = 12, r_2 = 6, r_3 = 6$ with eigenvectors $v_1 = (1,-2,1), v_2 = (-1,0,1), v_3 = (2,1,0)$ respectively.

Now, $x$, by the spectral method is given by $$\displaystyle x= \frac{u_1\cdot b}{r_1}u_1 + \frac{u_2\cdot b}{r_2}u_2+\frac{u_3\cdot b}{r_3}u_3.$$

Normalizing $v_1,v_2,v_3$ I get $u_1=\begin{pmatrix} \frac{1}{\sqrt{6}} \\ \sqrt{\frac{2}{3}} \\ \frac{1}{\sqrt{6}} \end{pmatrix} ,u_2 = \begin{pmatrix}\frac{-1}{\sqrt{2}} \\ 0 \\ \frac{1}{\sqrt{2}}\end{pmatrix}, u_3 = \begin{pmatrix} \frac{2}{\sqrt{5}} \\ \frac{1}{\sqrt{5}} \\ 0 \end{pmatrix}.$

So $x = 0 + \frac{6\sqrt{2}}{6}\left(-1/\sqrt{2},0,1/\sqrt{2}\right) + \frac{4}{\sqrt{5}}\left(2/\sqrt{5},1/\sqrt{5},0\right)=(7,4,1).$

This does not satisfy $Ax=b$ -- I can't find my error. By normal method of row reduction, I get $x=(1,2,3)$. Wolfram confirms this too! Am I incorrectly applying something here?

2 Answers 2

1

Your so-called spectral method works if the eigenvectors form an orthonormal basis, but this is not the case here: your $v_2,v_3$ are not even mutually orthogonal.

  • 0
    Since $A$ happens to be symmetric here, must not it have an orthonormal basis consisting of eigenvectors of $A$? https://en.wikipedia.org/wiki/Symmetric_matrix2017-01-24
  • 0
    You must norm your eigenvectors vector - their norm sholud be 12017-01-24
  • 1
    @Mathos $A$ does possess an orthonormal eigenbasis, but that doesn't mean the eigenvectors **you** choose are orthonormal. E.g. $u=(1,0)^T$ and $v=\frac1{\sqrt{2}}(1,1)^T$ are eigenvectors of the identity matrix $I_2$ (which is symmetric), but $\{u,v\}$ is not an orthonormal eigenbasis of $I_2$. (By the way, as the other comment points out, the eigenvectors in your question are also not of unit lengths. So, you have many things to fix.)2017-01-24
  • 0
    @user1551 Thanks! I do normalize them when I write out my $x$. Knowing that $A$ is symmetric, don't I simply need to normalize $v_1,v_2,v_3$ and proceed from there (I will edit my answer to make my computations more clear)?2017-01-24
  • 0
    @Mathos No. In principle, you first need to find a set of **mutually orthogonal** eigenvectors for every **repeated** eigenvalue, and then normalise each eigenvector. In your case, you first need to replace $v_3$ by another eigenvector for the eigenvalue $6$, so that $v_3\perp v_2$. You can use Gram-Schmidt orthogonalisation to do that. Then you shall normalise $v_1,v_2$ and the new $v_3$.2017-01-24
1

To expand on the answer by user1551: Two eigenvalues of your $A$ are equal, and you have chosen two (correct) eigenvectors: Both $v_2$ and $v_3$ have eigenvalue $6$, but $v_2\cdot v_3\neq 0$, and the "spectral method" formula for $x$ requires orthonormal eigenvectors.

However, any linear combination of $v_2$ and $v_3$ will also be an eigenvector with eigenvalue $6$, so you can choose e.g. $v_2$ and $\tilde{v}_3=v_3+a v_2$ with a suitable $a$ so that $v_2\cdot \tilde{v}_3=0$ and continue from there.

  • 0
    I will try this thanks2017-01-24