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

Title : Solving Systems of Linear Equation

Intended Learning Outcomes : At the end of this lesson, you should be able to :
1. Perform Gaussian-Jordan Elimination on a given system of linear equation
2. Perform Gauss-Seidel Method to solve a linear system of equations

Discussions :
1. Gauss-Jordan Elimination Method
Gauss-Jordan Elimination method is a variation of the Gaussian Elimination Method. It uses
the main diagonal with 1 as their coefficient. The method has two parts : Forward Elimination and
Back-Elimination. To illustrate the method, consider the system of simultaneous equations below :

5x + 3y + 2z = 16
2x + 6y - 3z = 38
4x + y - 9z = 27
Solve the system of linear equations above using the Gauss-Jordan Elimination Method

Solution :
Step 1 : Write the augmented matrix for the system

5 3 2 16
2 6 -3 38
4 1 -9 27

Forward Elimination
Step 2 : Divide row1 by 5 , divide row 2 by 2, divide row3 by 4
1 0.6000 0.4000 3.2000
1 3.0000 -1.5000 19.0000
1 0.2500 -2.2500 6.7500

Step 3 : Subtract : row2 - row1 , row3 - row1


1 0.6000 0.4000 3.2000
0 2.4000 -1.9000 15.8000
0 -0.3500 -2.6500 3.5500

Step 4 : Divide : row2 /2.4 , row3 / -0.35


1 0.6000 0.4000 3.2000
0 1 -0.7917 6.5833
0 1 7.5714 -10.1429
Step 5 : Subtract : row3 - row2
1 0.6000 0.4000 3.2000
0 1 -0.7917 6.5833
0 0 8.3631 -16.7262
Step 6 : Divide : row3 /8.3631
1 0.6000 0.4000 3.2000
0 1 -0.7917 6.5833
0 0 1 -2

Solving Systems of Linear Equation 1 of 3


Back Elimination
Step 1 : Subtract : row1 – 0.4(row3) ; row2 – (-0.7917)(row3)
1 0.6000 0 4.0000
0 1 0 5.0000
0 0 1 -2
Step 2 : Subtract : row1 – 0.6(row2)
1 0 0 1
0 1 0 5
0 0 1 -2

x=1
y=5
z = -2 , (answer)

2. Gauss-Seidel Method
Gauss-Seidel method is a iterative method to approximate the unknowns in a linear system .
It uses an initial guess of unknowns to start the process. This method converges on diagonally
dominant matrices. To illustrate the method, consider the system of simultaneous equations below :
5x + 3y + 2z = 16
2x + 6y - 3z = 38
4x + y - 9z = 27
Solve the system of linear equations above using the Gauss-Seidel Method

Solution :
Step 1 : Write the equations in terms of the unknowns
x = 1/5 (16 – 3y - 2z)
y = 1/6 (38 - 2x + 3z)
z = -1/9 (27 - 4x - y)

Step 2 : Try initial guess values for values of y and z


try : y = 1 , z = 1

Step 3 : Tabulate the Calculated Values

Values Trial 1 Trial 2 Trial 3 Trial 4 Trial 5 Trial 6 Trial 7 Trial 8


x 2.20 0.08 0.75 1.10 1.04 1.00 1.00
y 1.00 6.10 5.64 4.91 4.91 5.00 5.01 5.00
z 1.00 -1.34 -2.34 -2.12 -1.97 -1.98 -2.00 -2.00

x=1
y=5
z = -2 , (answer)

Solving Systems of Linear Equation 2 of 3


Self Assessment(Problem Set) :
Use N = last digit of your student ID

18x + 3y + 2z + (N+1)j = 236


2x + 16y - 3z + 2j = 145
4x + y - 19z + 4j = -127
5x + 6y - 4z + 14j = 225

1. Solve the system of linear equations above using the Gauss-Jordan Elimination Method.
2. Solve the system of linear equations above using the Gauss-Seidel Method.
3. Verify your answers using the GNU Octave. (provide a screenshot of answer).

References :
1. Applied Numerical Methods with MATLAB for Engineers and Scientist
Steven C. Chapra, McGraw Hill International Edition 2005

2. Elementary Numerical Analysis 3rd Edition


Kendall Atkinson &Weimin Han, John Wiley and Sons 2004

Solving Systems of Linear Equation 3 of 3

You might also like