Anda di halaman 1dari 7

632 C HAP.

11 E IGENVALUES AND E IGENVECTORS

Q R Method
Suppose that A is a real symmetric matrix. In the preceding section we saw how
Householders method is used to construct a similar tridiagonal matrix. The Q R
method is used to find all eigenvalues of a tridiagonal matrix. Plane rotations similar
to those that were introduced in Jacobis method are used to construct an orthogonal
matrix Q 1 = Q and an upper-triangular matrix U 1 = U so that A1 = A has the
factorization
(34) A1 = Q 1 U 1 .
Then form the product
(35) A2 = U 1 Q 1 .
Since Q 1 is orthogonal, we can use (34) to see that
(36) Q 1 A1 = Q 1 Q 1 U 1 = U 1 .
Therefore, A2 can be computed with the formula
(37) A2 = Q 1 A1 Q 1 .

Since Q 1 = Q 1
1 , it follows that A2 is similar to A1 and has the same eigenvalues. In
general, construct the orthogonal matrix Q k and upper-triangular matrix U k so that
(38) Ak = Q k U k .
S EC . 11.4 E IGENVALUES OF S YMMETRIC M ATRICES 633

Then define

(39) Ak+1 = U k Q k = Q k Ak Q k .

Again, we have Q k = Q 1
k , which implies that Ak+1 and Ak are similar. An important
consequence is that Ak is similar to A and hence has the same structure. Specifically,
we can conclude that if A is tridiagonal then Ak is also tridiagonal for all k. Now
suppose that A is written as

d1 e1
e1 d2 e2

e2 d3

(40) A= .. .
. d e
n2 n2
en2 dn1 en1
en1 dn

We can find a plane rotation P n1 that reduces to zero the element of A in location
(n, n 1), that is,

d1 e1
e1 d2 e2

e2 d3

(41) P n1 A = .. .
. d q r
n2 n2 n2
en2 pn1 qn1
0 pn

Continuing in a similar fashion, we can construct a plane rotation P n2 that will


reduce to zero the element of P n1 A located in position (n 1, n 2). After n 1
steps we arrive at

p1 q1 r1

0 p2 q2 . . .


0 0 p3 . . . rn4

(42) P 1 P n1 A = .. . . = U.
. . q r
n3 n3
p q r
n2 n2 n2
0 pn1 qn1
0 0 pn

Since each plane rotation is represented by an orthogonal matrix, equation (42) implies
that

(43) Q = P n1 P n2 P 1 .


634 C HAP. 11 E IGENVALUES AND E IGENVECTORS

Direct multiplication of U by Q will produce all zero elements below the lower
second diagonal. The tridiagonal form of A2 implies that it also has zeros above the
upper second diagonal. Investigation will reveal that the terms r j are used only to
compute these zero elements. Consequently, the numbers {r j } do not need to be stored
or used in the computer.
For each plane rotation P j it is assumed that we store the coefficients c j and s j
that define it. Then we do not need to compute and store Q explicitly; instead, we
can use the sequences {c j } and {s j } together with the correct formulas to unravel the
product

(44) A2 = U Q = U P n1 P n2 P 1 .

Acceleration Shifts
As outlined above the Q R method will work, but convergence is slow even for ma-
trices of small dimension. We can add a shifting technique that speeds up the rate of
convergence. Recall that if j is an eigenvalue of A, then j si is an eigenvalue of
the matrix B = A si I. This idea is incorporated in the modified step

(45) Ai si I = U i Q i ;

then form

(46) Ai+1 = U i Q i for i = 1, 2, . . . , k j ,

where {si } is a sequence whose sum is j ; that is, j = s1 + s2 + + sk j .


At each stage the correct amount of shift is found by using the four elements in the
lower-right corner of the matrix. Start by finding 1 and compute the eigenvalues of
the 2 2 matrix
 
dn1 en1
(47) .
en1 dn

They are x1 and x2 and are the roots of the quadratic equation

(48) x 2 (dn1 + dn )x + dn1 dn en1 en1 = 0.

The value si in equation (45) is chosen to be the root of (48) that is closest to dn .
Then Q R iterating with shifting is repeated until we have en1 0. This will
produce the first eigenvalue 1 = s1 + s2 + + sk1 . A similar process is repeated with
the upper n 1 rows to obtain en2 0, and the next eigenvalue is 2 . Successive iter-
ation is applied to smaller submatrices until we obtain e2 0 and the eigenvalue n2 .
Finally, the quadratic formula is used to find the last two eigenvalues. The details can
be gleaned from Program 11.5
S EC . 11.4 E IGENVALUES OF S YMMETRIC M ATRICES 635

Example 11.9. Find the eigenvalues of the matrix



4 2 2 1
2 3 1 1
M = 2
.
1 3 1
1 1 1 2
In Example 11.8, a tridiagonal matrix A1 was constructed that is similar to M. We start
our diagonalization process with this matrix:

4 3 0 0
3 2 3.16228 0
A1 = 0
.
3.16228 1.4 0.2
0 0 0.2 1.4
The four elements in the lower right corner are d3 = 1.4, d4 = 1.4, and e3 = 0.2 and
are used to form the quadratic equation
x 2 (1.4 + 1.4)x + (1.4)(1.4) (0.2)(0.2) = x 2 2 = 0.
Calculation produces the roots x1 = 1.41421 and x2 = 1.41421. The root closest to d4
is chosen as the first shift s1 = 1.41421, and the first shifted matrix is

2.58579 3 0 0
3 0.58579 1.74806 0
A1 s1 I = 0
.
1.74806 2.81421 1.61421
0 0 1.61421 0.01421
Next, the factorization A1 s1 I = Q 1 U 1 is computed:

0.65288 0.38859 0.55535 0.33814
0.75746 0.33494 0.47867 0.29145
Q1 U 1 = 0

0.85838 0.43818 0.26610
0 0 0.52006 0.85413

3.96059 2.40235 2.39531 0
0 3.68400 3.47483 0.17168
0
.
0 0.38457 0.08024
0 0 0 0.06550
Then the matrix product is computed in the reverse order to obtain

4.40547 2.79049 0 0
2.79049 4.21663 0.33011 0
A2 = U 1 Q 1 = 0
.
0.33011 0.21024 0.03406
0 0 0.03406 0.05595
The second shift is s2 = 0.06024, the second shifted matrix is A2 s2 I = Q 2 U 2 , and

4.55257 2.65725 0 0
2.65725 4.26047 0.01911 0
A3 = U 2 Q 2 = 0
.
0.01911 0.29171 0.00003
0 0 0.00003 0.00027
636 C HAP. 11 E IGENVALUES AND E IGENVECTORS

The third shift is s3 = 0.00027, the third shifted matrix is A3 s3 I = Q 3 U 3 , and



4.62640 2.53033 0 0
2.53033 4.33489 0.00111 0
A4 = U 3 Q 3 = 0
.
0.00111 0.29150 0
0 0 0 0

The first eigenvalue, rounded to five decimal places is given in the calculation

1 = s1 + s2 + s3 = 1.41421 0.06023 + 0.00027 = 1.35425.

Next 1 is placed in the last diagonal position of A4 and the process is repeated, but
changes are made only in the upper 3 3 corner of the matrix

4.62640 2.53033 0 0
2.53033 4.33489 0.00111 0
A4 = 0
.

0.00111 0.29150 0
0 0 0 1.35425

In a similar manner, one more shift reduces the entry in the second row and third
column to zero (to 10 decimal places):

s4 = 0.29150, A4 s4 I = Q 4 U 4 , A5 = U 4 Q 4 .

Hence the second eigenvalue is

2 = 1 + s4 = 1.35425 + 0.29150 = 1.64575.

Finally, 2 is placed on the diagonal of A5 in the third row and column to obtain

4.26081 2.65724 0 0
2.65724 4.55232 0 0
A5 = 0
.

0 1.64575 0
0 0 0 1.35425

The final computation requires finding the eigenvalues of the 2 2 matrix in the upper-left
corner of A5 . The characteristic equation is

x 2 (4.26081 + 4.55232)x + (4.26081)(4.55232) (2.65724)(2.65724) = 0,

which reduces to
x 2 + 0.29151x 26.45749 = 0.
The roots are x1 = 5.00000 and x2 = 5.29150, and the last two eigenvalues are computed
with the calculations

3 = 2 + x1 = 1.64575 + 5.0000 = 6.64575


and
4 = 2 + x2 = 1.64575 5.29150 = 3.64575. 
S EC . 11.4 E IGENVALUES OF S YMMETRIC M ATRICES 637

Program 11.5 can be used to approximate all the eigenvalues of a symmetric tridi-
agonal matrix. The program follows directly from the previous discussion, but with
two notable exceptions. First, the MATLAB command eig is used to find the roots
of the characteristic equation (48) of each 2 2 submatrix (47). Second, the Q R
factorization of the matrix Ai si I (45) is executed using the MATLAB command
[Q,R]=qr(B), which produces an orthogonal matrix Q and an upper-triangular matrix
R, such that B=Q*R (readers will be asked to write their own Q R factorization program).
Numerical Methods Using Matlab, 4th Edition, 2004
John H. Mathews and Kurtis K. Fink
ISBN: 0-13-065248-2

Prentice-Hall Inc.
Upper Saddle River, New Jersey, USA
http://vig.prenhall.com/

Anda mungkin juga menyukai