Topic 1 Systems of Linear Equations
Topic 1 Systems of Linear Equations
A System of Linear Equations is when we have two or more linear equations working
together.
2x + y = 5
−x + y = 2
In a race you can run 0.2 km every minute. The Horse can run 0.5 km every minute. But it takes
6 minutes to saddle the horse. How far can you get before the horse catches you
1
We can make two equations (d=distance in km, t=time in minutes)
d = 0.2t
d = 0.5(t−6)
Do you see how the horse starts at 6 minutes, but then runs faster?
It seems you get caught after 10 minutes ... you only got 2 km away.
Only simple variables are allowed in linear equations. No x2, y3, √x, etc:
2
Linear 2x+y-z = 4 vs non-linear 2x+y2 – z=4
1.1 Dimensions
A Linear Equation can be in 2 dimensions (such as the two lines plotted above)
3 dimensions
4 dimensions or more
For the equations to "work together" they share one or more variables:
2x + y − 2z = 3
3
x − y − z = 0
x + y + 3z = 12
2 equations in 3 variables,
6 equations in 4 variables,
9,000 equations in 567 variables,
etc.
When the number of equations is the same as the number of variables there is likely to be a
solution. Not guaranteed, but likely.
No solution
One solution
Infinitely many solutions
When there is no solution the equations are called "inconsistent". One or infinitely many
solutions are called "consistent"
1.4 Independent
"Independent" means that each equation gives new information.
Otherwise they are "Dependent".
Also called "Linear Independence" and "Linear Dependence"
For example given the two equations below:
x+y=3
2x + 2y = 6
4
Those equations are "Dependent", because they are really the same equation, just multiplied
by 2. So the second equation gave no new information.
The trick is to find where all equations are true at the same time.
The "you" line is true all along its length (but nowhere else).
at t=5 and d=1, the equation is true (Is d = 0.2t? Yes, as 1 = 0.2×5 is true)
at t=5 and d=3, the equation is not true (Is d = 0.2t? No, as 3 = 0.2×5 is not true)
Likewise the "horse" line is also true all along its length (but nowhere else).
But only at the point where they cross (at t=10, d=2) are they both true.
5
So they have to be true simultaneously that is why some people call them "Simultaneous
Linear Equations"
Solve Using Algebra
d = 0.2t
d = 0.5(t−6)
d = 0.2t = 0.5(t−6)
Algebra vs Graphs
Solving By Substitution
Solving By Substitution
6
Write one of the equations so it is in the style "variable = ..."
(Repeat as necessary)
Let's use the second equation and the variable "y" (it looks the simplest equation).
We can subtract x from both sides of x + y = 8 to get y = 8 − x. Now our equations look like this:
3x + 2y = 19
y=8−x
3x + 2(8 − x) = 19
y=8−x
Expand 2(8−x):
3x + 16 − 2x = 19
y=8−x
Then 3x−2x = x:
x + 16 = 19
y=8−x
x=3
y=8−x
x=3
y=8−3=5
7
And the answer is:
x=3
y=5
Check: why don't you check to see if x = 3 and y = 5 works in both equations?
Example:
x+z=6
z − 3y = 7
2x + y + 3z = 15
We should line up the variables neatly, or we may lose track of what we are doing:
x + z = 6
− 3y + z = 7
2x + y + 3z = 15
WeI can start with any equation and any variable. Let's use the first equation and the variable
"x".
x = 6−z
− 3y + z = 7
2x + y + 3z = 15
x = 6−z
− 3y + z = 7
8
2(6−z) + y + 3z = 15
2(6−z) + y + 3z = 15 simplifies to y + z = 3:
x = 6−z
− 3y + z = 7
y + z = 3
Now repeat the process, but just for the last 2 equations.
x = 6−z
− 3y + z = 7
z = 3−y
x = 6−z
− 3y + 3−y = 7
z = 3−y
x = 6−z
y = −1
z = 3−y
Almost Done!
9
Knowing that y = −1 we can calculate that z = 3−y = 4:
x = 6−z
y = −1
z = 4
x = 2
y = −1
z = 4
x=2
y = −1
z=4
We can use this method for 4 or more equations and variables... just do the same steps again and
again until it is solved. Conclusion: Substitution works nicely, but does take a long time to
calculate.
Solving By Elimination
‘Eliminate ’ means to remove: This method works by removing variables until there is just one
left
Example:
3x + 2y = 19
x+y=8
3x + 2y = 19
x + y = 8
10
Now ... our aim is to eliminate a variable from an equation.
3x + 2y = 19
2x + 2y = 16
x = 3
2x + 2y = 16
Next we see the 2nd equation has "2x", so let's halve it, and then subtract "x":
x = 3
x + y = 8
x = 3
y = 5
x = 3 and y = 5
i) 2x − y = 4
6x − 3y = 3
ii) 2x − y = 4
6x − 3y = 12
Example:
x+y+z=6
2y + 5z = −4
11
2x + 5y − z = 27
Written neatly:
x + y + z = 6
2y + 5z = −4
2x + 5y − z = 27
Subtract 2 times the 1st equation from the 3rd equation (just do this in your head or on
scratch paper):
And we get:
x + y + z = 6
2y + 5z = −4
3y − 3z = 15
We could subtract 1½ times the 2nd equation from the 3rd equation (because 1½ times 2 is 3) ...
12
And we end up with:
x + y + z = 6
2y + 5z = −4
z = −2
x + y + z = 6
y = 3
z = −2
x = 5
y = 3
z = −2
x=5
y=3
z = −2
Continued Assignment Find a solution to the following system of equations in three variables
13
iii) x+y+z =2
6x-4y+5z =31
5x+2y+2z =13
iv) x-2y+3z =9
-x+3y-z =-6
2x-5y+5x =17
14