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.

## 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?

• •   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 • At , why is the 4th dimension denoted by R4?
Why the letter R? •  R is the set of all real numbers. The real numbers can be thought of as any point on an infinitely long number line. Examples of these numbers are -5, 4/3, pi etc. An example of a number not included are an imaginary one such as 2i.

R4 means that points in the space has 4 coordinates of real values. Points in this space are written on the form (x1, x2, x3, x4) where xi is a real number.
• This might be a side tract, but as mentioned in "" does that mean, for any plane in any dimension the equation defining one is "point in that plane + vector 1 + vector 2"? Or for higher dimensions, will it need more vectors? • I think you are basically correct in the notion that you can define a plane with a point and two vectors, however I think it would be wise if you said "+ a linear combination of two non-zero independent vectors" instead of just "+ vector 1 + vector 2".
I disagree with Jeffrey for two reasons:
1.It can be dangerous to think of a vector as a line with two points. Vectors aren't defined by position. Really (1,1,1) -> (10,1,1) should just be the vector ( 9,0,0) and (2,2,2) -> (2,10,2) should just be the vector (0,8,0). You can make a plane out of a linear combination of these two vectors.
2. The two vectors in the video do not just "happen" to intersect at the point (2,0,5,0). Any two vectors added to the point (2,0,5,0) would intersect at this point because the two vectors both have that point as a starting position.
• 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 • 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!
• 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. • 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
• 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)
• at int the video sal says a matrices is a rays of numbers, what is a rays? 