homework代写 | math – math

math

homework代写 | math – 这个题目属于一个math的代写任务, 包括了math等方面, 该题目是值得借鉴的homework代写的题目

homework代写 代写homework hw代做

 math 5640/6640 - Introduction to Numerical Analysis II
Thi-Thao-Phuong Hoang, Spring 2022
 homework 6, DueFriday, Mar 25

There are totally 4 problems (2 pages).Submit the code for Problems 2 and 3 in the appendix.

Problem 1 [25 points](Pen and paper) Consider solving the linear systemAxxx=bbbiteratively, where

A=

3 2 1

1 2 1

1 1 3

 and bbb=

1

2

1

.

(a) Apply the Jacobi iterative method with initial guessxxx 0 = [1 0 0]T. Compute the first two
iteratesxxx 1 andxxx 2.
(b) Apply the Gauss-Seidel iterative method with initial guessxxx 0 = [1 0 0]T. Compute the first
iteratexxx 1.

Problem 2 25 points Write the code to perform Jacobi and Gauss-Seidel methods for solving the linear system in Problem 1. Usingrrrk 2 < 10 ^6 as the stopping criteria for both methods. Print out the residual normrrrk 2 for all iterations and the final solution.

Problem 3 25 points Consider solving the linear systemAxxx=bbbiteratively, where

A=

4 3 0

3 4 1

0 1 4

 and bbb=

2

1

0

.

(a) Letbe a vector given by= 1 : 0.05 : 1.95 = [1 1.05 1. 10... 1 .95]. Denote byjthejth
entry in the vector, for 1j20. For eachj, apply the successive over-relaxation (SOR)
method to solve the linear system with the relaxation parameteri. Usingrrrk 2 < 10 ^8 as
the stopping criteria and record the total iteration numbers neededNjto achieve the desired
tolerance for eachj.
  • Print out total iteration numbersNjfor allj.
  • What is the corresponding relaxation parameterjwhenNjobtains the minimum?
(b) What is the optimal relaxation parameteroptfor the SOR method for solving this linear
system? Compare the valueoptwith the optimal relaxation parameterjobtained in (a).

Problem 4 [25 points](Paper and pen) Consider solving the linear system Axxx = bbbby the stationary iterative method

xxxk+1=xxxk+M^1 (bbbAxxxk) =Txxxk+M^1 bbb,

1

whereT=IM^1 Ais the iteration matrix. Let

A=

4 2 1

2 6 2

1 2 5

 and bbb=

1

0

1

.

(a) Calculate the normsTandT 1 when the Jacobi method is applied. Will the Jacobi
method converge? Justify your answer properly.
(b) Calculate the normsTandT 1 when the Gauss-Seidel method is applied. Will the
Gauss-Seidel method converge? Justify your answer properly.

2