Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

Monsoon 2023-2024

CHC503
Computational Techniques in Chemical Engineering

Assignment 2
on
Numerical solution of system of linear algebraic equations

Total number of problems: 7

1. Consider the following system of linear equations:

x1  x2  x3  3
6 x1  2 x2  2 x3  2
3x1  4 x2  x3  1
Solve the above system by

(a) Naive Gauss elimination (i.e., Gauss elimination without any pivoting)
(b) Gauss elimination with partial pivoting
(c) Gauss-Jordan elimination without partial pivoting
All the steps of computation should be clear and evident. In each case [(a)-(c)
above], substitute the results back into the original equations in order to check the
accurateness of the obtained solutions.
(d) Represent the above system of equations in the matrix form AX=B, and calculate
the condition number of the matrix A thus obtained. For calculating the norms, use
row-sum norm (i.e., A  ), column-sum norm (i.e., A 1 ) and Frobenius norm (also
known as Euclidean norm i.e., A e ) approaches, and evaluate the condition number
for each of these approaches. Is the system ill-conditioned?
(e) Obtain the inverse of matrix A, using the augmented matrix approach while
performing naive Gauss elimination.
(f) Can LU decomposition (Doolittle decomposition variant) method be employed for
solving the above system? Explain your answer, and if the answer is YES, solve it
using LU decomposition method.
(g) Can Thomas algorithm be employed for solving the above system? Explain your
answer, and if the answer is YES, solve it using Thomas algorithm.
(h) Can Cholesky decomposition method be employed for solving the above system?
Explain your answer, and if the answer is YES, solve it using Cholesky
decomposition method.

1
2. Solve the following system of equations by LU decomposition method (Doolittle
decomposition variant):

3x1  2 x2  x3  10
2 x1  6 x2  4 x3  44
 x1  2 x2  5 x3  26

3. Solve the following system of equations by LU decomposition method (Doolittle


decomposition variant) with partial pivoting

2 x1  6 x2  x3  38
3x1  x2  7 x3  34
8 x1  x2  2 x3  20

4. Can Cholesky decomposition be applied to solve the following system of equations?


Explain your answer. If the answer is YES, obtain the solution.

8 x1  20 x2  15 x3  100
20 x1  80 x2  50 x3  250
15 x1  50 x2  60 x3  100

5. Consider the following system of equations:

 0.8 0.4 0   x1   41 
 0.4 0.8 0.4  x    25 
  2  
 0 0.4 0.8   x3  105
(a) Is the above system solvable by Thomas algorithm? Explain your answer, and if the
answer is YES, obtain the solution via the method.
(b) Is the above system solvable by Gauss-Siedel iterative method? Explain your
answer, and if the answer is YES, obtain the solution via the method (in case the
system is solvable via Gauss-Siedel method, your reported solution should have an
accuracy level of 5%, i.e., 0.05. You can start with any suitable initial guess as
discussed in the class lectures).

6. The following system of equations have been designed to evaluate the concentrations
(the c’s are in g/m3) in a series of coupled reactors as a function of the quantity of mass
input to each reactor (the right-hand sides of each of these equations are in g/day):

15c1  3c2  c3  3300


3c1  18c2  6c3  1200
4c1  c2  12c3  2400

Obtain the solution using

2
(a) Gauss-Siedel iterative method
(b) Jacobi iterative method.
For both (a) and (b), start with [0, 0, 0]T as the initial approximation. In each of these
cases, your solution should have an accuracy level of 5% (i.e., 0.05). Which method is
giving results (having desired accuracy) with lesser number of iterations, and why?

7. Consider the following system of linear equations:

3x1  x2  15 x3  44
6 x1  2 x2  x3  5
5 x1  10 x2  x3  28

Solve the above system employing


(a) classical Gauss-Siedel method (i.e., without any relaxation)
(b) Gauss-Siedel method with underrelaxation (   0.95 )
(c) Gauss-Siedel method with overrelaxation (i.e, SOR method) (   1.2 )

You can start with any suitable initial guess as discussed in the class lectures. A good
starting point can be [0 0 0]T (or, [1 1 1]T). The acceptable tolerance (accuracy) level
should be 5% in each of the three cases. You may rearrange the equations to achieve
convergence, if found necessary. You may also explain any observation/make a
comparison based on your calculations by the three methods.

You might also like