Docsity

Numerical Linear Algebra: Inverse & Rayleigh Iteration, Condition & Perturbation, Slides of Advanced Computer Architecture

Partial preview of the text

Download Numerical Linear Algebra: Inverse & Rayleigh Iteration, Condition & Perturbation and more Slides Advanced Computer Architecture in PDF only on Docsity!

  • Lecture

Overview

Inverse iteration Rayleigh quotient iteration Condition Perturbation Stability

Inverse iteration (cont’d)

what if μ is or nearly is an eigenvalue of A, so that A − μI is singular? can be handled numerically exhibit linear convergence unlike power iteration, we can choose the eigenvector that will be found by supplying an estimate μ of the corresponding eigenvalue if μ is much closer to one eigenvalue of A than to the others, then the largest eigenvalue o (A − μI )−^1 will be much larger than the rest

Theorem

Suppose λJ is the closest eigenvalue of μ and λK is the second closest, that is |μ − λJ | < |μ − λK | < |μ − λj | for each j 6 = J. Furthermore, suppose q> J v(0)^6 = 0, then after k iterations

‖v(k)^ − (±qJ )‖ = O

∣ (^) μμ−−λλKJ

k

, |λ(k)^ − λJ | = O

∣ (^) μμ−−λλJK

2 k

as k → ∞. The ± sign means that at each step k, one or the other choice of sign is to be taken, and then the indicated bound holds

Inverse iteration and Rayleigh quotient iteration

Inverse iteration: I (^) one of the most valuable tools of numerical linear algebra I (^) a standard method of calculating one or more eigenvectors of a matrix if the eigenvalues are already known Obtaining an eigenvalue estimate from an eigenvector estimate (the Rayleigh quotient) Obtaining an eigenvector estimate from an eigenvalue estimate (inverse iteration) Rayleigh quotient algorithm:

Initialize v(0)^ randomly with ‖v(0)‖ = 1 λ(0)^ = (v(0))>Av(0)^ = corresponding Rayleigh quotient for k = 1, 2 ,... do Solve w = (A − λ(k−1)I )−^1 v(k−1)^ // apply (A − μ(k−1)I )−^1 v(k)^ = (^) ‖ww‖ // normalize λ(k)^ = (v(k))>Av(k)^ // Rayleigh quotient end for

Example

Consider the symmetric matrix

A =

and let v(0)^ = (1, 1 , 1)>/

3 the initial eigenvector estimate When Rayleigh quotient iteration is applied to A, the following values λ(k)^ are computed by the first 3 iterations: λ(0)^ = 5, λ(1)^ = 5. 2131... , λ(2)^ = 5. 214319743184...

The actual value of the eigenvalue corresponding to the eigenvector closest to v(0)^ is λ = 5. 214319743377 After three iterations, Rayleigh quotient iteration has produced a result accurate to 10 digits With three more iterations, the solution increases this figure to about 270 digits, if our machine precision were high enough

Operation counts

Flops (floating point operations): addition, subtraction, multiplication, division, or square root counts as one flop Suppose A ∈ IRm×m^ is a full matrix, each step of power iteration involves a matrix-vector multiplication, requiring O(m^2 ) flops Each step of inverse iteration involves the solution of a linear system, which might seem to require O(m^3 ) flops, but this can be reduced to O(m^2 ) if the matrix is processed in advance by LU or QR factorization In Rayleigh quotient iteration, the matrix to be inverted changes at each step, and beating O(m^3 ) flops per step These figures improve greatly if A is tridiagonal, and all three iterations requires just O(m) flops per step For non-symmetric matrices, we must deal with Hessenberg instead of tridiagonal structure, and this figure increases to O(m^3 )

Absolute condition number

Let δx denote a small perturbation of x and write δf = f (x + δx) − f (x) Absolute condition number: ˆκ = ˆκ(x) = lim δ→ 0 sup ‖δx‖≤δ

‖δf ‖ ‖δx‖ For most problems, it can be interpreted as a supremum over all infinitesimal perturbations δx, and can write simply as

κˆ = sup δx

‖δf ‖ ‖δx‖ If f is differentiable, we can evaluate the condition number by means of the derivative of f Let J(x) be the matrix whose i, j entry is the partial derivative ∂fi /∂xj evaluated at x, known as the Jacobian of f at x By the definition, δf ≈ J(x)δx with ‖δx‖ → 0, and the absolute condition number becomes κˆ = ‖J(x)‖

where ‖J(x)‖ represents the norm of J(x) Docsity.com11 / 21

Relative condition number

Relative condition number:

κ = lim δ→ 0 sup ‖δx‖≤δ

‖δf ‖ ‖f (x)‖

‖δx‖ ‖x‖

Again, assume δx and δf are infinitesimal,

κ = sup δx

‖δf ‖ ‖f (x)‖

‖δx‖ ‖x‖

If f is differentiable, we can express this in terms of Jacobian

κ =

‖J(x)‖ ‖f (x)‖/‖x‖

Relative condition number is more important in numerical analysis A problem is well-conditioned if κ is small (e.g., 1, 10, 10^2 ), and ill-conditioned if κ is large (e.g., 10^6 , 10^16 )

Computing eigenvalues of a non-symmetric matrix

Computing the eigenvalues of a non-symmetric matrix is often ill-conditioned Consider the two matrices

A =

[

]

B =

[

]

whose eigenvalues are { 1 , 1 } and { 0 , 2 } respectively On the other hand, if a matrix A is symmetric (more generally, if it is normal), then its eigenvalues are well-conditioned It can be shown that if λ and λ + δλ are corresponding eigenvalues of A and A + δA, then |δλ| ≤ ‖δA‖ 2 with equality if δA is a multiple of the identity In that case, ˆκ = 1 if perturbations are measured in the 2-norm and the relative condition number is κ = ‖A‖ 2 /|λ|

Condition of matrix-vector multiplication

Consider A ∈ Cm×n, determine a condition number corresponding to perturbations of x

κ =

δx

‖A(x + δx) − Ax‖ ‖Ax‖

‖δx‖ ‖x‖

= sup δx

‖Aδx‖ ‖δx‖

‖Ax‖ ‖x‖

that is κ = ‖A‖ ‖x‖ ‖Ax‖

(κ = ‖J(x)‖ ‖f (x)‖/‖x‖

which is an exact formula for κ, dependent on both A and x If A happens to be square and non-singular, we can use the fact that ‖x‖/‖Ax‖ ≤ ‖A−^1 ‖ to loosen the bound

κ ≤ ‖A‖‖A−^1 ‖,

or κ = α‖A‖‖A−^1 ‖, α = ‖x‖ ‖Ax‖

‖A−^1 ‖

Condition of matrix-vector multiplication (cont’d)

Theorem

Let A ∈ Cm×n^ be nonsingular and consider the equation Ax = b. The problem of computing b given x, has condition number

κ = ‖A‖ ‖x‖ ‖b‖

≤ ‖A‖‖A−^1 ‖ (1)

with respect to perturbation of x. The problem of computing x given b, has condition number

κ = ‖A−^1 ‖ ‖b‖ ‖x‖

≤ ‖A‖‖A−^1 ‖ (2)

with respect to perturbation of b. If we use 2-norm, then the equality holds in (1) if x is a multiple of a right singular vector of A corresponding to the minimal singular value σm. Likewise, the equality hold in (2) if b is a multiple of a left singular vector of A corresponding to the maximal singular value σ 1.

Condition number of a matrix

The product ‖A‖‖A−^1 ‖ is the condition number of A (relative to the norm ‖ · ‖), denoted by κ(A)

κ(A) = ‖A‖‖A−^1 ‖

The condition number is attached to a matrix, not a problem If κ(A) is small, A is said to be well-conditioned; if κ(A) is large, A is ill-conditioned. If A is singular, it is customary to write κ(A) = ∞ If ‖ · ‖ = ‖ · ‖ 2 , then ‖A‖ = σ 1 , and ‖A−^1 ‖ = 1/σm, and thus

κ(A) = σ 1 σm in the 2-norm, which is the formula for computing 2-norm condition numbers of matrices. The ratio σ 1 /σm can be interpreted as the eccentricity of the hyperellipse that is the image of the unit sphere of Cm^ under A

Condition number of a system of equations

Let b be fixed, and consider the behavior of the problem A 7 → x = A−^1 b when A is perturbed by infinitesimal δA, then

(A + δA)(x + δx) = b

Using Ax = b and dropping the term (δA)(δx), we obtain (δA)x + A(δx) = 0, that is, δx = −A−^1 (δA)x It implies ‖δx‖ ≤ ‖A−^1 ‖‖δA‖‖x‖, or equivalently

‖δx‖ ‖x‖

‖δA‖ ‖A‖

≤ ‖A−^1 ‖‖A‖ = κ(A)

The equality in this bound will hold when δA is such that

‖A−^1 (δA)x‖ = ‖A−^1 ‖‖δA‖‖x‖

and it can be shown that for any A and b and norm ‖ · ‖, such perturbations of δA exists

Condition number of a system of equations (cont’d)

Theorem

Let b be fixed and consider the problem of computing x = A−^1 b where A is square and nonsingular. The condition number of this problem with respect to perturbation in A is

κ = ‖A‖‖A−^1 ‖ = κ(A)

Both theorems regarding matrix-vector multiplication and system of equations are of fundamental importance in numerical linear algebra They determine how accurately one can solve systems of equations If a problem Ax = b contains an ill-conditioned matrix A, one must always expect to “lose log 10 κ(A) digits” in computing the solution (except under very special cases)