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.

Main content

# Solving linear systems with matrices

## Video transcript

figure it never hurts getting as much practice as possible solving systems of linear equations so let's solve this what don't know what I'm going to do is I'm going to solve it using an Augmented matrix and I'm going to put it in row reduced row echelon form so what's the Augmented matrix for this system of equations three unknowns with three equations so it'll be I'll just have to do the coefficients so the coefficients of the X terms or just 1 1 1 coefficients of the Y terms are 1 2 & 3 coefficients of the Z's remember one three and four one three and four and let me show that it's augmented and then they equal three zero three zero and minus two now I want to get this augmented matrix into reduced row echelon form so the first thing I have a one leading one here that's a pivot entry let me make everything else in that column equal to a zero so let me so I'm not going to change my first row so I'll just be a 1 a 1 a 1 and then my dividing line and then I have a 3 now to make to zero this out let me just replace the second row with the first row minus the second row so 1 minus 1 is 0 1 minus 2 is 1 minus 2 actually a better thing to do because I eventually want this to be 1 anyway let me replace this row with this row with the second row minus the first row instead of the first row minus the second row I can do it either way so the first the second row minus the first row so 1 minus 1 is 0 2 minus 1 is 1 3 minus 1 is 2 and then 0 minus 3 is minus 3 now I want to also zero this out so let me replace this guy with this equation minus that equation so 1 minus 1 is 0 3 minus 1 is 2 4 minus 1 is 3 minus 2 minus three is minus five fair enough so I got my pivot entry here I have another pivot entry here to the right of this one which is what I want for reduced row echelon form now I need to target this entry and that entry and I need to zero them out so let's do it so we get so I'm not I'm going to keep my second row the same my second row zero one two and then I have a minus 3 and the Augmented part of it and to zero this guy out what I can do is I can replace the first row with the first row minus the second row so I get 1 minus 0 is 1 1 minus 1 there's a bird outside let me close my window so where was I I'm replacing the first row with the first row minus the second row so 1 minus 0 is 1 1 minus 1 is 0 I don't want to make it 1 minus 1 is 0 1 minus 2 is minus 1 and then 3 minus minus 3 so that's equal to 3 plus 3 so that's equal to 6 right 1 minus 0 is 1 1 minus 1 is 0 negative 1 and then 3 minus negative 3 that's 6 I always want to make sure I don't make a careless mistake now let me get rid of this entry right here let me zero that out so let me replace the third row with the third row minus 2 times the second row so we have 0 minus well 2 times 0 that's just going to be 0 2 minus 2 times 1 that's 2 2 minus 2 that's 0 3 minus 2 times 2 that's 3 minus 4 or minus 1 and then finally minus 5 minus 2 times minus 3 let me write that down minus 5 minus 2 times minus 3 it's -5 - -6 that's minus 5 plus 6 is equal to 1 I really wanted to make sure I didn't make a careless mistake there so that is equal to one so I'm almost done but I'm still not in reduced row-echelon form this has to be a positive one in order to get there it can't be anything other than a one that's just a style of reduced row-echelon form and then these guys up here have to be zeroed out well the easy thing to do let me just multiply this equation by minus one so then this becomes a plus one and then that becomes a minus one and then I just need to zero out these two guys up here so let's do it so my equation I'm going to keep my third row the same my third row is now 0 0 1 minus 1 0 0 1 minus 1 and now I want to zero this guy out so what I can do is I could set my first row equal to my first row plus my last row because these two add up they're going to be equal to 0 so what do I get 1 plus 0 is 1 0 plus 0 is 0 minus 1 plus 1 is 0 6 plus minus 1 is 5 now I want to zero this row out and to 0 this row out what I can do is I'll replace it with the middle with the second row minus 2 times the first row right so 0 minus 2 times 0 is just 0 1 minus 2 times 0 is just 1 2 minus 2 times 1 is 0 minus 3 minus 2 times negative 1 let me write that down minus 3 minus 2 times minus 1 don't want to make a careless mistake so what is that equal to this is equal to minus 3 minus minus minus 2 or minus 3 plus 2 which is equal to minus 1 so that's equal to minus 1 and now I have my Augmented matrix in reduced row echelon form reduced row echelon form my pivot entries are the only entries in their columns there each pivot entry in each successive rows to the right of the pivot entry before it and actually have no free variables every column has a pivot entry so let's take go back from the Augmented matrix world and kind of put back our variables there so what do we get we get X plus 0 y plus 0 Z is equal to 5 that's that row right there we get 0 X plus 1 y plus 1 y plus 0 Z is equal to minus 1 that's that row right there and then finally we have 0 X plus 0 y plus 1 Z is equal to minus 1 that's that row right there and just like that we've actually solved our system of three equations with three unknowns that's the solution right there I just throw it in this way just so you see the corresponding but obviously I could have written them closer to their equal sign so hopefully you found that vaguely useful