Question 9.3: POWER METHODS Find all eigenvalues and eigenvectors of the f...
POWER METHODS
Find all eigenvalues and eigenvectors of the following matrix using the power, shifted inverse power, and shifted power methods:
\mathbf{A}=\left[\begin{array}{cccc} 4 & -3 & 3 & -9 \\ -3 & 6 & -3 & 11 \\ 0 & 8 & -5 & 8 \\ 3 & -3 & 3 & -8 \end{array}\right], \quad \mathbf{x}_{1}=\left\{\begin{array}{l} 0 \\ 1 \\ 0 \\ 1 \end{array}\right\}
Learn more on how do we answer questions.
Apply the user-defined function PowerMethod to find the dominant eigenvalue of A:
>> A = [4 −3 3 −9;−3 6 −3 11;0 8 −5 8;3 −3 3 −8];
>> x1 = [0;1;0;1]; % Initial vector
>> [e_val, e_vec] = PowerMethod(A, x1) % Default values for tol and kmax
e_val =
−5.0000 % Dominant eigenvalue
e_vec =
0.5000
−0.5000
−0.5000
0.5000
The smallest magnitude eigenvalue of \mathbf{A} can be estimated by either applying the power method to \mathbf{A}^{-1} (see Example 9.2) or by applying the shifted inverse power method to \mathbf{A} with \alpha=0.
>> [e_val, e_vec] = ShiftInvPower(A, 0, x1)
e_val =
1.0001 % Smallest magnitude eigenvalue
e_vec =
−0.8165
0.4084
0.0001
−0.4082
The largest and smallest eigenvalues of \mathbf{A} are therefore -5 and 1, respectively. To see if the remaining two eigenvalues are between these two values, we set \alpha to be the average, \alpha=(-5+1) / 2=-2, and apply the shifted inverse power method. However, \alpha=-2 causes \mathbf{A}-\alpha \mathbf{I} to be singular, meaning \alpha is an eigenvalue of \mathbf{A}. Since we also need the eigenvector associated with this eigenvalue, we set \alpha to a value close to -2 and apply the shifted inverse power:
>> [e_val, e_vec] = ShiftInvPower(A, −1.5, x1) % alpha=−1.5
eigenval =
−2.0000 % Third eigenvalue
eigenvec =
0.5774
−0.5774
0.0000
0.5774
We find the fourth eigenvalue using the shifted power method. Knowing \lambda=-2 is an eigenvalue of \mathbf{A}, we apply the power method to \mathbf{A}+2 \mathbf{I} :
>> A1 = A + 2*eye(4,4);
>> [e_val, e_vec] = PowerMethod(A1, x1)
e_val =
5.0000 % Fourth eigenvalue = 5+(−2)=3
e_vec =
−0.0000
0.7071
0.7071
0.0000
By the reasoning behind the shifted power method, the fourth eigenvalue is \lambda=-2+5=3. In summary, all four eigenvalues and their eigenvectors are
\lambda_{1}=-5, \mathbf{v}_{1}=\left\{\begin{array}{l} 1 \\ -1 \\ -1 \\ 1 \end{array}\right\}, \quad \lambda_{2}=1, \mathbf{v}_{2}=\left\{\begin{array}{l} -2 \\ 1 \\ 0 \\ -1 \end{array}\right\}, \quad \lambda_{3}=-2, \mathbf{v}_{3}=\left\{\begin{array}{l} 1 \\ -1 \\ 0 \\ 1 \end{array}\right\}, \quad \lambda_{4}=3, \mathbf{v}_{4}=\left\{\begin{array}{l} 0 \\ 1 \\ 1 \\ 0 \end{array}\right\}