1 00:00:07,165 --> 00:00:07,790 JOEL LEWIS: Hi. 2 00:00:07,790 --> 00:00:09,364 Welcome back to recitation. 3 00:00:09,364 --> 00:00:11,280 You've been learning in lecture about matrices 4 00:00:11,280 --> 00:00:13,820 and their various applications, and one of them 5 00:00:13,820 --> 00:00:16,490 is to solving systems of linear equations. 6 00:00:16,490 --> 00:00:19,690 So I have here a system of three linear equations for you. 7 00:00:19,690 --> 00:00:25,203 2x plus c*z equals 4, x minus y plus 2z equals pi, 8 00:00:25,203 --> 00:00:29,730 and x minus 2y plus 2z equals minus 12. 9 00:00:29,730 --> 00:00:31,790 So what I'd like you to do is the following. 10 00:00:31,790 --> 00:00:35,080 Find the value of c-- or all values of c-- 11 00:00:35,080 --> 00:00:38,100 for which, first of all, there's a unique solution 12 00:00:38,100 --> 00:00:40,010 to this system. 13 00:00:40,010 --> 00:00:43,140 Second of all, for which the corresponding homogeneous 14 00:00:43,140 --> 00:00:44,790 system has a unique solution. 15 00:00:44,790 --> 00:00:47,250 So remember that the corresponding homogeneous 16 00:00:47,250 --> 00:00:50,330 system is the system where you just replace these constants 17 00:00:50,330 --> 00:00:51,620 on the right by 0. 18 00:00:51,620 --> 00:00:53,310 So it's a very similar-looking system. 19 00:00:53,310 --> 00:00:55,130 The left-hand sides are all the same, 20 00:00:55,130 --> 00:00:57,775 but the right-hand sides are replaced with 0. 21 00:00:57,775 --> 00:01:00,275 So you want to find the value of c for which this system has 22 00:01:00,275 --> 00:01:02,070 a unique solution, the value of c 23 00:01:02,070 --> 00:01:04,520 for which the corresponding homogeneous system has 24 00:01:04,520 --> 00:01:10,300 a unique solution, and also the values of c 25 00:01:10,300 --> 00:01:13,830 for which the corresponding homogeneous system has 26 00:01:13,830 --> 00:01:15,310 infinitely many solutions. 27 00:01:15,310 --> 00:01:18,390 Note that I'm not asking you to solve this system of equations, 28 00:01:18,390 --> 00:01:21,790 although you're welcome to do so if you like. 29 00:01:21,790 --> 00:01:23,720 Although, of course, whether you can or not 30 00:01:23,720 --> 00:01:25,850 might depend on the value of c. 31 00:01:25,850 --> 00:01:30,210 So why don't you pause the video, take a little while 32 00:01:30,210 --> 00:01:33,179 to work out the solutions to these three questions, 33 00:01:33,179 --> 00:01:34,970 come back, and we can work it out together. 34 00:01:43,530 --> 00:01:46,820 So hopefully you have some luck working out these problems. 35 00:01:46,820 --> 00:01:48,860 Let's start working through them together. 36 00:01:48,860 --> 00:01:52,590 So I'm actually going to take parts a and b 37 00:01:52,590 --> 00:01:53,682 together at the same time. 38 00:01:53,682 --> 00:01:55,140 And the reason that I'm going to do 39 00:01:55,140 --> 00:01:58,230 that is that one thing you've learned 40 00:01:58,230 --> 00:02:04,140 is that a system has a unique solution for, 41 00:02:04,140 --> 00:02:08,470 on the right-hand side-- sorry-- a system has a unique solution, 42 00:02:08,470 --> 00:02:11,580 like this, a square system of linear equations 43 00:02:11,580 --> 00:02:13,670 has a unique solution if and only 44 00:02:13,670 --> 00:02:15,490 if it has a unique solution regardless 45 00:02:15,490 --> 00:02:17,070 of what the right-hand side is. 46 00:02:17,070 --> 00:02:20,320 So in particular, the answer to a and the answer to b 47 00:02:20,320 --> 00:02:21,870 are exactly the same. 48 00:02:21,870 --> 00:02:25,760 So values of c for which this system has a unique solution 49 00:02:25,760 --> 00:02:29,480 are exactly the same as values of c for which the homogeneous 50 00:02:29,480 --> 00:02:30,940 system has a unique solution. 51 00:02:30,940 --> 00:02:33,750 Now the solutions will be different, of course. 52 00:02:33,750 --> 00:02:38,400 But the value of c-- or the values 53 00:02:38,400 --> 00:02:40,660 of c-- that make it solvable uniquely, 54 00:02:40,660 --> 00:02:43,660 make it solvable uniquely for all right-hand sides. 55 00:02:43,660 --> 00:02:46,210 And so which values of c are those? 56 00:02:46,210 --> 00:02:48,590 Well, those are the values of c for which 57 00:02:48,590 --> 00:02:51,957 the coefficient matrix on the left-hand side is invertible. 58 00:02:51,957 --> 00:02:54,040 So if the coefficient matrix on the left-hand side 59 00:02:54,040 --> 00:02:56,620 is invertible, then we can solve this system 60 00:02:56,620 --> 00:02:58,040 and we get a unique solution. 61 00:02:58,040 --> 00:03:01,040 If it's not invertible, then either we 62 00:03:01,040 --> 00:03:04,170 can't solve this system-- like, there are no solutions-- 63 00:03:04,170 --> 00:03:06,640 or we can solve this system, but there are infinitely 64 00:03:06,640 --> 00:03:07,780 many solutions. 65 00:03:07,780 --> 00:03:10,700 So in both questions a and b, we're 66 00:03:10,700 --> 00:03:14,680 asking for the value of c for which the coefficient matrix 67 00:03:14,680 --> 00:03:16,450 of the left-hand side is invertible, 68 00:03:16,450 --> 00:03:19,270 and that will be when we have a unique solution. 69 00:03:19,270 --> 00:03:22,780 So how do we know when a matrix is invertible? 70 00:03:22,780 --> 00:03:25,620 Well, let's write down what the matrix is first of all. 71 00:03:25,620 --> 00:03:29,410 So this matrix M that we're after is equal to the matrix 72 00:03:29,410 --> 00:03:43,290 2, 0, c; 1, minus 1, 2; 1, minus 2, 2. 73 00:03:43,290 --> 00:03:46,850 So this is the coefficient matrix M of that system, 74 00:03:46,850 --> 00:03:49,650 and we want to know for which values of c is it invertible. 75 00:03:49,650 --> 00:03:52,531 Well, when is a matrix invertible? 76 00:03:52,531 --> 00:03:54,780 A matrix is invertible-- square matrix is invertible-- 77 00:03:54,780 --> 00:03:58,310 precisely when it has non-zero determinant. 78 00:03:58,310 --> 00:04:01,610 So we just need to look at the determinant of this matrix. 79 00:04:01,610 --> 00:04:05,070 So you've learned how to compute determinants of matrices, 80 00:04:05,070 --> 00:04:05,740 I think. 81 00:04:05,740 --> 00:04:10,830 So let's, in this case, we have the det M. 82 00:04:10,830 --> 00:04:13,380 So it's a sum or difference of six different terms, 83 00:04:13,380 --> 00:04:15,070 and you could get it, for example, 84 00:04:15,070 --> 00:04:17,781 by the Laplace expansion if you wanted to. 85 00:04:17,781 --> 00:04:20,030 So I'm just going to write out what the six terms are. 86 00:04:20,030 --> 00:04:28,900 So it's 2 times minus 1 times 2, plus 0 times 2 times 1, 87 00:04:28,900 --> 00:04:38,910 plus c times 1 times minus 2, minus c times minus 1 88 00:04:38,910 --> 00:04:49,990 times 1, minus 2 times minus 2 times 2, minus 0 times 1 times 89 00:04:49,990 --> 00:04:50,900 2. 90 00:04:50,900 --> 00:04:53,530 So this is the determinant of this matrix. 91 00:04:53,530 --> 00:04:56,517 You can get it either just by remembering 92 00:04:56,517 --> 00:04:58,475 which terms are which and which get a plus sign 93 00:04:58,475 --> 00:05:01,430 and which get a minus sign, or by doing the Laplace expansion, 94 00:05:01,430 --> 00:05:05,600 or by whatever other tricks you might happen to know. 95 00:05:05,600 --> 00:05:09,100 So now we need to know whether or not this determinant is 0. 96 00:05:09,100 --> 00:05:11,622 So let's work out what this is. 97 00:05:11,622 --> 00:05:13,330 So this is-- let me start simplifying it. 98 00:05:13,330 --> 00:05:19,060 So this is minus 4 plus 0 minus 2c-- 99 00:05:19,060 --> 00:05:22,560 this is minus minus c, so plus c-- 100 00:05:22,560 --> 00:05:29,520 this is minus minus 8, so plus 8, which is equal to 4 minus c. 101 00:05:29,520 --> 00:05:32,390 So the determinant-- right, two of those terms 102 00:05:32,390 --> 00:05:35,810 are 0, and so I just get to leave them out. 103 00:05:35,810 --> 00:05:39,900 So the determinant of this matrix is 4 minus c. 104 00:05:39,900 --> 00:05:41,750 And what we're interested in is when 105 00:05:41,750 --> 00:05:44,820 this determinant is non-zero. 106 00:05:44,820 --> 00:05:56,970 So in particular, for c not equal to 0-- sorry, 107 00:05:56,970 --> 00:06:03,090 for c not equal to 4-- when c is not 4, the determinant of M 108 00:06:03,090 --> 00:06:04,510 is not 0. 109 00:06:04,510 --> 00:06:12,930 So when c is not 4, determinant of M is not 0, 110 00:06:12,930 --> 00:06:18,160 so both systems-- both the original system 111 00:06:18,160 --> 00:06:21,210 and the corresponding homogeneous system-- 112 00:06:21,210 --> 00:06:33,170 have a unique solution. 113 00:06:33,170 --> 00:06:38,090 So when c is not 4-- so for most values of c-- 114 00:06:38,090 --> 00:06:41,140 the determinant is not 0, and the system 115 00:06:41,140 --> 00:06:42,530 has a unique solution. 116 00:06:42,530 --> 00:06:45,150 So when c is equal to 4, what happens? 117 00:06:45,150 --> 00:06:48,900 Well, when c is equal to 4, we're in the bottom case. 118 00:06:48,900 --> 00:06:51,980 We're in the case where the homogeneous system has 119 00:06:51,980 --> 00:06:53,960 infinitely many solutions. 120 00:06:53,960 --> 00:06:54,470 OK? 121 00:06:54,470 --> 00:06:58,640 So let me write that over here. 122 00:06:58,640 --> 00:07:04,260 When c equals 4-- I'm going to abbreviate 123 00:07:04,260 --> 00:07:12,920 again-- the homogeneous system has-- I'm 124 00:07:12,920 --> 00:07:17,120 going to use this symbol-- this sort of sideways eight symbol 125 00:07:17,120 --> 00:07:19,230 means infinity, so I'm going to use it 126 00:07:19,230 --> 00:07:26,660 for infinitely many solutions. 127 00:07:26,660 --> 00:07:28,976 So when c is 4, the homogeneous system 128 00:07:28,976 --> 00:07:30,225 has infinitely many solutions. 129 00:07:30,225 --> 00:07:33,240 And you might be curious-- well, so let 130 00:07:33,240 --> 00:07:35,240 me say one more thing about that. 131 00:07:35,240 --> 00:07:39,640 We know when the coefficient matrix isn't invertible 132 00:07:39,640 --> 00:07:42,960 that the system either has zero or infinitely many solutions. 133 00:07:42,960 --> 00:07:45,160 But the homogeneous system always has a solution. 134 00:07:45,160 --> 00:07:47,680 It always has the solution where everything is all 0. 135 00:07:47,680 --> 00:07:48,180 Right? 136 00:07:48,180 --> 00:07:51,060 So that's why we know that it's infinitely many here. 137 00:07:51,060 --> 00:07:54,100 And one thing you might ask is can you find any others? 138 00:07:54,100 --> 00:08:00,280 Can you find any solutions that aren't just [0, 0, 0]? 139 00:08:00,280 --> 00:08:01,690 And the answer is yes. 140 00:08:01,690 --> 00:08:04,312 So this is now going beyond when I asked you to do, 141 00:08:04,312 --> 00:08:06,645 but I think it's, you know, an interesting thing to see. 142 00:08:12,670 --> 00:08:17,740 So if you wanted to find another solution, what do you know? 143 00:08:17,740 --> 00:08:21,840 Well, let's go back to the equations that we had. 144 00:08:21,840 --> 00:08:24,460 So when we're dealing with a homogeneous system, 145 00:08:24,460 --> 00:08:25,850 the right-hand sides are 0. 146 00:08:25,850 --> 00:08:28,058 So I'm just going to cross out these right-hand sides 147 00:08:28,058 --> 00:08:30,280 and replace them with 0 so we don't get confused. 148 00:08:30,280 --> 00:08:34,950 So this is 0, 0, and 0. 149 00:08:34,950 --> 00:08:39,242 So we're dealing with this system: 2x plus c*z equals 0, 150 00:08:39,242 --> 00:08:45,140 x minus y plus 2z equals 0, and x minus 2y plus 2z equals 0. 151 00:08:45,140 --> 00:08:48,550 OK, so if you want a solution [x, y, z] 152 00:08:48,550 --> 00:08:50,380 to this system, what do you know? 153 00:08:50,380 --> 00:08:53,970 Well, from the second equation, you know that the vector 154 00:08:53,970 --> 00:08:59,650 [x, y, z] is orthogonal to the vector 1, minus 1, 2. 155 00:08:59,650 --> 00:09:00,540 How do you know that? 156 00:09:00,540 --> 00:09:03,890 Because this left-hand side, x minus y plus 2z, 157 00:09:03,890 --> 00:09:10,350 is equal to [x, y, z] dot 1, minus 1, 2. 158 00:09:10,350 --> 00:09:12,380 And similarly from the third equation, 159 00:09:12,380 --> 00:09:14,270 you know that the vector [x, y, z] 160 00:09:14,270 --> 00:09:18,310 is orthogonal to the vector 1, minus 2, 2, 161 00:09:18,310 --> 00:09:22,930 because this left-hand side is equal to [x, y, z] dot 1, 162 00:09:22,930 --> 00:09:25,160 minus 2, 2. 163 00:09:25,160 --> 00:09:26,040 Yeah? 164 00:09:26,040 --> 00:09:27,700 And that's equal to 0. 165 00:09:27,700 --> 00:09:30,210 So from the second and third equations, 166 00:09:30,210 --> 00:09:32,370 you know that you're looking for a vector that's 167 00:09:32,370 --> 00:09:36,290 orthogonal to both x-- or sorry-- both 1, 168 00:09:36,290 --> 00:09:40,039 minus 1, 2, and 1, minus 2, 2. 169 00:09:40,039 --> 00:09:41,580 How do you get a vector perpendicular 170 00:09:41,580 --> 00:09:42,840 to two known vectors? 171 00:09:42,840 --> 00:09:44,510 Well, you just take their cross product. 172 00:09:44,510 --> 00:09:46,110 So let's go back over here. 173 00:09:46,110 --> 00:10:04,750 So to find one, you take a cross product 174 00:10:04,750 --> 00:10:07,380 of two rows of the coefficient matrix. 175 00:10:07,380 --> 00:10:10,310 So in this case, for example, we can take these rows, 1, 176 00:10:10,310 --> 00:10:13,210 minus 1, 2; and 1, minus 2, 2. 177 00:10:13,210 --> 00:10:18,000 So, for example, the vector 1, minus 1, 178 00:10:18,000 --> 00:10:24,549 2-- OK-- cross the vector 1, minus 2, 2. 179 00:10:24,549 --> 00:10:26,215 Now I've kind of run out of board space, 180 00:10:26,215 --> 00:10:28,631 so I'm not going to work out precisely what this vector is 181 00:10:28,631 --> 00:10:29,260 for you. 182 00:10:29,260 --> 00:10:32,090 But if you like, you can certainly check. 183 00:10:32,090 --> 00:10:34,017 You can compute this cross product out 184 00:10:34,017 --> 00:10:35,850 with our nice formula for the cross product. 185 00:10:35,850 --> 00:10:37,830 It will give you some vector, and then you 186 00:10:37,830 --> 00:10:40,220 can check that that vector is indeed 187 00:10:40,220 --> 00:10:42,640 a solution of the homogeneous system. 188 00:10:42,640 --> 00:10:45,117 So that will give us a second solution 189 00:10:45,117 --> 00:10:46,200 of the homogeneous system. 190 00:10:46,200 --> 00:10:50,140 Nontrivial we say, because it's not just the 0 solution. 191 00:10:50,140 --> 00:10:54,090 So to quickly recap, we had a system of linear equations. 192 00:10:54,090 --> 00:10:57,380 I've now crossed out what the original right-hand side was. 193 00:10:57,380 --> 00:10:59,100 We had a system of linear equations, 194 00:10:59,100 --> 00:11:03,540 and we were looking for a choice of c for which that system had 195 00:11:03,540 --> 00:11:06,700 a unique solution and for which the corresponding homogeneous 196 00:11:06,700 --> 00:11:08,340 system had a unique solution. 197 00:11:08,340 --> 00:11:11,490 And the values of c that make that work are precisely 198 00:11:11,490 --> 00:11:15,470 the values of c such that the coefficient matrix 199 00:11:15,470 --> 00:11:17,030 has a non-zero determinant. 200 00:11:17,030 --> 00:11:18,975 So that's true for both parts a and b. 201 00:11:18,975 --> 00:11:22,920 And for part c, when we were looking for what values of c 202 00:11:22,920 --> 00:11:27,550 give the homogeneous system infinitely many solutions, 203 00:11:27,550 --> 00:11:30,150 the answer is any other value of c. 204 00:11:30,150 --> 00:11:34,140 Any value of c for which the coefficient matrix does 205 00:11:34,140 --> 00:11:37,635 have 0 determinant will give you infinitely many solutions 206 00:11:37,635 --> 00:11:40,530 in the homogeneous case, and in non-homogeneous cases 207 00:11:40,530 --> 00:11:44,630 will either give you 0 solutions or infinitely many solutions. 208 00:11:44,630 --> 00:11:46,390 And then we also at the end, we briefly 209 00:11:46,390 --> 00:11:53,080 discussed one way to find nontrivial solutions 210 00:11:53,080 --> 00:11:55,965 in the homogeneous case when there are infinitely 211 00:11:55,965 --> 00:11:57,180 many solutions. 212 00:11:57,180 --> 00:11:58,954 So I'll end there.