1 00:00:02,990 --> 00:00:04,850 GILBERT STRANG: This video is about one 2 00:00:04,850 --> 00:00:07,610 of the key applications of ordinary differential 3 00:00:07,610 --> 00:00:14,120 equations to electrical flow, flow of currents in a network. 4 00:00:14,120 --> 00:00:18,000 And so I drew a network, a very simple network. 5 00:00:18,000 --> 00:00:21,930 It's just called an RLC loop. 6 00:00:21,930 --> 00:00:24,876 It's only got one loop, so it's a really simple network. 7 00:00:26,530 --> 00:00:31,550 The R stands for resistance to the flow. 8 00:00:31,550 --> 00:00:34,680 The L stands for an inductance. 9 00:00:34,680 --> 00:00:36,010 And the C is the. 10 00:00:36,010 --> 00:00:39,000 Capacitance those are the three elements 11 00:00:39,000 --> 00:00:47,660 of a simple linear constant coefficient problem associated 12 00:00:47,660 --> 00:00:49,240 with one loop. 13 00:00:49,240 --> 00:00:52,770 And then there is a switch, which I'll close, 14 00:00:52,770 --> 00:00:55,180 and the flow will begin. 15 00:00:55,180 --> 00:00:59,420 And there is a voltage source, so like a battery, 16 00:00:59,420 --> 00:01:03,940 or maybe let's make this alternating current. 17 00:01:03,940 --> 00:01:08,470 So the voltage source will be some voltage 18 00:01:08,470 --> 00:01:13,750 times an e to the i omega t. 19 00:01:13,750 --> 00:01:17,300 So we're going to have alternating current. 20 00:01:17,300 --> 00:01:22,810 And the question is, what is the current? 21 00:01:22,810 --> 00:01:25,590 We have to find the current, I. So the current 22 00:01:25,590 --> 00:01:34,575 is I of t going around the loop. 23 00:01:38,040 --> 00:01:40,240 And we saw our differential equation 24 00:01:40,240 --> 00:01:44,870 will have that unknown I of t, rather than my usual y. 25 00:01:44,870 --> 00:01:47,400 I'm going to use I for current. 26 00:01:47,400 --> 00:01:56,220 Again, this is an RLC loop that everybody has to understand, 27 00:01:56,220 --> 00:02:03,510 as in electrical engineering. 28 00:02:03,510 --> 00:02:08,699 So I'm going to have a second order differential equation. 29 00:02:08,699 --> 00:02:11,300 Well, you'll see what that equation is. 30 00:02:11,300 --> 00:02:14,760 So you'll remember Ohm's law. 31 00:02:14,760 --> 00:02:19,620 That the voltage is the current times the resistance. 32 00:02:19,620 --> 00:02:28,560 So this gives me a voltage across the resistor. 33 00:02:28,560 --> 00:02:31,920 If the current is I and the resistance is R, 34 00:02:31,920 --> 00:02:39,200 then the voltage drop from here to here is I times R. 35 00:02:39,200 --> 00:02:40,180 So that's that term. 36 00:02:42,940 --> 00:02:49,170 But now I have also my current is changing with time. 37 00:02:49,170 --> 00:02:50,670 This is alternating current. 38 00:02:50,670 --> 00:02:52,360 It's going up and down. 39 00:02:52,360 --> 00:03:00,600 So the current is also going through the inductance. 40 00:03:00,600 --> 00:03:05,560 And there, the voltage drop across the inductance 41 00:03:05,560 --> 00:03:07,090 has this form. 42 00:03:07,090 --> 00:03:10,000 The derivative of the current comes into it. 43 00:03:10,000 --> 00:03:13,830 And in the capacitance, which is building up charge, 44 00:03:13,830 --> 00:03:17,170 the integral of the current comes in. 45 00:03:17,170 --> 00:03:21,630 So there, that's the physical equation that 46 00:03:21,630 --> 00:03:25,710 expresses this voltage law, which 47 00:03:25,710 --> 00:03:31,980 says that around a closed loop-- this is a closed, 48 00:03:31,980 --> 00:03:36,900 loops are closed-- add to 0. 49 00:03:36,900 --> 00:03:42,720 So I have four terms, and they combine to give us 0. 50 00:03:42,720 --> 00:03:46,040 So there's an equation I'd like to solve. 51 00:03:46,040 --> 00:03:49,520 And how am I going to solve that equation? 52 00:03:49,520 --> 00:03:54,830 By the standard idea which applies 53 00:03:54,830 --> 00:03:57,430 when I have constant coefficients 54 00:03:57,430 --> 00:04:03,680 and I have a pure exponential forcing term. 55 00:04:03,680 --> 00:04:09,240 I look for a solution that is a multiple of that exponential, 56 00:04:09,240 --> 00:04:09,946 right? 57 00:04:09,946 --> 00:04:12,540 The solution to differential equations 58 00:04:12,540 --> 00:04:14,970 with constant coefficients, if they 59 00:04:14,970 --> 00:04:17,480 have an exponential forcing, then 60 00:04:17,480 --> 00:04:25,040 the solution is I equals some, shall 61 00:04:25,040 --> 00:04:30,520 I say W e to the i omega t. 62 00:04:30,520 --> 00:04:35,860 Some multiple of the source gives me the solution 63 00:04:35,860 --> 00:04:37,520 to that differential equation. 64 00:04:37,520 --> 00:04:41,280 Well, it's actually a differential integral equation. 65 00:04:41,280 --> 00:04:45,140 I can make it a more familiar looking differential equation 66 00:04:45,140 --> 00:04:47,920 by taking the derivative of every term. 67 00:04:47,920 --> 00:04:49,400 Suppose I do that. 68 00:04:49,400 --> 00:04:52,050 Suppose I take the derivative of every term, just to make 69 00:04:52,050 --> 00:04:54,190 it look really familiar. 70 00:04:54,190 --> 00:04:58,900 That would be L times I double prime. 71 00:04:58,900 --> 00:05:01,280 Taking the derivative of the derivative. 72 00:05:01,280 --> 00:05:05,560 This would be RI prime. 73 00:05:05,560 --> 00:05:08,860 The derivative of the integral would be just I itself. 74 00:05:08,860 --> 00:05:13,010 So I'd have 1 over C I. And I would 75 00:05:13,010 --> 00:05:19,140 have the derivative here, I omega V e to the I omega t. 76 00:05:22,160 --> 00:05:27,110 So it's just a standard second order 77 00:05:27,110 --> 00:05:30,410 constant coefficient linear differential equation. 78 00:05:30,410 --> 00:05:34,470 And in fact, if you are a mechanical engineer, 79 00:05:34,470 --> 00:05:36,570 you would look at that and say, well, I 80 00:05:36,570 --> 00:05:39,760 don't know what L, R, and 1 over C stand for. 81 00:05:39,760 --> 00:05:44,350 But I know that I should see the mass, the damping, 82 00:05:44,350 --> 00:05:46,060 and the stiffness there. 83 00:05:46,060 --> 00:05:50,490 So we have a complete parallel between two important fields 84 00:05:50,490 --> 00:05:54,730 of engineering, the electric engineering with L, R, 85 00:05:54,730 --> 00:05:59,590 and 1 over C, mechanical engineering with M, 86 00:05:59,590 --> 00:06:04,090 B for damping, and K for stiffness. 87 00:06:04,090 --> 00:06:11,920 And actually, that parallel allowed analog computers-- 88 00:06:11,920 --> 00:06:16,140 which came before digital computers 89 00:06:16,140 --> 00:06:21,150 and lost out in that competition. 90 00:06:21,150 --> 00:06:27,430 An analog computer was just solving this linear equation 91 00:06:27,430 --> 00:06:34,010 by actually imposing the voltage and measuring the current. 92 00:06:34,010 --> 00:06:38,990 So an analog computer actually solved the equation 93 00:06:38,990 --> 00:06:44,240 by creating the model and measuring the answer. 94 00:06:44,240 --> 00:06:48,620 But we're not creating an analog computer here. 95 00:06:48,620 --> 00:06:53,240 We're just doing differential equations. 96 00:06:53,240 --> 00:06:57,570 So why don't I figure out what that W is. 97 00:06:57,570 --> 00:06:58,790 So what am I going to do? 98 00:06:58,790 --> 00:07:02,880 As always, I have this equation. 99 00:07:02,880 --> 00:07:04,820 I have a pure exponential. 100 00:07:04,820 --> 00:07:07,700 I look for a solution of that same form. 101 00:07:07,700 --> 00:07:09,070 I plug it in. 102 00:07:09,070 --> 00:07:11,910 And I get an equation for W. 103 00:07:11,910 --> 00:07:14,030 That's exactly what I'll do on the next board. 104 00:07:14,030 --> 00:07:19,290 I'll put W e to the I omega t into this equation 105 00:07:19,290 --> 00:07:24,170 and find W. Let's do it. 106 00:07:28,430 --> 00:07:31,030 Maybe I'll bring that down just a hair 107 00:07:31,030 --> 00:07:35,520 and I'll do it here where you can watch me do it. 108 00:07:35,520 --> 00:07:38,130 So I have L times the derivative. 109 00:07:38,130 --> 00:07:42,560 So I have L. The derivative will bring down 110 00:07:42,560 --> 00:07:51,640 an I omega L. Everything is going to multiply W and match 111 00:07:51,640 --> 00:07:58,590 V. When I put this into the equation, 112 00:07:58,590 --> 00:08:05,760 the derivative is an I omega L W e to the I omega t, 113 00:08:05,760 --> 00:08:08,910 and it's matching V e to the I omega t. 114 00:08:08,910 --> 00:08:15,980 Now, what happens when I put I in for that second term, 115 00:08:15,980 --> 00:08:22,240 R. I just get an R. R times W times e to the I omega t. 116 00:08:22,240 --> 00:08:23,230 No problem. 117 00:08:23,230 --> 00:08:28,500 And now finally, a 1 over C. The integral. 118 00:08:28,500 --> 00:08:34,090 The integral of the exponential brings down-- 119 00:08:34,090 --> 00:08:41,580 let me put it in the denominator neatly-- I divide by I omega 120 00:08:41,580 --> 00:08:44,450 when I integrate e to the I omega t. 121 00:08:44,450 --> 00:08:48,860 I have a division by I omega. 122 00:08:48,860 --> 00:08:50,240 That's it. 123 00:08:50,240 --> 00:08:52,190 That's it. 124 00:08:52,190 --> 00:08:56,630 Those are the three terms that come-- times W, the unknown. 125 00:08:56,630 --> 00:08:57,415 This is to find. 126 00:09:00,090 --> 00:09:03,010 And of course, we find it right away. 127 00:09:03,010 --> 00:09:08,870 We find W is V over-- and now we're 128 00:09:08,870 --> 00:09:13,970 seeing this I omega L plus R. Oh, 129 00:09:13,970 --> 00:09:17,280 let me combine the I omegas. 130 00:09:17,280 --> 00:09:21,440 Combine the real part and the imaginary part. 131 00:09:21,440 --> 00:09:27,120 The real part is R. And the imaginary part is I 132 00:09:27,120 --> 00:09:38,100 omega L minus 1 over I omega C. 133 00:09:38,100 --> 00:09:39,790 Straightforward. 134 00:09:39,790 --> 00:09:42,610 And that has a name. 135 00:09:42,610 --> 00:09:45,080 That is the resistance. 136 00:09:45,080 --> 00:09:47,370 But when there's also terms coming 137 00:09:47,370 --> 00:09:50,680 from an inductance and a capacitance, 138 00:09:50,680 --> 00:09:54,800 then the whole thing is called the impedance. 139 00:09:54,800 --> 00:10:02,260 So this whole thing, this whole denominator, 140 00:10:02,260 --> 00:10:04,625 is called the complex impedance. 141 00:10:09,790 --> 00:10:14,150 Believe me, all these ideas are so important. 142 00:10:14,150 --> 00:10:16,420 There's a whole vocabulary here. 143 00:10:16,420 --> 00:10:21,020 But you see, we've done exactly the same thing 144 00:10:21,020 --> 00:10:24,080 for other constant coefficient equations. 145 00:10:24,080 --> 00:10:28,910 We just called the coefficient A, B, C. Or maybe M, B, K. 146 00:10:28,910 --> 00:10:32,310 And now we have slightly different letters, 147 00:10:32,310 --> 00:10:35,430 but we don't have a new idea here. 148 00:10:35,430 --> 00:10:39,690 The idea is this 1 over, that 1 over the impedance, that 149 00:10:39,690 --> 00:10:48,130 will be the transfer function, which multiplies the source 150 00:10:48,130 --> 00:10:54,440 to give the complex number W. And W is a complex number. 151 00:10:54,440 --> 00:10:58,810 I have to now think about that. 152 00:10:58,810 --> 00:11:06,030 And that impedance is always called Z. 153 00:11:06,030 --> 00:11:12,910 So we now have a new letter for the important quantity that 154 00:11:12,910 --> 00:11:15,550 shows up in the denominator there. 155 00:11:15,550 --> 00:11:19,780 And again, its real part is the resistance. 156 00:11:19,780 --> 00:11:23,000 Its imaginary part comes from L and C. 157 00:11:23,000 --> 00:11:26,200 So we can easily see how large-- what's 158 00:11:26,200 --> 00:11:28,560 the size of that impedance? 159 00:11:28,560 --> 00:11:35,830 What's going to be the magnitude of this current? 160 00:11:35,830 --> 00:11:37,640 We want the size of that number. 161 00:11:37,640 --> 00:11:39,980 V is the size of the voltage. 162 00:11:39,980 --> 00:11:42,370 Here is the size of the impedance. 163 00:11:42,370 --> 00:11:45,360 And the answer will give us the size of W. 164 00:11:45,360 --> 00:11:48,660 I'm using size or magnitude to say 165 00:11:48,660 --> 00:11:51,500 that when I only do magnitudes, you 166 00:11:51,500 --> 00:11:53,930 won't be seeing the phase lag. 167 00:11:53,930 --> 00:11:58,120 So complex numbers, like this complex number 168 00:11:58,120 --> 00:12:00,890 has a magnitude which we're about to write down. 169 00:12:00,890 --> 00:12:05,590 And also it has a phase lag that tells us 170 00:12:05,590 --> 00:12:07,920 how much is in the imaginary part 171 00:12:07,920 --> 00:12:09,710 and how much is in the real part. 172 00:12:09,710 --> 00:12:11,750 But the magnitude is easy. 173 00:12:11,750 --> 00:12:14,300 What's the magnitude of a complex number? 174 00:12:14,300 --> 00:12:19,790 It's the real part squared and the imaginary part squared. 175 00:12:19,790 --> 00:12:22,830 Oh, that should have been a plus there, I think. 176 00:12:22,830 --> 00:12:26,750 I don't know how it became a minus. 177 00:12:26,750 --> 00:12:30,860 It will become a minus, so I was thinking 178 00:12:30,860 --> 00:12:33,920 if I put the I up there. 179 00:12:33,920 --> 00:12:35,840 Let me show you what I'm saying. 180 00:12:35,840 --> 00:12:41,300 The imaginary part is omega L minus 1 181 00:12:41,300 --> 00:12:49,260 over omega C. What I'm saying is that if I put the I up there, 182 00:12:49,260 --> 00:12:55,520 then 1 over I is minus I. That's the brilliant step I just 183 00:12:55,520 --> 00:12:56,610 took there. 184 00:12:56,610 --> 00:13:00,470 So all that squared. 185 00:13:00,470 --> 00:13:03,000 Are you OK with that? 186 00:13:03,000 --> 00:13:05,950 It's the real part squared, which is the resistance. 187 00:13:05,950 --> 00:13:08,860 And this combination gives the imaginary part. 188 00:13:08,860 --> 00:13:10,140 We square that. 189 00:13:10,140 --> 00:13:12,630 That's maybe called the reactants. 190 00:13:12,630 --> 00:13:16,450 And the sum of those squares is the impedance squared, 191 00:13:16,450 --> 00:13:18,870 the magnitude. 192 00:13:18,870 --> 00:13:25,860 So we have essentially successfully solved 193 00:13:25,860 --> 00:13:32,940 a second order constant coefficient single equation 194 00:13:32,940 --> 00:13:35,930 for the current. 195 00:13:35,930 --> 00:13:36,990 What to do now. 196 00:13:36,990 --> 00:13:40,540 Just let me add a little bit more. 197 00:13:43,510 --> 00:13:46,580 Maybe just a comment. 198 00:13:46,580 --> 00:13:50,620 That video was about one loop. 199 00:13:50,620 --> 00:13:54,850 When I told Dr. Mohler that one of the applications, one 200 00:13:54,850 --> 00:13:57,700 of the real applications in this series of videos 201 00:13:57,700 --> 00:14:00,540 would be an RLC circuit, his reply 202 00:14:00,540 --> 00:14:04,940 was an RLC circuit is not an application, not 203 00:14:04,940 --> 00:14:07,090 a realistic application. 204 00:14:07,090 --> 00:14:08,980 One loop. 205 00:14:08,980 --> 00:14:14,620 So how do we proceed with a full scale circuit 206 00:14:14,620 --> 00:14:21,420 with many nodes, many resistors, many conductors, many edges? 207 00:14:21,420 --> 00:14:24,290 Well, we have a big decision to make. 208 00:14:24,290 --> 00:14:26,330 And that's the comment I want to make. 209 00:14:26,330 --> 00:14:27,190 They have a choice. 210 00:14:27,190 --> 00:14:31,770 They can use Kirchoff's current law at the nodes 211 00:14:31,770 --> 00:14:35,960 and solve for the voltages at those nodes. 212 00:14:35,960 --> 00:14:39,670 Or they can do as we did for one loop, 213 00:14:39,670 --> 00:14:43,590 use Kirchoff's voltage law around that one loop 214 00:14:43,590 --> 00:14:48,290 which said that the currents in the loop 215 00:14:48,290 --> 00:14:52,910 gave a total voltage drop adding to 0. 216 00:14:52,910 --> 00:14:57,260 So we solve the current equation for the unknown I. This 217 00:14:57,260 --> 00:15:00,050 is what we did for one loop. 218 00:15:00,050 --> 00:15:05,680 My message is just for a big system, this is the winner. 219 00:15:05,680 --> 00:15:10,110 So writing down the equations in terms 220 00:15:10,110 --> 00:15:13,480 of Kirchoff's current law, that the currents-- we 221 00:15:13,480 --> 00:15:16,860 get the nodal picture, the picture 222 00:15:16,860 --> 00:15:20,580 with an equation for every node instead of the picture 223 00:15:20,580 --> 00:15:22,700 for an equation for every loop. 224 00:15:22,700 --> 00:15:27,620 Because it's not so easy to see which are the loops to consider 225 00:15:27,620 --> 00:15:32,453 and which loops are combinations of other loops. 226 00:15:34,960 --> 00:15:36,740 The linear algebra is the question. 227 00:15:36,740 --> 00:15:40,780 And the linear algebra, to get the loop picture 228 00:15:40,780 --> 00:15:43,810 independent and clear, is more difficult 229 00:15:43,810 --> 00:15:46,620 than the node picture. 230 00:15:46,620 --> 00:15:51,790 The node picture with the unknown voltages, 231 00:15:51,790 --> 00:15:58,740 V at the nodes, is the good one. 232 00:15:58,740 --> 00:16:03,150 And the matrix that comes into that is the incidence matrix. 233 00:16:03,150 --> 00:16:07,340 It connects nodes and edges. 234 00:16:07,340 --> 00:16:09,960 It says how the network is put together. 235 00:16:09,960 --> 00:16:14,130 And that matrix, I'll study with a little bit of linear algebra. 236 00:16:14,130 --> 00:16:16,220 So that comes in a later video. 237 00:16:16,220 --> 00:16:19,180 If you look for incidence matrices, 238 00:16:19,180 --> 00:16:23,780 you'll see probably two videos about those very, very 239 00:16:23,780 --> 00:16:26,810 important and beautiful matrices. 240 00:16:26,810 --> 00:16:28,640 Thank you.