You are on page 1of 4

AMOUD UNIVERSITY

FACULTY OF ENGINEERING

DEPARTMENT OF CIVIL ENGINEERING

Numerical Methods

LECTURE NOTES

CHAPTER THREE

Numerical solution of linear equations

(Part two)

CLASS: Junior

FIRST SEMESTER

ACADEMIC YEAR: September, 2020 – July, 2021

LECTURER: Mr. Abdiqani M. Aden (Msc in Research & Statistics; Msc in Pure Mathematics)
Solving System of linear equations by Gaussian Elimination
 Engineers often need to solve large systems of linear equations; for example in determining

the forces in a large framework or finding currents in a complicated electrical circuit. The

method of Gauss elimination provides a systematic approach to their solution.

 In using Gauss elimination, which has three stages:

o In the first stage the equations are written in matrix form.

o In the second stage the matrix equations are replaced by a system of equations having

the same solution but which are in triangular form.

o In the final stage the new system is solved by back-substitution.

+ 3 + 5 = 14
Consider the system: 2 − − 3 = 3
4 +5 − =7

Stage 1: Matrix formulation

The first step is to write the equations in matrix form:


1 3 5 14
2 −1 −3 = 3
4 5 −1 7
Then, for conciseness, we combine the matrix of coefficients with the column vector of right-hand
sides to produce the augmented matrix:
1 3 5 14
2 −1 −3 3
4 5 −1 7
Stage 2: Triangularisation
We will next triangularise the matrix of coefficients by means of row operations. There are

three possible row operations:

 Interchange two rows; i.e R ↔ R .

 Multiply or divide a row by a non-zero constant factor; i.e 2R .

 Add to, or subtract from, one row a multiple of another row. i.e 2R + R = R

Numerical Methods Lecture Notes AU 2020 Page 2


The second stage proceeds by first eliminating x from the second and third equations using row
operations.
1 3 5 14 1 3 5 14
2 −1 −3 3 2 −1 −3 3
4 5 −1 7 4 5 −1 7
In the above we have subtracted twice row (equation) 1 from row (equation) 2.In full these
operations would be written, respectively, as
(2x – y – 3z) − 2( x + 3y + 5z) = 3 − 2 × 14 or −7y – 13z= −25
and
(4x + 5y − z) − 4( x + 3y + 5z) = 7 − 4 × 14 or −7y – 21z = −49 .
Now since all the elements in rows 2 and 3 are negative we multiply throughout by −1:

Finally, we eliminate y from the third equation by subtracting equation (row) 2 from equation
(row) 3. i.e. R3 − R2:

The system is now in triangular form.


Stage 3: Back Substitution
Here we solve the equations from bottom to top. At each step of the back substitution process we
encounter equations which only have a single unknown and so can be easily solved.

From the last equation we see that z = 3.


Substituting this value into the second equation gives:
7y + 13z = 25 or 7y + 13(3) = 25 or 7y = −14 so that y = −2.
Finally, using these values for y and z in equation 1 gives
x + 3y + 5z = 14 or x + 3(-2) + 5(3) = 14 or x − 6 + 15 = 14. Hence x = 5.

Numerical Methods Lecture Notes AU 2020 Page 3


Example (1)
Solve the system by Gaussian Elimination
x + 3y − 5z = 2
3x + 11y − 9z = 4
−x + y + 6z = 7

Example (2)
Solve the system using Gaussian Elimination
2x − 3x + 4x = 2
4x + x + 2x = 2
x − x + 3x = 3

Example (3)
A d.c. circuit comprises three closed loops. Applying Kirchhoff’s laws to the closed loops gives
the following equations for current flow in milliamperes:
2I + 3I − 4I = 26
I − 5I − 3I = −87
7I + 2I + 6I = 12
Use Gaussian Elimination to solve for I , I and I .

THE END

Numerical Methods Lecture Notes AU 2020 Page 4

You might also like