eigen-values, eigen-vectors qr factorization (1) · pdf filedominant eigen-value • let 1,...

17
EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) ELM1222 Numerical Analysis 1 Some of the contents are adopted from Laurene V. Fausett, Applied Numerical Analysis using MATLAB. Prentice Hall Inc., 1999 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Upload: tranmien

Post on 19-Mar-2018

235 views

Category:

Documents


3 download

TRANSCRIPT

Page 1: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

EIGEN-VALUES, EIGEN-VECTORS

QR FACTORIZATION (1)

ELM1222 Numerical Analysis

1

Some of the contents are adopted from

Laurene V. Fausett, Applied Numerical Analysis using MATLAB. Prentice Hall Inc., 1999

ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 2: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Eigen-values, Eigen-vectors

Why do we need eigen-values, eigen-vectors?

โ€ข Eigen-values and eigen-vectors give us useful and important information

about a matrix ( a special matrix representing a system, or a data):

Some examples:

1. determine whether or not a matrix is positive definite(matrix A is positive

definite if and only if the eigenvalues of A are positive)

2. determine whether or not a matrix is invertible as well as to indicate how

sensitive the determination of the inverse will be to numerical errors.

3. provide important representation for matrices known as the eigenvalue

decomposition

2 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 3: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Eigen-values, Eigen-vectors

โ€ข Eigenvalues of an matrix A are obtained by solving its

โ€ข characteristic equation

โ€ข ๐œ†๐‘› + ๐‘๐‘›โˆ’1๐œ†๐‘›โˆ’1 + ๐‘๐‘›โˆ’2๐œ†๐‘›โˆ’2 + โ‹ฏ + ๐‘1๐œ†1 + ๐‘0 = 0

โ€ข For large values of n, polynomial equations like this one are difficult and time-

consuming to solve.

โ€ข Moreover, numerical techniques for approximating roots of polynomial

equations of high degree are sensitive to rounding errors.

โ€ข We need alternative methods for approximating eigenvalues

โ€ข As presented here, the method can be used only to find the eigenvalue of A

that is largest in absolute value โ€”the dominant eigenvalue of A.

โ€ข Although this restriction may seem severe, dominant eigenvalues are of

primary interest in many physical applications.

3 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 4: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Dominant Eigen-value

โ€ข Let ๐œ†1, ๐œ†2, ๐œ†3,โ€ฆ, ๐œ†๐‘› be the eigen-values of an A matrix with size ๐‘›๐‘ฅ๐‘›.

โ€ข If the eigen values in magnitude will be sorted like

๐œ†1 < ๐œ†2 < ๐œ†3 < โ‹ฏ < ๐œ†๐‘› , ๐œ†๐‘› is called the dominant eigen-value

Example 1:

Find the dominant eigen value of the following matrix.

2 โˆ’121 โˆ’5

The characteristic equation will be

(2 โˆ’ ๐œ†)(โˆ’5 โˆ’ ๐œ†) + 12 = 0

โˆ’10 + 3 ๐œ† + ๐œ† 2 + 12 = 0

๐œ† = {โˆ’1, โˆ’2}

The dominant one is -2 and corresponding eigen-vector is ๐‘ฅ = ๐‘ก 3 1 ๐‘‡ where ๐‘ก โ‰  0

4 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 5: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

NUMERICAL TECHNIQUES FOR EIGEN-

VALUES, EIGEN-VECTOR APPROXIMATION

5 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Power Method

โ€ข Accelerated Power Method

โ€ข Shifted Power Method

โ€ข Inverse Power Method

Page 6: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Power Method

โ€ข Like the Jacobi and Gauss-Seidel methods, the power method for

approximating eigenvalues is iterative.

โ€ข We chose an initial approximation of one of the dominant eigenvectors of A.

โ€ข This initial approximation can be a nonzero vector z

โ€ข We will have

w = Az

If z is an eigen-vector, then for any component we will have

ฮป zk = wk

If z is not an eigen-vector we will use w as the next approximation of z but

in the scaled form such that the largest component of z will be 1

6 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 7: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Power Method

The iteration pattern will be as following;

w(1) = A z(1),

---

z(2) = w(1)

๐‘ค(1)๐‘˜

=A z(1)

๐‘ค(1)๐‘˜ w(2) = A z(2) = A

A z(1)

๐‘ค(1)๐‘˜

= A2 z(1)

๐‘ค(1)๐‘˜

,

z(3) =w(2)

๐‘ค(2)๐‘˜

=A z(2)

๐‘ค(2)๐‘˜

= A2 z(1)

๐‘ค(2)๐‘˜. ๐‘ค(1)

๐‘˜

w(3) = A z(3) = AA z(2)

๐‘ค(2)๐‘˜

= A3 z(1)

๐‘ค(2)๐‘˜. ๐‘ค(1)

๐‘˜

---

w(i) = A z(i), z(i) =w(i)

w(i)๐‘˜

7 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 8: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Power Method

Example 2:

Given the A matrix find the dominant eigen-value and corresponding eigen-

vector using Power method

8 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

๐ณ = 1 1 1 ๐‘‡ Initial eigen-vector

First Iteration

๐ฐ = ๐€๐ณ = 27 19 20 ๐‘‡ ๐ฐ๐Ÿ = 27

๐ณ = ๐ฐ/๐‘ค1 = 1.000 0.7037 0.7407 ๐‘‡

Second Iteration

๐ฐ = ๐€๐ณ = 25.1852 15.1111 16.0000 ๐‘‡ ๐ฐ๐Ÿ = 25.1852

๐ณ = ๐ฐ/๐‘ค1 = 1.000 0.6000 0.6353 ๐‘‡

Page 9: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Power Method

9 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Third Iteration

๐ฐ = ๐€๐ณ = 24.5647 13.6471 14.3059 ๐‘‡ ๐ฐ๐Ÿ = 24.5647

๐ณ = ๐ฐ/๐‘ค1 = 1.000 0.5556 0.5824 ๐‘‡

Fourth Iteration

๐ฐ = ๐€๐ณ = 24.3065 12.9655 13.4253 ๐‘‡ ๐ฐ๐Ÿ = 24.3065 ๐ณ = ๐ฐ/๐‘ค1 = 1.000 0.5334 0.5523 ๐‘‡

๐œ† โ‰… ๐‘ค1, ๐œ† = 24.3065

๐ณ = 1.000 0.5334 0.5523 ๐‘‡

๐€๐ณ โˆ’ ฮป๐ณ = โˆ’0.1249 โˆ’0.3653 โˆ’0.5123 ๐‘‡

๐€๐ณ โˆ’ ฮป๐ณ โˆž = 0.5123

Page 10: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Accelerated Power Method

โ€ข In some cases, when A is symmetric power method with

โ€ข Rayleigh quotient converges more rapidly than classic power method.

โ€ข If x is an eigen-vector matrix A then its corresponding eigenvalue is given by

ฮป =๐‘ง๐‘‡Az

๐‘ง๐‘‡. z=

๐‘ง๐‘‡w

๐‘ง๐‘‡. z

โ€ข This is called Rayleigh quotient

10 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 11: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Accelerated Power Method

Example 3:

Given the A matrix find the dominant eigen-value and corresponding eigen-

vector using Rayleigh quotient

11 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 12: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Shifted Power Method

โ€ข If we already know an eigenvalue ฮป of a matrix A , we can find another

eigenvalue of A by applying the power method to the matrix B = A โˆ’ฮปI .

โ€ข Denote the dominant eigenvalue of the shifted matrix B as ฮผ

Example 4

If one eigen-value of the following matrix is 6 to find another eigen value apply

power method to the shifted matrix

12 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 13: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Shifted Power Method

13 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Initialize iterations with

๐ณ = 1 1 1 ๐‘‡

Apply Rayleigh quotient approximation

First Iteration

๐ฐ = ๐๐ณ = โˆ’3 โˆ’5 0 ๐‘‡

๐œ‡ =๐ณT๐ฐ

๐ณT๐ณ= โˆ’

3

8

w2 = โˆ’5 ๐ณ = ๐ฐ/๐‘ค2 = 3/5 1 0 ๐‘‡

Second Iteration

๐ฐ = ๐๐ณ = โˆ’13/5 โˆ’21/5 0 ๐‘‡

๐œ‡ =๐ณT๐ฐ

๐ณT๐ณ= โˆ’

72

17

w2 = โˆ’21

5

๐ณ = ๐ฐ/๐‘ค2 = 13/21 1 0 ๐‘‡

๐€๐ณ โˆ’ ฮป๐ณ ๐Ÿ < 0.0001 we can use this as a stopping criterion

Page 14: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Inverse power method

โ€ข Provides an estimate of the eigenvalue of A that is of smallest magnitude

โ€ข Based on the fact that eigenvalues of B = Aโˆ’1 are the reciprocals of the

eigenvalues of A.

โ€ข Thus, we apply the power method to B = Aโˆ’1 to find its dominant eigenvalue

ฮผ .

โ€ข Then, reciprocal of ฮผ (i.e. ๐œ† = 1/๐œ‡) will give the smallest magnitude.

โ€ข It is not desirable to actually compute Aโˆ’1 .instead where the power method

is normally Aโˆ’1 z = w, we will use the form A w = z

14 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Page 15: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Inverse power method

Example 5: Given the following A matrix calculate the smallest eigen value

using inverse Power Method

15 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Initialize iterations with

๐ณ = 1 1 1 ๐‘‡

First Iteration

๐€๐ฐ = ๐ณ ๐ฐ = 0.0286 0.0651 0. 0573 ๐‘‡

๐œ‡ =๐‘ค2

๐‘ง2= 0.0651

๐œ† =1

๐œ‡= 15.3601

w2 = โˆ’5 ๐ณ = ๐ฐ/๐‘ค2 = 0.4400 1 0.8801 ๐‘‡

Page 16: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Inverse power method

16 ELM1222 Numerical Analysis | Dr Muharrem Mercimek

Second Iteration

๐€๐ฐ = ๐ณ ๐ฐ = 0.0042 0.0842 0. 0617 ๐‘‡

๐œ‡ =๐‘ค2

๐‘ง2= 0.0842

(๐‘ค2 is the largest component of w)

๐œ† =1

๐œ‡= 11.8777

๐ณ = ๐ฐ/๐‘ค2 = โˆ’0.0495 1 0.7324 ๐‘‡

Third Iteration

๐€๐ฐ = ๐ณ ๐ฐ = โˆ’0.0336 0.1029 0. 0639 ๐‘‡

๐œ‡ =๐‘ค2

๐‘ง2= 0.1029

๐œ† =1

๐œ‡= 9.7153

The largest eigen-value for ๐€โˆ’1

The smallest eigen-value for A

Page 17: EIGEN-VALUES, EIGEN-VECTORS QR FACTORIZATION (1) · PDF fileDominant Eigen-value • Let 1, 2, 3,, ๐‘› be the eigen-values of an A matrix with size ๐‘› ๐‘›. • If the eigen values

Summary of Distance Metrics

17 ELM1222 Numerical Analysis | Dr Muharrem Mercimek