 Hi, I'm Zor. Welcome to IndieZor education. We have a very easy task in front of us today to solve the system of two linear equations with two variables. Basically it looks like this in general. I'm sure you would have absolutely no problems to solve any particular system like this with real numbers, real solutions, etc. There are different methods to do it like elimination for instance or substitution or whatever. But that's not what we're going to talk about today. I would like to approach this from the matrix perspective because this is exactly how systems with 3, 4, 25 variables are solved. This is how computers actually are solving systems of linear equations, etc. So I'm going to use the theory of matrix and terminology of matrices and the theory of determinants, matrix determinants, which we have already discussed before. So let me first try to solve this thing. I'll solve it exactly the same way as probably everybody else does. For instance, I presume that these two coefficients are not simultaneously equal to zero because otherwise we would have a system of two equations with one variable, which is no good, obviously. So let's consider A1, 2, for instance, not equal to zero. So I will be able to solve this equation for X2 if I know, for instance, the value of X1. And to get the value of X1, I'll just eliminate X2 by multiplying this by A22, this multiplied by A12, and I will subtract from this, I will subtract this. So if I will do this, my X2 will cancel out, right? A12 and A22 was X2, and here I will have X22 and A12, which is the same thing. So if I will subtract the results of multiplication of each of these equations, I will eliminate X2. So what I will have is, on the left I will have B1 times A22 minus B2 times A12 equals and on the right I will have A11 times A22 minus A21 times A12 X1. So the solution is very simple. Okay, now, it's very easy to derive this formula. What's more interesting is to start interpreting this formula from the position of matrices and their determinant. So let's use the matrix of the coefficients. This is matrix of the coefficients A11, A22, A12, A21, A22. These are coefficients. Now, what is in the denominator? Well, according to our definition, the determinant of this matrix is main diagonal minus the alternate diagonal, which is exactly the denominator here. Now, the numerator, well, it looks kind of similar to this, but we don't have the same coefficients here. So what is the numerator? Well, here's what I suggest. Let's take the first row, the first column, sorry, in the matrix A replaced with three coefficients and let's call it A1. One, because we have substituted the first column where X1 actually is. So all the coefficients which are for X1, I substitute it with the three elements of these equations. Now, as you see, the numerator is the determinant of this matrix. So the determinant of matrix A1 is again main diagonal, which is B1 times A22 minus alternate diagonal, B2 times A12, which is numerator. Now, let's do a very similar thing. Let's eliminate X1, for instance, and get X2. Or alternatively, we can just use the first equation and since we know the value of X1, we can find the value of X2. Whatever is easier. Well, let's do it this way. And by the way, using these, I can say that X1 is equal to the determinant of matrix A1 divided by the determinant of main matrix of the coefficients A. Alright, now let me wipe out this and let's solve it for X2. I would prefer actually to do exactly the same way as I did when I was solving for X1. I'll just eliminate X1. Now, to eliminate X1, I will multiply this by A21 and this I will multiply by A11 and subtract from this. I subtract this, in which case my X1 would be cancelled out and what remains is B1 times A21 minus B2 times A11. That's on the left. On the right, again, X1 will cancel out, right? Because A11, A21 and A21, A11, it was a minus sign. So, with the plus, I will have A12, A21 minus A22, A11, X2. And from here, X2 is equal to... Well, if you don't mind, I will change the signs in both cases because this actually looks like exactly the determinant of the matrix A that was a minus sign. So, I actually probably should have subtracted this from this, not this from this. It doesn't really matter. So, let me change the signs here. So, I will have plus here, minus here, plus here and minus here. Alright? That's the same thing. So, X2 is equal to... In the numerator, I will have B2A11 minus B1A21 and denominator is A11A22 minus A12A21. Well, lo and behold, in the denominator, I have exactly the same determinant of matrix A. Now, here, what do I have here? Well, let me just use the same approach but slightly different here. So, I used to have my matrix of the coefficients like this. Now, if you remember, to get the value of X1, I had to substitute the first column with the three members. Now, for X2, if you notice, I can substitute the second column with three members. And the determinant of this matrix, call it A2. The second column is substituted with three members, right? And now, the determinant is A11 times B2, A11 times B2 minus B1 times A21, B1 times A. So, as you see, X2, similarly to X1 actually, is equal to determinant of matrix A2 divided by determinant of matrix A. So, what we have done here, we have come up with a very general way to express solutions of our system of two equations with two variables, linear equations. What you have to do is, first of all, the denominator for all of these solutions is exactly the same, it's the determinant of the matrix of the coefficients. And the numerator for the first one, you have to substitute in this matrix the first column with three members and get the determinant. For the second unknown variable, you have to substitute the second column in the matrix of the coefficients with the three members and get the determinant. And that's how basically you get the solutions. Now, what's interesting is that exactly the same formulas exist for three equations with three variables, 4, 25, whatever. The formulas are exactly the same. So, you have the matrix of the coefficients, you substitute the first column with the three members and get the determinant, divide by the determinant of the matrix of the coefficients, you will get the first variable. Substitute the second column with three members, get the determinant, divide by the determinant of the coefficients and you will get the second variable, etc., etc., etc. Now, I will do exactly these types of calculations in the next lecture for three variables and three equations. And again, I will just solve these equations and come up eventually with the same formula. And I'm just leaving it just as an information that the same formulas actually exist for n linear equations with n variables. But this is something which people usually learn in higher schools, colleges, whatever. Okay, that's it for today. Thank you very much for your attention. I think there is a very interesting lesson that I would like you to basically learn from this. You see, there are many different things in mathematics and they are seemingly non-related to each other. But then, as soon as you come up to a little bit higher level and look at these problems from that higher level, you see the commonality. Like, for instance, there is a commonality of the solutions of any linear system of linear equations. I mean, the formulas are exactly the same. Now, you cannot say it without going to this upper layer of looking at this through the series of matrices and determinants. If you just see the system, if you're trying to solve it, you see many different ways how to solve it, many particular approaches. But you don't see this generalized view, it basically tells you that lots of different things are really related to each other. But to see this relation, you have to really be on the top of it. As everything else in the world. I mean, everything is related. But to know how the relation actually is accomplished, how these links are organized, you really have to look at this from the top. Okay, that's a little lesson, which I wanted you to know. Alright, I invite you to go to Unisor.com website. Look at the notes to this lecture just to make sure that you are better prepared. And again, don't forget that the site allows for registered students to take exams, which is very, very important. Exams are not available for all the lectures, but I'm working on it. So thanks very much again and good luck.