If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

### Course: Linear algebra>Unit 1

Lesson 6: Matrices for solving systems by elimination

# Solving a system of 3 equations and 4 variables using matrix row-echelon form

Sal solves a linear system with 3 equations and 4 variables by representing it with an augmented matrix and bringing the matrix to reduced row-echelon form. Created by Sal Khan.

## Want to join the conversation?

• What is a leading entry?
• It is the first non-zero entry in a row starting from the left. So if we had the matrix:
``| 1 | 2 | 0 || 0 | 3 | 4 || 5 | 6 | 7 || 0 | 0 | 8 |``

the entries 1, 3, 5 and 8 are leading entries.
• what is the difference between using echelon and gauss jordan elimination process
• Gauss-Jordan is augmented by an n x n identity matrix, which will yield the inverse of the original matrix as the original matrix is manipulated into the identity matrix.

In the case that Sal is discussing above, we are augmenting with the linear "answers", and solving for the variables (in this case, x_1, x_2, x_3, x_4) when we get to row reduced echelon form (or rref).
• Is there a reason why line two was subtracted from line one, and (line one times two) was subtracted from line three? what I'm saying is why didn't we subtract line 3 from two times line one
• it doesnt matter how you do it as long as you end up in rref
that just happens to be the way sal did it
• onward : i don't get this whole visualisation thing..
can anyone post a link / explain it?
Thx!!
• It's not easy to visualize because it is in four dimensions! It is hard enough to plot in three!

So Sal has some vector [x1, x2, x3, x4]' = [2 0 5 0]' + x2*[-2 1 0 0]' + x4*[-3 0 2 1]'

Let's ignore the last two terms for the moment. We can do that by pretending that x2 = 0 and x4 = 0. Then we get [x1, x2, x3, x4]' = [2 0 5 0]'. That's one possible answer, which Sal shows by marking a big blue spot. We can't plot it exactly because it has to be in four dimensions! In any case, if we lived in some crazy four dimensional universe (let's leave time out of this), then we could plot this as a line coming from the origin [0, 0, 0, 0]' to the point [2 0 5 0]'. That's what Sal's blue line represents.

But wait, that's not all! We still have those last two terms. Each of those vectors represents a line. Let's ignore the last term for now. So we have:
[x1, x2, x3, x4]' = [2 0 5 0]' + x2*[-2 1 0 0]'

OK, so that last vector is a line. Because we can have any value for x2, that means any multiple of that line PASSING THROUGH [2 0 5 0] is an answer. So if x2 is 0, we get [2 0 5 0] as an answer. If x2 is 1, we get [0 1 5 0] is an answer. This makes a line that goes through [2 0 5 0]. However, this line is in four dimensions, so is still really hard to plot!

But wait, there's more! We have another term we have been ignoring. The last term has another vector. What do we get when we can move in two different directions? We get a plane!

If you would like an analogy (in 3D), think of yourself as being in a multi-storey building. The first term gives you floor. The second and third terms give you some amount north and some amount east (they could be negative). The first term is fixed; you aren't allowed to change floors. However, the last two terms vary as much as you like, so you can go north, east, south (negative north), west (negative east) or any combination as much as you like.

Sorry, confusing I know, but four dimensions can do that!
• Hi, Could you guys explain what echelon form means? Like the things needed for a system to be a echelon form?
• A rectangular matrix is in echelon form if it has the following three properties:

1. All nonzero rows are above any rows of all zeros
2. Each leading entry of a row is in a column to the right of the leading entry of the row above it.
3. All entries in a column below a leading entry are zeros.

For it to be in reduced echelon form, it must satisfy the following additional conditions:

4. The leading entry in each nonzero row is 1
5. Each leading 1 is the only nonzero entry in its column
• Is there a video or series of videos that shows the validity of different row operations? I'm looking for a proof or some other kind of intuition as to how row operations work.
• at , how did you get X2 = 0 1 0
X4=0 0 1
i dont understand how did you get that . we only know X1 ans X3 ??
thanks
Hal
• Sal has assumed that the solution is in R^4 (which I guess it is if it's in R2 or R3). I'm also confused.

What he's doing implies that the free variables x2 and x4 are on their own x2 and x4 axes of R^4, which I have doubts about.

1) The original 3x4 transformation matrix is from R^4 to R^3.
2) The rref matrix has only 2 rows, which seems to mean there are only x1 and x3 coordinates in the solution.
(1 vote)
• What if there are MORE equations than unknowns?
• Then either some of them are redundant, or you will have additional restrictions which make the set of equations unsolvable.
• at int the video sal says a matrices is a rays of numbers, what is a rays?