1 00:00:10,570 --> 00:00:13,000 PROFESSOR: Hi, everyone. 2 00:00:13,000 --> 00:00:17,530 So for the first part of this course, 3 00:00:17,530 --> 00:00:20,250 we've learned basically the ins and outs 4 00:00:20,250 --> 00:00:21,990 of solving linear systems of equations. 5 00:00:24,800 --> 00:00:29,760 Today we're going to do a little review of the basic concepts. 6 00:00:29,760 --> 00:00:35,520 Hopefully we'll see a few of them in the following problem. 7 00:00:35,520 --> 00:00:37,660 We're given a square matrix A-- a three 8 00:00:37,660 --> 00:00:42,040 by three square matrix A-- where the last entry is a parameter 9 00:00:42,040 --> 00:00:43,570 k. 10 00:00:43,570 --> 00:00:46,200 And this parameter will vary. 11 00:00:46,200 --> 00:00:54,620 And we'll see what happens to the system of equations A*x 12 00:00:54,620 --> 00:01:01,180 equal to [2, 3, 7], for which k it has a unique solution, 13 00:01:01,180 --> 00:01:04,260 for which k it has infinitely many solutions. 14 00:01:04,260 --> 00:01:06,710 Then we'll find the LU decomposition. 15 00:01:06,710 --> 00:01:09,800 And finally, we'll write down the complete solution, 16 00:01:09,800 --> 00:01:11,087 the system. 17 00:01:11,087 --> 00:01:12,670 So I'll give you a few minutes to work 18 00:01:12,670 --> 00:01:14,630 this problem on your own. 19 00:01:14,630 --> 00:01:16,710 And then please come back and see how I do it. 20 00:01:24,810 --> 00:01:26,980 All right, welcome back. 21 00:01:26,980 --> 00:01:33,510 So let's start with part A. For which k does this system, 22 00:01:33,510 --> 00:01:37,720 A*x equal [2, 3, 7], have a unique solution? 23 00:01:37,720 --> 00:01:46,310 So what do we know about square systems of linear equations? 24 00:01:46,310 --> 00:01:51,630 They have a unique solution when the matrix A is invertible. 25 00:01:51,630 --> 00:01:55,230 So now, when is A invertible? 26 00:01:55,230 --> 00:01:58,590 It is invertible when it is of full rank. 27 00:01:58,590 --> 00:02:01,240 And how do we figure this out? 28 00:02:01,240 --> 00:02:04,770 We do it by performing row operations. 29 00:02:04,770 --> 00:02:07,245 We do it by doing eliminations on the matrix. 30 00:02:10,490 --> 00:02:14,360 But since we want to simulate an exam setting, 31 00:02:14,360 --> 00:02:18,910 it always pays off to see what tasks lie ahead of us. 32 00:02:18,910 --> 00:02:25,000 So in part C, we're asked to find the LU decomposition. 33 00:02:25,000 --> 00:02:28,540 This means that when we do row operations, 34 00:02:28,540 --> 00:02:34,020 we'd better keep track what row operations we're doing exactly. 35 00:02:34,020 --> 00:02:38,660 In particular, we'll write them down as elementary matrices. 36 00:02:38,660 --> 00:02:45,070 And in part D, we'll be asked to compute the complete solution. 37 00:02:45,070 --> 00:02:51,520 And therefore it's good to do row operations 38 00:02:51,520 --> 00:02:57,985 on the augmented matrix A. So let's do this. 39 00:02:57,985 --> 00:03:00,330 I'm going to write this. 40 00:03:00,330 --> 00:03:12,210 The augmented matrix A is the following beast, 1, 1, 1; 1 2, 41 00:03:12,210 --> 00:03:21,440 3; 3, 4, k; and then 2, 3, 7. 42 00:03:25,280 --> 00:03:31,430 So first thing, we subtract a multiple of row one 43 00:03:31,430 --> 00:03:32,400 from row two. 44 00:03:32,400 --> 00:03:36,540 And it's exactly negative 1 times 45 00:03:36,540 --> 00:03:40,360 the first row plus the second. 46 00:03:40,360 --> 00:03:45,990 Let me write down the corresponding elementary matrix 47 00:03:45,990 --> 00:03:47,340 that does this. 48 00:03:47,340 --> 00:03:51,300 It's E_(2,1). 49 00:03:51,300 --> 00:03:55,730 And it's lower diagonal with 1's on the diagonal. 50 00:03:55,730 --> 00:03:59,670 And it's going to be exactly minus 1 51 00:03:59,670 --> 00:04:02,300 in the first entry of the second row. 52 00:04:04,870 --> 00:04:12,850 So we get 1, 1, 1, 2; 0, 1, 2, 1. 53 00:04:15,460 --> 00:04:18,620 And we copy down the third row. 54 00:04:21,810 --> 00:04:25,660 Now we subtract a multiple of the first row 55 00:04:25,660 --> 00:04:27,550 from the third one. 56 00:04:27,550 --> 00:04:30,790 And let me write this here. 57 00:04:34,890 --> 00:04:37,640 Yeah, we'll multiply the first row by negative 3, 58 00:04:37,640 --> 00:04:40,800 and add it to the third one. 59 00:04:40,800 --> 00:04:45,740 This is accomplished by the elementary matrix E_(3,1) which 60 00:04:45,740 --> 00:04:51,530 is 1, 1, 1, negative three, and then 0, 0. 61 00:04:54,320 --> 00:05:01,030 OK, 1, 1, 1, 2; 0, 1, 2, 1. 62 00:05:01,030 --> 00:05:03,250 We copy the first two rows. 63 00:05:03,250 --> 00:05:10,630 And then the third one will be 0, 1, k minus 3, 64 00:05:10,630 --> 00:05:14,750 and 7 minus 3 times 2, 7 minus 6, 1. 65 00:05:17,430 --> 00:05:22,413 We have essentially one last row operation to perform. 66 00:05:22,413 --> 00:05:23,560 Let me do it here. 67 00:05:26,300 --> 00:05:31,970 So we'll subtract the second row from the third one. 68 00:05:31,970 --> 00:05:48,450 And we'll get 1, 1, 1, 2; 0, 1, 2, 1; 0, 0, k minus 5, 69 00:05:48,450 --> 00:05:51,300 and then 0. 70 00:05:51,300 --> 00:05:57,150 And this was achieved by the elementary matrix E_(3,2), 71 00:05:57,150 --> 00:06:05,780 which was 1, 1, 1, and then negative 1. 72 00:06:05,780 --> 00:06:10,040 Because we multiplied the second row by negative 1 73 00:06:10,040 --> 00:06:13,410 and added it to the third one. 74 00:06:13,410 --> 00:06:24,410 So we got to a matrix, which is upper triangular. 75 00:06:24,410 --> 00:06:30,920 And we want to figure out: for which value of the parameter k 76 00:06:30,920 --> 00:06:35,730 is this matrix of full rank. 77 00:06:38,310 --> 00:06:39,320 This is a pivot. 78 00:06:39,320 --> 00:06:40,440 This is a pivot. 79 00:06:40,440 --> 00:06:43,200 And we want this one to be a pivot as well. 80 00:06:43,200 --> 00:06:51,410 And that happens when k minus 5 is not 0. 81 00:06:51,410 --> 00:06:58,000 So when k is different from 5, the matrix A is of full rank. 82 00:06:58,000 --> 00:07:02,330 And therefore the system A*x equals to [2, 3, 83 00:07:02,330 --> 00:07:05,220 7] has a unique solution. 84 00:07:05,220 --> 00:07:14,960 Now part B. For which k do we have infinitely many solutions? 85 00:07:14,960 --> 00:07:21,160 So when are we in such a situation? 86 00:07:21,160 --> 00:07:25,750 We are in such a situation when the null space of the matrix A 87 00:07:25,750 --> 00:07:28,990 is nontrivial. 88 00:07:28,990 --> 00:07:32,450 So the null space will be nontrivial 89 00:07:32,450 --> 00:07:38,230 when this k minus 5 number here, which 90 00:07:38,230 --> 00:07:42,760 is what's the pivot in the first case, is 0. 91 00:07:42,760 --> 00:07:50,030 So k minus 5 equals to 0. 92 00:07:50,030 --> 00:07:54,260 You see there's a little caveat here. 93 00:07:54,260 --> 00:07:57,990 When k is equal to 5, we get the third row 94 00:07:57,990 --> 00:08:02,760 of the augmented matrix, 0, 0, 0, equal to 0. 95 00:08:02,760 --> 00:08:05,250 This means that the matrix is actually consistent, 96 00:08:05,250 --> 00:08:10,090 and we indeed have a solution But if this entry were nonzero, 97 00:08:10,090 --> 00:08:12,000 then we would get no solutions. 98 00:08:15,240 --> 00:08:24,850 Now off to part C. We want to compute the LU decomposition. 99 00:08:24,850 --> 00:08:30,040 Well, we already got what the matrix U 100 00:08:30,040 --> 00:08:34,470 is through performing row operations. 101 00:08:34,470 --> 00:08:35,870 It's this guy here. 102 00:08:35,870 --> 00:08:47,284 Let me write it down-- 1, 1, 1; 0 1, 2; 0, 0, k minus 5. 103 00:08:47,284 --> 00:08:52,370 And when k is equal to 4, this entry's negative 1. 104 00:08:56,050 --> 00:08:59,330 And now what about the matrix L? 105 00:08:59,330 --> 00:09:02,710 Well, how did we get to this U? 106 00:09:02,710 --> 00:09:07,460 We had the matrix A. We got the matrix U. 107 00:09:07,460 --> 00:09:11,670 And what we did was first we applied E_(2,1). 108 00:09:11,670 --> 00:09:16,840 Then we applied E_(3,1) and then E_(3,2). 109 00:09:24,500 --> 00:09:28,170 We get A by inverting this equation. 110 00:09:28,170 --> 00:09:38,860 So it's going to be E_(2,1) inverse E_(3,1) inverse E_(3,2) 111 00:09:38,860 --> 00:09:48,120 inverse times U. And this is our matrix L. 112 00:09:48,120 --> 00:09:50,710 And we know it's fairly easy to invert these elementary 113 00:09:50,710 --> 00:09:56,755 matrices E. We flip the signs of the off-diagonal entries. 114 00:10:01,280 --> 00:10:04,400 I'm not going to write down again 115 00:10:04,400 --> 00:10:06,570 the inverses of these guys. 116 00:10:09,500 --> 00:10:11,780 I'm just going to write the product of the inverses. 117 00:10:11,780 --> 00:10:15,480 And that's also very easy to compute. 118 00:10:15,480 --> 00:10:18,380 Because one, we invert the signs. 119 00:10:18,380 --> 00:10:28,060 We just send the numbers in their corresponding entry of L. 120 00:10:28,060 --> 00:10:30,280 I mean the following thing. 121 00:10:30,280 --> 00:10:33,390 So minus 1 becomes a 1. 122 00:10:33,390 --> 00:10:38,945 And it comes here, in its respective entry. 123 00:10:42,820 --> 00:10:50,720 For E_(3,1), we flip the sign, first 3, 124 00:10:50,720 --> 00:10:54,350 and we plug it in here. 125 00:10:54,350 --> 00:10:59,570 And for E_(3,2), we flip the sign of this guy, becomes 1, 126 00:10:59,570 --> 00:11:01,030 and we plug it in here. 127 00:11:03,700 --> 00:11:07,120 So give me a few moments to erase the board, 128 00:11:07,120 --> 00:11:09,500 and then I'll do part four. 129 00:11:13,520 --> 00:11:18,650 We're back, and we're going to do part D now. 130 00:11:18,650 --> 00:11:21,640 So we need to find the complete solution 131 00:11:21,640 --> 00:11:24,130 of the system for all k. 132 00:11:24,130 --> 00:11:26,950 And we saw that for k equal to 5, 133 00:11:26,950 --> 00:11:30,650 the system had many, many solutions. 134 00:11:30,650 --> 00:11:34,280 And for k not equal to 5, it had only one. 135 00:11:34,280 --> 00:11:38,410 So first let's look at the case k not 136 00:11:38,410 --> 00:11:42,225 equal to 5, when the matrix A was invertible. 137 00:11:46,840 --> 00:11:51,830 It's not hard to see what the solution of the system then is. 138 00:11:51,830 --> 00:11:54,960 It's going to be-- let me just write it down. 139 00:12:00,420 --> 00:12:05,690 So when k is not equal to 5, this was nonzero. 140 00:12:05,690 --> 00:12:11,520 Therefore, x_3 needs to be 0. 141 00:12:11,520 --> 00:12:16,370 When x_3 is 0, we have x_2 plus 2 times x_3. 142 00:12:16,370 --> 00:12:20,250 So x_2 plus 0 equals 1. 143 00:12:20,250 --> 00:12:24,050 Therefore x_2 is 1. 144 00:12:24,050 --> 00:12:27,380 And then we go back to the first row. 145 00:12:27,380 --> 00:12:32,810 We have x_1 plus x_2 plus x_3 equals 2. 146 00:12:32,810 --> 00:12:38,880 So x_1 plus 1 plus 0 equals 2. 147 00:12:38,880 --> 00:12:40,810 So x_1 plus 1 equals 2. 148 00:12:40,810 --> 00:12:43,860 And therefore x_1 is 1. 149 00:12:43,860 --> 00:12:45,600 Good. 150 00:12:45,600 --> 00:12:51,580 Now what about k equal to 5? 151 00:12:51,580 --> 00:12:58,480 Then we see that x_3 is a free variable. 152 00:12:58,480 --> 00:13:04,125 So the solution will be [x 1, x 2, x 3]. 153 00:13:07,650 --> 00:13:13,800 x_3 can be any number c. 154 00:13:13,800 --> 00:13:16,420 From the second row, we'll get the value of x_2. 155 00:13:16,420 --> 00:13:19,190 It's 1 minus 2 times x_3. 156 00:13:19,190 --> 00:13:22,430 So 1 minus 2 times c. 157 00:13:22,430 --> 00:13:37,384 And x_1 is 2 minus x_2 minus x_3. 158 00:13:37,384 --> 00:13:39,480 So let me rewrite this. 159 00:13:39,480 --> 00:13:45,670 It's 2 minus x_2 is 1 minus-- aah, 160 00:13:45,670 --> 00:13:53,051 chalk-- 2c, minus c, 1 minus 2c, c. 161 00:13:56,760 --> 00:14:00,400 So we'll decompose this vector here 162 00:14:00,400 --> 00:14:02,615 into a component which is independent of c 163 00:14:02,615 --> 00:14:06,440 and a component which is a multiple of c. 164 00:14:06,440 --> 00:14:10,840 So this is 2 minus 1. 165 00:14:10,840 --> 00:14:20,790 It should be [1, 1, 0] plus c times-- 166 00:14:20,790 --> 00:14:25,830 we'll have two c minus c, c, so c times 1. 167 00:14:25,830 --> 00:14:29,692 Here we'll have minus 2c so negative 2. 168 00:14:29,692 --> 00:14:33,290 And here we'll have 1. 169 00:14:33,290 --> 00:14:38,470 And thus we get the particular solution for the system 170 00:14:38,470 --> 00:14:43,160 and the special solution for the system. 171 00:14:43,160 --> 00:14:45,420 We're kind of done here. 172 00:14:45,420 --> 00:14:48,770 If you're at an exam, you should immediately 173 00:14:48,770 --> 00:14:50,100 start the next problem. 174 00:14:50,100 --> 00:14:52,530 Good luck, and Ill see you later.