0% found this document useful (0 votes)
17 views

Assignment-3

thapar assignment 3

Uploaded by

iprakashbe23
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views

Assignment-3

thapar assignment 3

Uploaded by

iprakashbe23
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Thapar Institute of Engineering & Technology, Patiala

Department of Mathematics
UMA021: Numerical Linear Algebra
Assignment 3
Matrix Algebra

1. Use Gaussian elimination with backward substitution and two-digit rounding arithmetic to solve the following
linear systems (do not reorder the equations). The exact solution to each system is x1 = −1, x2 = 1, x3 = 3.
(a)

−x1 + 4x2 + x3 = 8
5 2 2
x1 + x2 + x3 = 1
3 3 3
2x1 + x2 + 4x3 = 11

(b)

4x1 + 2x2 − x3 = −5
1 1 1
x1 + x2 − x3 = −1
9 9 3
x1 + 4x2 + 2x3 = 9

2. Using four-digit arithmetic, solve the following system of equations by Gaussian elimination with partial
pivoting:

0.729x1 + 0.81x2 + 0.9x3 = 0.6867


x1 + x2 + x3 = 0.8338
1.331x1 + 1.21x2 + 1.1x3 = 1.000

3. Use Gaussian elimination to solve the following systems and determine if row interchanges are necessary:

(a)

x1 − x2 + 3x3 = 2
3x1 − 3x2 + x3 = −1
x1 + x2 = 3

(b)

2x1 − x2 + x3 − x4 = 6
x2 − x3 + x4 = 5
x4 = 5
x3 − x4 = 3

4. Use LU factorization to solve the following systems:


(a)

2x1 − x2 + x3 = −1
3x1 + 3x2 + 9x3 = 0
3x1 + 3x2 + 5x3 = 4

(b)

x1 + x2 − x3 = 3
x1 + 2x2 − 2x3 = 2
−2x1 + x2 + x3 = 1

CONTINUED
–2–
5. Find l∞ and l2 norms of the vectors.
t
(a) x = 3, −4, 0, 32 .
t
(b) x = sin k, cos k, 2k for a fixed positive integer k.

6. Find the l∞ and l2 norm of the matrix:


 
4 −1 7
A = −1 4 0
−7 0 4

7. The following linear system Ax = b has x as the actual solution and x̃ as an approximate solution. Compute
kx − x̃k∞ and kAx̃ − bk∞ . Also compute kAk∞ .

x1 + 2x2 + 3x3 = 1
2x1 + 3x2 + 4x3 = −1
3x1 + 4x2 + 6x3 = 2
Here, actual solution: x = (0, −7, 5) , approximate solution: x̃ = (−0.2, −7.5, 5.4)t .
t

8. Find the first two iterations of Jacobi and Gauss-Seidel using ~x(0) = (0, 0, 0)t :

4.63x1 − 1.21x2 + 3.22x3 = 2.22,

−3.07x1 + 5.48x2 + 2.11x3 = −3.17,


1.26x1 + 3.11x2 + 4.57x3 = 5.11.

9. The linear system:


x1 − x3 = 0.2
1 1
− x1 + x2 − x3 = −1.425
2 4
1
x1 − x2 + x3 = 2
2
has the solution (0.9, −0.8, 0.7)t .

(a) Is the coefficient matrix strictly diagonally dominant?


(b) Compute the spectral radius of the Gauss-Seidel iteration matrix.
(c) Perform four iterations of the Gauss-Seidel iterative method to approximate the solution.
(d) What happens in part (c) when the first equation in the system is changed to x1 − 2x3 = 0.2?

10. Comment whether the Gauss-Seidel method can be applied for the following system of equations. If appli-
t
cable, perform two iterations, assuming the initial guess as ~x(0) = 0, 0, 0 .

12x1 + 3x2 − 5x3 = 1


x1 + 5x2 + 3x3 = 28
3x1 + 7x2 + 13x3 = 76

11. Compute the condition numbers of the following matrices relative to k · k∞ :

(a)  
0.03 58.9
5.31 −6.10

CONTINUED
–3–
(b)  
0.04 0.01 −0.01
 0.2 0.5 −0.2 
1 2 4

Answers: 1(a) ~x = (−0.7, 1.1, 2.9)t ; 1(b) ~x = (0.38, −2, 2.5)t ; (2) ~x = (0.2246, t
√ 0.2812, 0.3280) ; (3) do
t t k
it your self; 4(a) ~x = (1, 2, −1) ; 4(b) ~x = (4, 4, 5) ; 5(a) 4, 5.2202; 5(b) 2 , 1 + 4k 2 ; (6) 12, 8.2394;
(7) 0.5, 0.3, 13; (8) Jacobi: ~x(1) = (0.47948, −0.57847, 1.11816)t , ~x(2) = (−0.44934, −0.74039, 1.37962)t ,
Gauss-Seidel: ~x(1) = (0.47948, −0.30985, 1.19683)t , ~x(2) = (−0.43384, −1 : 28234, 2.11044)t ; 9. (a) No (b)
ρ(Tg ) = 0.625 (c) ~x(4) = (1.07090, −0.67183, 0.59319)t (d) Gauss-Seidel method will not converge(ρ(Tg ) =
1.375 > 1) (10) method will work (ρ(Tg ) = 0.18605 < 1), ~x(2) = (−0.13729, 3.93515, 3.75891)t (11) (a)
12.24, (b) 198.17.

You might also like