9
1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made on Jacobi Method: 1. The system given by Has a unique solution. 2. The coefficient matrix has no zeros on its main diagonal, namely, , are nonzeros. Main idea of Jacobi To begin, solve the 1 st equation for , the 2 nd equation for and so on to obtain the rewritten equations: Then make an initial guess of the solution . Substitute these values into the right hand side the of the rewritten equations to obtain the first approximation, ( ) This accomplishes one iteration. In the same way, the second approximation ( ) is computed by substituting the first approximation’s - vales into the right hand side of the rewritten equations. By repeated iterations, we form a sequence of approximations ( )

7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

  • Upload
    vancong

  • View
    224

  • Download
    1

Embed Size (px)

Citation preview

Page 1: 7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

1

7.3 The Jacobi and Gauss-Seidel Iterative Methods

The Jacobi Method

Two assumptions made on Jacobi Method:

1. The system given by

Has a unique solution.

2. The coefficient matrix has no zeros on its main diagonal, namely, , are nonzeros.

Main idea of Jacobi

To begin, solve the 1st equation for , the 2

nd equation for and so on to obtain the rewritten equations:

Then make an initial guess of the solution

. Substitute these values into the right hand side the of

the rewritten equations to obtain the first approximation, (

)

This accomplishes one iteration.

In the same way, the second approximation (

) is computed by substituting the first approximation’s -

vales into the right hand side of the rewritten equations.

By repeated iterations, we form a sequence of approximations (

)

Page 2: 7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

2

The Jacobi Method. For each generate the components

of from by

[

]

Example. Apply the Jacobi method to solve

Continue iterations until two successive approximations are identical when rounded to three significant digits.

Solution To begin, rewrite the system

Choose the initial guess

The first approximation is

Page 3: 7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

3

Continue iteration, we obtain

0.000 -0.200 0.146 0.192

0.000 0.222 0.203 0.328

0.000 -0.429 -0.517 -0.416

When to stop: 1.

; or 2 || || . Here is a given small number .

The Jacobi Method in Matrix Form

Consider to solve an size system of linear equations with [

] and [

] for [

].

We split into

[

] [

] [

]

is transformed into

Assume exists and

[

]

Page 4: 7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

4

Then

The matrix form of Jacobi iterative method is

Define and Jacobi iteration method can also be written as

Numerical Algorithm of Jacobi Method

Input: , , tolerance TOL, maximum number of iterations .

Step 1 Set

Step 2 while ( ) do Steps 3-6

Step 3 For

[∑

]

Step 4 If | | , then OUTPUT ( );

STOP.

Step 5 Set

Step 6 For

Set

Step 7 OUTPUT ( );

STOP.

Another stopping criterion in Step 4:

Page 5: 7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

5

The Gauss-Seidel Method

Main idea of Gauss-Seidel

With the Jacobi method, only the values of

obtained in the th iteration are used to compute

. With the Gauss-Seidel

method, we use the new values

as soon as they are known. For example, once we have computed

from the first

equation, its value is then used in the second equation to obtain the new

and so on.

Example. Derive iteration equations for the Jacobi method and Gauss-Seidel method to solve

Choose the initial guess

0.000 -0.200 0.167

0.000 0.156 0.334

0.000 -0.508 -0.429

The Gauss-Seidel Method. For each generate the components

of from by

[ ∑

]

Namely,

Page 6: 7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

6

Matrix form of Gauss-Seidel method.

Define and , Gauss-Seidel method can be written as

Numerical Algorithm of Gauss-Seidel Method

Input: , , tolerance TOL, maximum number of iterations .

Step 1 Set

Step 2 while ( ) do Steps 3-6

Step 3 For

[ ∑

]

Step 4 If | | , then OUTPUT ( );

STOP.

Step 5 Set

Step 6 For

Set

Step 7 OUTPUT ( );

STOP.

Page 7: 7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

7

Convergence theorems of the iteration methods

Let the iteration method be written as

Lemma 7.18 If the spectral radius satisfies , then exists, and

Theorem 7.19 For any , the sequence defined by

converges to the unique solution of if and only if

Proof (only show is sufficient condition)

( )

Since

Corollary 7.20 If | | for any natural matrix norm and is a given vector, then the sequence defined by

converges, for any , to a vector with , and the following error bound hold:

(i) | | | | | |

(ii) | | | |

| |

Page 8: 7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

8

Theorem 7.21 If is strictly diagonally dominant, then for any choice of , both the Jacobi and Gauss-Seidel methods give

sequences that converges to the unique solution of .

Rate of Convergence

Corollary 7.20 (i) implies | | | |

Theorem 7.22 (Stein-Rosenberg) If for each and , for each , then one and only one of

following statements holds:

(i) ( ) ( )

(ii) ( ) ( )

(iii) ( ) ( )

(iv) ( ) ( )

Page 9: 7.3 The Jacobi and Gauss-Seidel Iterative Methods The ...zxu2/acms40390F13/Lec-7.3.pdf · 1 7.3 The Jacobi and Gauss-Seidel Iterative Methods The Jacobi Method Two assumptions made

9

Simple iteration

Assume there is an initial guess for the solution to . If one could compute the error , then one

could find the solution . However, is expensive to compute.

Instead, let’s compute the residual . Note that .

If is a matrix with the property that approximates the identity, yet is easy to solve for , one could

approximate the error by .

Thus, one solve for , which approximates , and then replace by . Repeat this

process with .

Simple iteration algorithm

Given an initial guess , compute , and solve for .

Set .

Compute .

Solve for .

Remark:

1. For , the method is Jacobi iteration

( ) ,

2. For , the method is GS.

( )