1 00:00:04,000 --> 00:00:08,000 All right. Good morning all. 2 00:00:08,000 --> 00:00:17,000 Today we embark on another new chapter in what we do. 3 00:00:17,000 --> 00:00:23,000 And the topic is going to be -- 4 00:00:41,000 --> 00:00:46,000 We will talk about this thing called an Operational Amplifier. 5 00:00:46,000 --> 00:00:51,000 Before I get into the lecture, I want to point out a couple of 6 00:00:51,000 --> 00:00:54,000 things. One is that you are going to 7 00:00:54,000 --> 00:00:59,000 hear about two big words in today's lecture. 8 00:00:59,000 --> 00:01:02,000 Two big and incredibly important words. 9 00:01:02,000 --> 00:01:08,000 And I want to mention those words to you right now so that 10 00:01:08,000 --> 00:01:12,000 when I come to them in lecture you can say OK, 11 00:01:12,000 --> 00:01:17,000 I better pay really close attention, these are important 12 00:01:17,000 --> 00:01:19,000 words. All right. 13 00:01:19,000 --> 00:01:24,000 One of them is abstraction. The second one is feedback. 14 00:01:24,000 --> 00:01:29,000 Two incredibly important concepts. 15 00:01:29,000 --> 00:01:32,000 Abstraction, you have been seeing a couple 16 00:01:32,000 --> 00:01:36,000 times during this course, once in the beginning where we 17 00:01:36,000 --> 00:01:39,000 abstracted out Maxwell's equations by focusing on a 18 00:01:39,000 --> 00:01:44,000 smaller playground and simply using KVL, KCL in place of those 19 00:01:44,000 --> 00:01:46,000 equations. A big abstraction. 20 00:01:46,000 --> 00:01:51,000 It turns out that almost all of EECS is based upon abstractions 21 00:01:51,000 --> 00:01:53,000 at various levels. In the first lecture, 22 00:01:53,000 --> 00:01:58,000 I also showed you the layer upon layer of abstraction that 23 00:01:58,000 --> 00:02:03,000 we built to be able to build interesting systems. 24 00:02:03,000 --> 00:02:06,000 The second big thing is feedback. 25 00:02:06,000 --> 00:02:11,000 And I am going to relate this to anti-lock breaks in cars. 26 00:02:11,000 --> 00:02:16,000 And so, you can wait and see how we do that. 27 00:02:16,000 --> 00:02:19,000 It's an incredibly important concept. 28 00:02:19,000 --> 00:02:24,000 Before we dive into the amplifier abstraction, 29 00:02:24,000 --> 00:02:30,000 let me first talk about something that you know. 30 00:02:30,000 --> 00:02:34,000 Start with something that you know and then lead up into the 31 00:02:34,000 --> 00:02:37,000 operational amplifier and its circuits. 32 00:02:37,000 --> 00:02:41,000 You know about the MOSFET amplifier. 33 00:02:46,000 --> 00:02:54,000 The MOSFET amplifier that you know about looked like this. 34 00:02:54,000 --> 00:02:59,000 It was based on a MOSFET. 35 00:03:03,000 --> 00:03:09,000 There was a VS supply. There was a vI input, 36 00:03:09,000 --> 00:03:14,000 a vO output and, as I said, a VS supply. 37 00:03:14,000 --> 00:03:22,000 So, this was a MOSFET circuit that you've seen before. 38 00:03:22,000 --> 00:03:30,000 One way of viewing this is that this circuit has three major 39 00:03:30,000 --> 00:03:35,000 ports. This here is the input port 40 00:03:35,000 --> 00:03:38,000 with voltage vI. This here, between the drain 41 00:03:38,000 --> 00:03:42,000 terminal and the ground, is the output port. 42 00:03:42,000 --> 00:03:47,000 I take the output between the drain terminal and ground. 43 00:03:47,000 --> 00:03:50,000 And, finally, we have a third port, 44 00:03:50,000 --> 00:03:53,000 which is this one. It is called the power port. 45 00:03:53,000 --> 00:03:58,000 I apply VS between this terminal here and the ground 46 00:03:58,000 --> 00:04:02,000 terminal. And that gives us the power 47 00:04:02,000 --> 00:04:04,000 port. This device here was a three 48 00:04:04,000 --> 00:04:08,000 port device. Input port or control port, 49 00:04:08,000 --> 00:04:12,000 output port and a power port. And so we looked at the circuit 50 00:04:12,000 --> 00:04:16,000 and did a whole bunch of analyses of it. 51 00:04:16,000 --> 00:04:20,000 Then what I can do at this point, now that you've seen 52 00:04:20,000 --> 00:04:24,000 this, it's often times interesting to think about 53 00:04:24,000 --> 00:04:30,000 abstracting this out into some kind of a building block. 54 00:04:30,000 --> 00:04:33,000 Much like in software, you write a procedure and you 55 00:04:33,000 --> 00:04:37,000 abstract out the internal details of the procedure in the 56 00:04:37,000 --> 00:04:41,000 procedure declaration and in the call that you make. 57 00:04:41,000 --> 00:04:44,000 In the same way, we can take this little device 58 00:04:44,000 --> 00:04:49,000 here and abstract that out into the following abstraction. 59 00:04:54,000 --> 00:05:00,000 We could abstract that out as a device that looks like this. 60 00:05:06,000 --> 00:05:12,000 I have my input port, I have my output port and I 61 00:05:12,000 --> 00:05:18,000 have my power port. So, I can apply VS here. 62 00:05:18,000 --> 00:05:25,000 Notice that I've taken these six terminals here, 63 00:05:25,000 --> 00:05:30,000 one, two, three, four, five and six, 64 00:05:30,000 --> 00:05:37,000 and put a box around it. And just exposed the terminals 65 00:05:37,000 --> 00:05:39,000 to you. And I need to tell you a little 66 00:05:39,000 --> 00:05:43,000 bit more about the internal properties, but suffice it to 67 00:05:43,000 --> 00:05:46,000 say that you can begin working with this little block. 68 00:05:46,000 --> 00:05:51,000 An even simpler version of this for many applications might just 69 00:05:51,000 --> 00:05:53,000 look like this, vI and vO where there is a 70 00:05:53,000 --> 00:05:57,000 ground that is shared among them that is implicit in this 71 00:05:57,000 --> 00:06:01,000 picture. And vI and vO can simply be the 72 00:06:01,000 --> 00:06:05,000 node voltages at these nodes. This is a progressively more 73 00:06:05,000 --> 00:06:08,000 abstract representation of this amplifier. 74 00:06:08,000 --> 00:06:11,000 What we can do is, provided we know, 75 00:06:11,000 --> 00:06:14,000 we can abstract out the relevant properties of this 76 00:06:14,000 --> 00:06:19,000 block and expose them outside. And the relevant properties 77 00:06:19,000 --> 00:06:22,000 might well be that, let's say here the properties 78 00:06:22,000 --> 00:06:27,000 may be that I in is always zero. I can also express to you the 79 00:06:27,000 --> 00:06:33,000 gain of this amplifier. I may also be able to tell you 80 00:06:33,000 --> 00:06:37,000 the Thevenin equivalent for the output. 81 00:06:37,000 --> 00:06:44,000 There are some properties that I can give you that will let you 82 00:06:44,000 --> 00:06:48,000 use this building block abstractly. 83 00:06:48,000 --> 00:06:55,000 Today, what we will do is introduce a powerful abstraction 84 00:06:55,000 --> 00:07:01,000 of a type of amplifier. This is called the operational 85 00:07:01,000 --> 00:07:09,000 amplifier or "op amp" for short. What I am going to do is give 86 00:07:09,000 --> 00:07:15,000 you a slightly more involved building block than the one I 87 00:07:15,000 --> 00:07:21,000 have shown you there. But suffice it to say that the 88 00:07:21,000 --> 00:07:28,000 idea is going to be the same. This building block looks like 89 00:07:28,000 --> 00:07:31,000 this. This building block has an 90 00:07:31,000 --> 00:07:37,000 input port. This building block also has a 91 00:07:37,000 --> 00:07:43,000 port in which to connect power or the power port. 92 00:07:43,000 --> 00:07:47,000 And the way I am going to connect power, 93 00:07:47,000 --> 00:07:52,000 I am going to connect a plus VS supply here. 94 00:07:52,000 --> 00:07:56,000 That is going to be my ground node. 95 00:07:56,000 --> 00:08:03,000 And I am going to connect a minus VS supply to this node 96 00:08:03,000 --> 00:08:08,000 here. So, these voltages are both VS. 97 00:08:08,000 --> 00:08:14,000 I want to apply a plus VS here and a negative VS out here. 98 00:08:14,000 --> 00:08:21,000 And I am going to take the output between the ground node 99 00:08:21,000 --> 00:08:27,000 and the output node of the operational amplifier and call 100 00:08:27,000 --> 00:08:32,000 that a vO. This is the output port. 101 00:08:32,000 --> 00:08:35,000 So, input port and output port and a power port. 102 00:08:35,000 --> 00:08:39,000 Think of this as a pattern where I have an input port 103 00:08:39,000 --> 00:08:42,000 across which I connect the input. 104 00:08:42,000 --> 00:08:46,000 I have a power port across which I connect a plus VS, 105 00:08:46,000 --> 00:08:49,000 minus VS supply, and then I take the output 106 00:08:49,000 --> 00:08:54,000 terminal and take a ground terminal, which is defined by 107 00:08:54,000 --> 00:08:58,000 external components of my circuitry, and use this as my 108 00:08:58,000 --> 00:09:02,000 reference node. Remember ground is just a 109 00:09:02,000 --> 00:09:06,000 reference node. I am going to use this as a 110 00:09:06,000 --> 00:09:09,000 reference node. These two are equal in 111 00:09:09,000 --> 00:09:11,000 magnitude. And take this as my output. 112 00:09:11,000 --> 00:09:16,000 And when I do something like this, I can build an even 113 00:09:16,000 --> 00:09:20,000 simpler, so this is an abstract differential input amplifier. 114 00:09:20,000 --> 00:09:23,000 In other words, this amplifier is going to 115 00:09:23,000 --> 00:09:26,000 amplify whatever I apply at the input. 116 00:09:26,000 --> 00:09:30,000 A slightly more abstract representation of this looks 117 00:09:30,000 --> 00:09:34,000 like this. vOUT and plus/minus vIN. 118 00:09:34,000 --> 00:09:38,000 This is a slightly more abstract representation where, 119 00:09:38,000 --> 00:09:42,000 remember, we are going to draw this again and again, 120 00:09:42,000 --> 00:09:46,000 maybe at least 38 or 39 times in this course. 121 00:09:46,000 --> 00:09:49,000 And, remember, each time you draw it, 122 00:09:49,000 --> 00:09:52,000 remember that there is an implicit power port, 123 00:09:52,000 --> 00:09:58,000 a plus/minus supply that is connected which we don't show. 124 00:09:58,000 --> 00:10:02,000 And I remember when I first learned about it a long time ago 125 00:10:02,000 --> 00:10:05,000 there was a confusion in me initially. 126 00:10:05,000 --> 00:10:08,000 How does this work? Where is the power coming from? 127 00:10:08,000 --> 00:10:13,000 Just remember that power comes from a plus/minus supply, 128 00:10:13,000 --> 00:10:16,000 and we just don't show that in this abstraction. 129 00:10:16,000 --> 00:10:20,000 Now, the details, a lot of details are in Chapter 130 00:10:20,000 --> 00:10:24,000 16 of your course notes. That's the reading for that. 131 00:10:24,000 --> 00:10:28,000 The other thing is that there are some other key properties of 132 00:10:28,000 --> 00:10:35,000 this amplifier. And let me discuss those very 133 00:10:35,000 --> 00:10:37,000 quickly. First of all, 134 00:10:37,000 --> 00:10:44,000 I can draw a circuit model for the amplifier. 135 00:10:44,000 --> 00:10:52,000 Make some room for myself here. And this is a circuit model for 136 00:10:52,000 --> 00:11:00,000 what we call the ideal operational amplifier. 137 00:11:00,000 --> 00:11:03,000 And the circuit model is going to look like this. 138 00:11:03,000 --> 00:11:08,000 This is an abstract device. And, in terms of analyzing how 139 00:11:08,000 --> 00:11:12,000 this behaves in a circuit, I am going to show you this 140 00:11:12,000 --> 00:11:15,000 abstract circuit that looks as follows. 141 00:11:15,000 --> 00:11:19,000 Some input v is applied at these two terminals here. 142 00:11:19,000 --> 00:11:23,000 And this terminal is called my v plus terminal and this is 143 00:11:23,000 --> 00:11:27,000 called my v minus terminal, so this corresponds to these 144 00:11:27,000 --> 00:11:32,000 two terminals. I am telling you that the 145 00:11:32,000 --> 00:11:36,000 current going in is going to be zero, so i plus is going to be 146 00:11:36,000 --> 00:11:39,000 zero and i minus is going to be zero. 147 00:11:39,000 --> 00:11:44,000 i plus is the current in here and i minus is the current into 148 00:11:44,000 --> 00:11:48,000 the v minus terminal, and both these currents are 149 00:11:48,000 --> 00:11:51,000 going to be zero in this device here. 150 00:11:51,000 --> 00:11:54,000 The output is going to look like this. 151 00:11:54,000 --> 00:12:00,000 Let me just call it vOUT to be consistent with this here. 152 00:12:00,000 --> 00:12:03,000 And taken with ground as my reference. 153 00:12:03,000 --> 00:12:07,000 The output is simply Av. In other words, 154 00:12:07,000 --> 00:12:12,000 what I am doing is I am going to model this as a device that 155 00:12:12,000 --> 00:12:16,000 has a dependent source at its output. 156 00:12:16,000 --> 00:12:22,000 And the dependent source here is a voltage controlled voltage 157 00:12:22,000 --> 00:12:25,000 source. It is a dependent source, 158 00:12:25,000 --> 00:12:30,000 it is a voltage controlled voltage source such that the 159 00:12:30,000 --> 00:12:37,000 output voltage is A times the voltage v across its input. 160 00:12:37,000 --> 00:12:42,000 This is actually very simple. Think of these three terminals 161 00:12:42,000 --> 00:12:46,000 I have shown you here. I applied input across these. 162 00:12:46,000 --> 00:12:51,000 And the output is going to be A times whatever I applied. 163 00:12:51,000 --> 00:12:54,000 And A is going to tend towards infinity. 164 00:12:54,000 --> 00:12:59,000 A is going to be huge. And specific values for A might 165 00:12:59,000 --> 00:13:05,000 be a hundred thousand or a million or things of that sort. 166 00:13:05,000 --> 00:13:09,000 Huge A in this abstract amplifier. 167 00:13:09,000 --> 00:13:15,000 In addition to that, the other properties are that 168 00:13:15,000 --> 00:13:21,000 it is going to have infinite input resistance. 169 00:13:21,000 --> 00:13:30,000 That means looking in this looks like an open circuit. 170 00:13:30,000 --> 00:13:35,000 The fact that this is open here implies the infinite input 171 00:13:35,000 --> 00:13:40,000 resistance across this port. What about the output here? 172 00:13:40,000 --> 00:13:44,000 Remember, this is a voltage source. 173 00:13:44,000 --> 00:13:49,000 And we have a zero output resistance, which means that no 174 00:13:49,000 --> 00:13:55,000 matter how the load affects this, as I apply a load this is 175 00:13:55,000 --> 00:14:01,000 going to behave like an ideal voltage source and keep holding 176 00:14:01,000 --> 00:14:06,000 the voltage constant based on whatever the function I 177 00:14:06,000 --> 00:14:10,000 establish here. And A is virtually infinite. 178 00:14:10,000 --> 00:14:14,000 Let me pause there for a few seconds and just dwell on this 179 00:14:14,000 --> 00:14:17,000 so you just understand what the basic device is. 180 00:14:17,000 --> 00:14:20,000 Following this basic definition, I am just going to 181 00:14:20,000 --> 00:14:23,000 build a whole bunch of fun little circuits. 182 00:14:23,000 --> 00:14:26,000 The analysis will be pretty straightforward, 183 00:14:26,000 --> 00:14:30,000 but this is a big conceptual leap here where there is some 184 00:14:30,000 --> 00:14:33,000 circuitry inside. Containing resistors, 185 00:14:33,000 --> 00:14:36,000 MOSFETs, a whole bunch of stuff in there. 186 00:14:36,000 --> 00:14:39,000 I am not telling you what is inside it. 187 00:14:39,000 --> 00:14:42,000 Much like I could build an abstract amplifier, 188 00:14:42,000 --> 00:14:46,000 I could put an abstract box around the amplifier you saw 189 00:14:46,000 --> 00:14:50,000 earlier, I want to put a box around some circuitry. 190 00:14:50,000 --> 00:14:53,000 I am not telling you what the circuitry is. 191 00:14:53,000 --> 00:14:57,000 And, if you are curious, you should look at page 581 of 192 00:14:57,000 --> 00:15:02,000 your course notes. There is an example solved. 193 00:15:02,000 --> 00:15:07,000 The example is for a differential amplifier. 194 00:15:07,000 --> 00:15:11,000 This is the small signal analysis chapter. 195 00:15:11,000 --> 00:15:17,000 That differential amplifier that's solved in that example is 196 00:15:17,000 --> 00:15:23,000 usually the first stage in an operational amplifier circuit. 197 00:15:23,000 --> 00:15:30,000 That differential amplifier is the first stage at the input. 198 00:15:30,000 --> 00:15:34,000 And that differential amplifier, as the name implies, 199 00:15:34,000 --> 00:15:39,000 amplifies not a single voltage but amplifies a differential 200 00:15:39,000 --> 00:15:42,000 voltage. Note that this guy amplifies 201 00:15:42,000 --> 00:15:46,000 the voltage difference between these two terminals. 202 00:15:46,000 --> 00:15:50,000 That's v here. And v is simply the same as v 203 00:15:50,000 --> 00:15:54,000 plus minus v minus. It's the node voltage here 204 00:15:54,000 --> 00:16:00,000 minus the node voltage here. That is what's amplified. 205 00:16:00,000 --> 00:16:03,000 It amplifies a difference. Therefore, it is called a 206 00:16:03,000 --> 00:16:06,000 difference amplifier or a differential amplifier. 207 00:16:06,000 --> 00:16:10,000 And so that input stage is what is inside the op amp. 208 00:16:10,000 --> 00:16:13,000 It's got a bunch of other circuitry like level shifters 209 00:16:13,000 --> 00:16:16,000 and so on. And at the output it has got a 210 00:16:16,000 --> 00:16:18,000 buffer. At at the output it has 211 00:16:18,000 --> 00:16:23,000 something that is reminiscent of the source follower circuit that 212 00:16:23,000 --> 00:16:26,000 you learned about in recitations, solved an example 213 00:16:26,000 --> 00:16:31,000 in the course notes and in your homework as well. 214 00:16:31,000 --> 00:16:35,000 And you solved a variant of the source follower on your quiz as 215 00:16:35,000 --> 00:16:38,000 well in problem two. So, a circuit that looks like 216 00:16:38,000 --> 00:16:42,000 that appears at the output. Remember, for the source 217 00:16:42,000 --> 00:16:46,000 follower, the resistance looking in from the output was very, 218 00:16:46,000 --> 00:16:49,000 very small. You have seen some of the 219 00:16:49,000 --> 00:16:53,000 pieces that go inside the amplifier, but we will deal with 220 00:16:53,000 --> 00:16:57,000 this as a building block and simply represent it using this 221 00:16:57,000 --> 00:17:02,000 abstract little circuit. To dwell on this a little 222 00:17:02,000 --> 00:17:06,000 longer, this little device here is the workhorse of the analog 223 00:17:06,000 --> 00:17:10,000 industry. Much like your primitive gate 224 00:17:10,000 --> 00:17:14,000 abstraction, your inverter and NAND gate and so on, 225 00:17:14,000 --> 00:17:18,000 much as your primitive inverter or NAND gate was from the 226 00:17:18,000 --> 00:17:21,000 foundations of the digital industry. 227 00:17:21,000 --> 00:17:25,000 Remember we learned how to build this little abstract 228 00:17:25,000 --> 00:17:30,000 device called a NAND gate or an inverter? 229 00:17:30,000 --> 00:17:34,000 We noticed that those form the foundations of very complicated 230 00:17:34,000 --> 00:17:38,000 microprocessors. Those were the building blocks 231 00:17:38,000 --> 00:17:41,000 of the digital industry. In the same way, 232 00:17:41,000 --> 00:17:45,000 this little beast here is the building block of the analog 233 00:17:45,000 --> 00:17:47,000 industry. Just to give you an analogy 234 00:17:47,000 --> 00:17:51,000 from software, think of this abstract little 235 00:17:51,000 --> 00:17:55,000 device as a library routine from a library of functions when you 236 00:17:55,000 --> 00:18:01,000 program in C++ or whatever. Can someone give me an example 237 00:18:01,000 --> 00:18:06,000 of an incredibly popular routine that we use all the time that 238 00:18:06,000 --> 00:18:11,000 may be called the workhorse of the software industry? 239 00:18:11,000 --> 00:18:13,000 Pardon? An abstraction, 240 00:18:13,000 --> 00:18:17,000 an abstract procedure. One example might be something 241 00:18:17,000 --> 00:18:21,000 like a printf. Printf is an abstract name for 242 00:18:21,000 --> 00:18:25,000 a procedure that goes and does something for you. 243 00:18:25,000 --> 00:18:31,000 It is amazing how we take the lowly printf for granted. 244 00:18:31,000 --> 00:18:34,000 I stick my printf into my program, it includes the 245 00:18:34,000 --> 00:18:37,000 standard IO library and it goes and prints a value. 246 00:18:37,000 --> 00:18:40,000 You won't believe how complicated the printf is. 247 00:18:40,000 --> 00:18:43,000 As you go into learning more advanced software subjects, 248 00:18:43,000 --> 00:18:46,000 implementing the printf is a nightmare. 249 00:18:46,000 --> 00:18:48,000 It is horrendously complicated. Just imagine. 250 00:18:48,000 --> 00:18:52,000 You give it a string and it has to go and print that on your 251 00:18:52,000 --> 00:18:55,000 terminal or on your Windows system or whatever. 252 00:18:55,000 --> 00:19:00,000 Think of the complicated steps it has to go through. 253 00:19:00,000 --> 00:19:02,000 But, as far as you're concerned, it's simple. 254 00:19:02,000 --> 00:19:05,000 Just print out something and you're done. 255 00:19:05,000 --> 00:19:08,000 The same way. Think of this as the printf of 256 00:19:08,000 --> 00:19:10,000 the analog business. It is really simple, 257 00:19:10,000 --> 00:19:13,000 and the analysis is going to be incredibly simple, 258 00:19:13,000 --> 00:19:17,000 it will be mind-bogglingly simple, but inside it, 259 00:19:17,000 --> 00:19:19,000 heavens forbid if you look inside it. 260 00:19:19,000 --> 00:19:22,000 Tell you what, go into to S-T-D-I-O dot in one 261 00:19:22,000 --> 00:19:25,000 of the library routines and just pore through printf. 262 00:19:25,000 --> 00:19:30,000 The world's worst horrendous macros are in there. 263 00:19:30,000 --> 00:19:33,000 I mean it is just nasty. The same way inside the op amp, 264 00:19:33,000 --> 00:19:35,000 it is nasty. You don't want to go there. 265 00:19:35,000 --> 00:19:38,000 Much like in your C programming in your classes, 266 00:19:38,000 --> 00:19:42,000 you were able to use printf without fully knowing how it was 267 00:19:42,000 --> 00:19:45,000 implemented. Probably some MIT god or some 268 00:19:45,000 --> 00:19:48,000 key graduate implemented it, but once it was implemented you 269 00:19:48,000 --> 00:19:52,000 just used it based on simple abstract rules as to how it 270 00:19:52,000 --> 00:19:54,000 behaved. You didn't have to know what 271 00:19:54,000 --> 00:19:57,000 was inside it to use it. The same way with the 272 00:19:57,000 --> 00:20:02,000 operational amplifier. So, just think of printf when 273 00:20:02,000 --> 00:20:06,000 you see this and just imagine how simple it is going to be to 274 00:20:06,000 --> 00:20:09,000 use it. You may think that I spend way 275 00:20:09,000 --> 00:20:12,000 too much time, ten minutes dwelling on this 276 00:20:12,000 --> 00:20:15,000 abstract concept, but I like to dwell on things 277 00:20:15,000 --> 00:20:18,000 that I think are incredibly important. 278 00:20:18,000 --> 00:20:21,000 The concept of abstraction is very important. 279 00:20:21,000 --> 00:20:25,000 And it's not just in software. The concept of abstraction 280 00:20:25,000 --> 00:20:30,000 pervades all of EECS. And if I were to give you a 281 00:20:30,000 --> 00:20:34,000 project to say go and ask every professor what is the one word 282 00:20:34,000 --> 00:20:38,000 that you think best describes all of EECS? 283 00:20:38,000 --> 00:20:41,000 Just pick one word. Go ask every single professor 284 00:20:41,000 --> 00:20:44,000 you know. What is a single word? 285 00:20:44,000 --> 00:20:48,000 If you were to characterize all of EECS with just one word, 286 00:20:48,000 --> 00:20:52,000 what might that word be? In my mind, it is the A word, 287 00:20:52,000 --> 00:20:54,000 abstraction. It is all over. 288 00:20:54,000 --> 00:20:58,000 If you do a grep on all the words used by all your 289 00:20:58,000 --> 00:21:03,000 professors in your four years here, I promise you the first 290 00:21:03,000 --> 00:21:08,000 one will be know. And the second one will be 291 00:21:08,000 --> 00:21:10,000 abstraction. Check it out. 292 00:21:10,000 --> 00:21:13,000 See if what I am saying is true or not. 293 00:21:13,000 --> 00:21:17,000 It is all over the place. In 6.001, how many times do you 294 00:21:17,000 --> 00:21:21,000 think the word abstraction was used in 6.001? 295 00:21:21,000 --> 00:21:25,000 It's all over the map. It's the A word all over. 296 00:21:25,000 --> 00:21:30,000 Imagine your shock when you see it being used in 002 because the 297 00:21:30,000 --> 00:21:35,000 same concept applies. We build more complicated 298 00:21:35,000 --> 00:21:40,000 systems by abstracting out the details of lesser objects, 299 00:21:40,000 --> 00:21:45,000 and then using those to build the more complicated systems. 300 00:21:45,000 --> 00:21:50,000 Abstraction is a very powerful mechanism of dealing with 301 00:21:50,000 --> 00:21:54,000 complexity. Next step is how do I go about 302 00:21:54,000 --> 00:21:58,000 using the op amp? Let me show you how it looks on 303 00:21:58,000 --> 00:22:03,000 a scope. What I am going to do is apply 304 00:22:03,000 --> 00:22:09,000 input to the op amp, I am going to look at the 305 00:22:09,000 --> 00:22:17,000 output, place the resistor RL to ground and look at the output. 306 00:22:17,000 --> 00:22:25,000 And here I am going to apply a plus VS and out here a minus VS. 307 00:22:25,000 --> 00:22:32,000 Again, remember that a plus VS simply looks like this and a 308 00:22:32,000 --> 00:22:40,000 minus VS simply looks like this. It's just an inverted VS 309 00:22:40,000 --> 00:22:45,000 applied here so I get a minus VS at this input. 310 00:22:45,000 --> 00:22:50,000 First of all, what I would like to do is as I 311 00:22:50,000 --> 00:22:57,000 change vIN, I am going to plot for you how vOUT looks. 312 00:22:57,000 --> 00:23:03,000 vIN and this is vO. I am going to plot vIN in terms 313 00:23:03,000 --> 00:23:08,000 of microvolts and vO in volts. vIN is going to have a very 314 00:23:08,000 --> 00:23:14,000 very small, the scale is going to be in microvolts because 315 00:23:14,000 --> 00:23:17,000 remember the gain of this is huge. 316 00:23:17,000 --> 00:23:21,000 It's on the order of ten to the sixth. 317 00:23:21,000 --> 00:23:25,000 It's huge. Small changes in vIN are going 318 00:23:25,000 --> 00:23:32,000 to cause massive changes in vO. I have a very fine scale on the 319 00:23:32,000 --> 00:23:36,000 X axis. What is going to happen if I 320 00:23:36,000 --> 00:23:39,000 somehow magically make vIN exactly zero? 321 00:23:39,000 --> 00:23:45,000 If I short these two terminals, if this was a completely ideal 322 00:23:45,000 --> 00:23:50,000 op amp, which it never is, if it's a completely ideal op 323 00:23:50,000 --> 00:23:53,000 amp, then my output should be zero. 324 00:23:53,000 --> 00:24:00,000 As I increase my vIN the output should be A times vIN. 325 00:24:00,000 --> 00:24:03,000 For some small value of vIN, small v, let's say one 326 00:24:03,000 --> 00:24:06,000 microvolt, the output should be one volt. 327 00:24:06,000 --> 00:24:10,000 A is a constant so this would look like a straight line. 328 00:24:10,000 --> 00:24:14,000 And let's say my supply voltages are 12 volts minus 12 329 00:24:14,000 --> 00:24:19,000 volts, if this were an ideal amplifier and I didn't have to 330 00:24:19,000 --> 00:24:23,000 worry about the supply, this would just go on extending 331 00:24:23,000 --> 00:24:25,000 forever. But I have a plus 12 volt 332 00:24:25,000 --> 00:24:27,000 supply and a minus 12 volt supply. 333 00:24:27,000 --> 00:24:32,000 My output cannot go past those limits. 334 00:24:32,000 --> 00:24:35,000 And so, therefore, my output kind of flattens out 335 00:24:35,000 --> 00:24:39,000 at these two points. And it is called hitting the 336 00:24:39,000 --> 00:24:42,000 rails. Output goes up and you hear a 337 00:24:42,000 --> 00:24:45,000 thunk sound and you hit the rails. 338 00:24:45,000 --> 00:24:49,000 When you play with op amps in your next lab, 339 00:24:49,000 --> 00:24:53,000 if you listen really, really carefully you may hear 340 00:24:53,000 --> 00:24:55,000 it. So, this saturates out. 341 00:24:55,000 --> 00:24:59,000 Not surprisingly, this region where the output 342 00:24:59,000 --> 00:25:05,000 saturates at the supply is called the saturation region. 343 00:25:05,000 --> 00:25:09,000 Remember, don't confuse it with-- It's not the same as your 344 00:25:09,000 --> 00:25:13,000 saturation in the MOSFET. It is a totally different 345 00:25:13,000 --> 00:25:16,000 thing. It is just happenstance that we 346 00:25:16,000 --> 00:25:20,000 call this saturation. And if you would like to think 347 00:25:20,000 --> 00:25:24,000 about it, you can think of it as the thunk region. 348 00:25:24,000 --> 00:25:27,000 That's probably more appropriate to distinguish it 349 00:25:27,000 --> 00:25:32,000 from the saturation region in the MOSFET. 350 00:25:32,000 --> 00:25:36,000 And, not surprisingly, this one is called the active 351 00:25:36,000 --> 00:25:39,000 region. And it is in this region that 352 00:25:39,000 --> 00:25:43,000 we use the op amp. Here it has hit the rails and 353 00:25:43,000 --> 00:25:48,000 is kind of dangling out there. It's not much use to us. 354 00:25:48,000 --> 00:25:53,000 It's in this active region that we use it because this is where 355 00:25:53,000 --> 00:25:58,000 the gain is seen. Now, it turns out that this is 356 00:25:58,000 --> 00:26:01,000 a very high gain device. It is very skittish. 357 00:26:01,000 --> 00:26:05,000 This gain is kind of a really funny thing. 358 00:26:05,000 --> 00:26:08,000 It's dependent on a bunch of factors. 359 00:26:08,000 --> 00:26:10,000 This could be temperature dependent. 360 00:26:10,000 --> 00:26:15,000 This gain here and this curve is just completely skittish. 361 00:26:15,000 --> 00:26:20,000 It could depend on temperature. It could depend on time of day. 362 00:26:20,000 --> 00:26:24,000 It could depend on what medication this amplifier is on. 363 00:26:24,000 --> 00:26:27,000 It could depend on its mood swings. 364 00:26:27,000 --> 00:26:32,000 Who knows what? This is kind of unstable. 365 00:26:32,000 --> 00:26:34,000 And A in particular is highly unstable. 366 00:26:34,000 --> 00:26:36,000 It is going to be big, that's for sure, 367 00:26:36,000 --> 00:26:40,000 but it could be ten to the six, on a rainy day it might be two 368 00:26:40,000 --> 00:26:43,000 times ten to the six. If it feeling sleepy it may be 369 00:26:43,000 --> 00:26:46,000 point five times ten to the sixth. 370 00:26:46,000 --> 00:26:48,000 It is big but I cannot rely on it. 371 00:26:48,000 --> 00:26:51,000 Let me show you an example. I want to show you this curve 372 00:26:51,000 --> 00:26:54,000 for this MOSFET, apply an input and plotting the 373 00:26:54,000 --> 00:26:56,000 output. What I will do is take a look 374 00:26:56,000 --> 00:27:00,000 at this curve. Then what I am going to do is 375 00:27:00,000 --> 00:27:04,000 use a heat gun to heat the op amp and you are going to see 376 00:27:04,000 --> 00:27:07,000 this vary all over the map. If you still remember last 377 00:27:07,000 --> 00:27:11,000 week, some of you may remember that from some place in a 378 00:27:11,000 --> 00:27:15,000 similar situation where the gm for the MOSFETs you were given 379 00:27:15,000 --> 00:27:18,000 was also dependent on temperature and stuff like that. 380 00:27:18,000 --> 00:27:22,000 It is a very common occurrence. And that is certainly the case 381 00:27:22,000 --> 00:27:24,000 for the MOSFET. 382 00:27:31,000 --> 00:27:34,000 Let's apply input. Let's do this. 383 00:27:34,000 --> 00:27:38,000 This is vIN versus vOUT for the amplifier. 384 00:27:38,000 --> 00:27:44,000 Notice that this is plus 12 volts, this is minus 12 volts. 385 00:27:44,000 --> 00:27:47,000 It is about two volts per division. 386 00:27:47,000 --> 00:27:52,000 This axis here is in microvolts, I believe. 387 00:27:52,000 --> 00:27:57,000 For a very small change, for a few tens of microvolts, 388 00:27:57,000 --> 00:28:03,000 I have an incredibly high gain. Notice that this has an 389 00:28:03,000 --> 00:28:07,000 incredibly high gain here. The gain is the slope of this 390 00:28:07,000 --> 00:28:11,000 line, almost a vertical line. What I am going to do next, 391 00:28:11,000 --> 00:28:14,000 is to have some fun, is I am going to heat the op 392 00:28:14,000 --> 00:28:16,000 amp. To show you that A is kind of 393 00:28:16,000 --> 00:28:20,000 really skittish and also the fact that it doesn't quite hit 394 00:28:20,000 --> 00:28:24,000 zero, it does all kinds of weird things, I am going to heat the 395 00:28:24,000 --> 00:28:27,000 op amp. And then let's take a look at 396 00:28:27,000 --> 00:28:30,000 how that curve fluctuates. 397 00:29:00,000 --> 00:29:04,000 What you saw there was that the op amp began to behave really 398 00:29:04,000 --> 00:29:07,000 weirdly as I heated it. Instead of doing this it 399 00:29:07,000 --> 00:29:11,000 sometimes did this really weirdly, like getting an offset 400 00:29:11,000 --> 00:29:15,000 from the center and so on. And it does a bunch of other 401 00:29:15,000 --> 00:29:18,000 weird things, but we won't go into those 402 00:29:18,000 --> 00:29:21,000 details. It's not relevant for this 403 00:29:21,000 --> 00:29:23,000 course. But the point is that the gain 404 00:29:23,000 --> 00:29:29,000 and the offset at the input are dependent on temperature. 405 00:29:29,000 --> 00:29:33,000 And we look for ways to make it less dependent on temperature. 406 00:29:33,000 --> 00:29:37,000 As the next step, what I would like to do is 407 00:29:37,000 --> 00:29:40,000 build a circuit. This is model equivalent of 408 00:29:40,000 --> 00:29:44,000 your Hello World program. We are going to use the printf 409 00:29:44,000 --> 00:29:47,000 and build a small program on the printf. 410 00:29:47,000 --> 00:29:51,000 You don't have to worry about how printf is implemented, 411 00:29:51,000 --> 00:29:56,000 just that we can build very highly interesting circuits with 412 00:29:56,000 --> 00:30:00,000 this horrendously complicated function based on a simple 413 00:30:00,000 --> 00:30:08,000 abstraction of the device. The circuit that we will build 414 00:30:08,000 --> 00:30:14,000 is called a noninverting amplifier. 415 00:30:20,000 --> 00:30:22,000 From now on, I am not going to show you the 416 00:30:22,000 --> 00:30:25,000 plus/minus VS. I am not going to show the 417 00:30:25,000 --> 00:30:28,000 power port, but it is in there. It's hidden under the 418 00:30:28,000 --> 00:30:31,000 abstraction layer. This is my op amp. 419 00:30:31,000 --> 00:30:35,000 And I am going to build the following circuit. 420 00:30:35,000 --> 00:30:38,000 This is my v plus and this is my v minus. 421 00:30:38,000 --> 00:30:43,000 What I am going to do is for the v plus I shall apply a vIN. 422 00:30:43,000 --> 00:30:47,000 Let me talk a little bit about ground as well. 423 00:30:47,000 --> 00:30:52,000 Ground is commonly taken as the point at which I connect my VS 424 00:30:52,000 --> 00:30:58,000 and minus VS supply. It is kind of at the midpoint. 425 00:30:58,000 --> 00:31:03,000 And if VS and minus VS are very carefully tuned then the output 426 00:31:03,000 --> 00:31:08,000 is also going to be at that same ground reference when the input 427 00:31:08,000 --> 00:31:11,000 is zero. So, the ground is defined as 428 00:31:11,000 --> 00:31:16,000 the point at which I connect my plus/minus VS supplies. 429 00:31:16,000 --> 00:31:20,000 I apply my vIN out here. Then what I am going to do, 430 00:31:20,000 --> 00:31:24,000 here is my output vO. I am going to have a resistive 431 00:31:24,000 --> 00:31:30,000 divider to ground here and label these R1 and R2. 432 00:31:30,000 --> 00:31:36,000 And what I am going to do here is feed this back to the input, 433 00:31:36,000 --> 00:31:40,000 to the v minus input. I am going to sample the 434 00:31:40,000 --> 00:31:44,000 voltage here and feed that into here. 435 00:31:44,000 --> 00:31:49,000 So, this is my abstract model and this is my Hello World 436 00:31:49,000 --> 00:31:53,000 program. What we are going to do is 437 00:31:53,000 --> 00:31:59,000 simply analyze how this little program behaves. 438 00:31:59,000 --> 00:32:00,000 So, my equivalent circuit model. 439 00:32:00,000 --> 00:32:03,000 The way to analyze these is after one or two of these 440 00:32:03,000 --> 00:32:07,000 examples, you will be able to directly analyze this just by 441 00:32:07,000 --> 00:32:09,000 looking at it, by inspection. 442 00:32:09,000 --> 00:32:11,000 But, much as we did for the other pieces, 443 00:32:11,000 --> 00:32:14,000 let me grunge through drawing the equivalent circuit and 444 00:32:14,000 --> 00:32:18,000 grinding through the analysis, and then show you the much 445 00:32:18,000 --> 00:32:20,000 simpler way of doing it. And even here, 446 00:32:20,000 --> 00:32:23,000 even with this grinding analysis, it is going to be 447 00:32:23,000 --> 00:32:26,000 pretty simple in any case. So, I will replace the op amp 448 00:32:26,000 --> 00:32:30,000 with its equivalent circuit model. 449 00:32:30,000 --> 00:32:33,000 Its equivalent circuit was v plus, v minus. 450 00:32:44,000 --> 00:32:49,000 So, that was the equivalent circuit model of the operational 451 00:32:49,000 --> 00:32:53,000 amplifier, just this piece. I draw that for you. 452 00:32:53,000 --> 00:32:59,000 Then what I am going to do is I connect my v in here. 453 00:32:59,000 --> 00:33:02,000 And, remember, I have an R1, 454 00:33:02,000 --> 00:33:09,000 R2 resistive divider here. And this one gets connected to 455 00:33:09,000 --> 00:33:14,000 this terminal there. I also know that i plus is 456 00:33:14,000 --> 00:33:18,000 zero. I also know that i minus is 457 00:33:18,000 --> 00:33:22,000 zero. All I've done is simply 458 00:33:22,000 --> 00:33:30,000 replaced the amplifier with its equivalent circuit. 459 00:33:30,000 --> 00:33:34,000 Let's go ahead and analyze that circuit now. 460 00:33:34,000 --> 00:33:38,000 Let's go ahead and analyze that circuit. 461 00:33:38,000 --> 00:33:42,000 And it's going to be pretty simple, actually. 462 00:33:42,000 --> 00:33:48,000 What I am going to show you is the hard way of doing it. 463 00:33:48,000 --> 00:33:54,000 I will show you a much easier way, but the hard way itself is 464 00:33:54,000 --> 00:33:59,000 pathetically easy. What I want to do is find vO in 465 00:33:59,000 --> 00:34:04,000 terms of vIN. And there will be a bunch of 466 00:34:04,000 --> 00:34:08,000 other factors thrown in, including things like R1 and 467 00:34:08,000 --> 00:34:12,000 R2, A and stuff like that. Let's go and analyze it. 468 00:34:12,000 --> 00:34:16,000 vO, let's look at that circuit. By the way, let me take 30 469 00:34:16,000 --> 00:34:20,000 seconds and make a little speech at this point. 470 00:34:20,000 --> 00:34:24,000 When you see circuits like this, and I saw this happen in 471 00:34:24,000 --> 00:34:27,000 quiz two as well, for some reason, 472 00:34:27,000 --> 00:34:31,000 when you see a new kind of circuit, don't completely go 473 00:34:31,000 --> 00:34:36,000 berserk or freeze or whatever. There is just no reason to. 474 00:34:36,000 --> 00:34:39,000 You know the node method. The node method is the 475 00:34:39,000 --> 00:34:43,000 workhorse of our business. When in doubt apply the node 476 00:34:43,000 --> 00:34:45,000 method. It will simply work. 477 00:34:45,000 --> 00:34:47,000 Don't freeze. Don't think oh, 478 00:34:47,000 --> 00:34:50,000 man, I need to apply a pattern that I know already. 479 00:34:50,000 --> 00:34:52,000 I must have seen this somewhere. 480 00:34:52,000 --> 00:34:56,000 When in doubt boom, apply the node method. 481 00:34:56,000 --> 00:35:00,000 This circuit here, all I have here is one unknown 482 00:35:00,000 --> 00:35:03,000 node voltage. I know the voltage of v plus, 483 00:35:03,000 --> 00:35:06,000 I need to compute the voltage vO. 484 00:35:06,000 --> 00:35:10,000 There are two unknowns, vO is an unknown and the 485 00:35:10,000 --> 00:35:14,000 voltage here at v minus is another unknown. 486 00:35:14,000 --> 00:35:18,000 This is a very simple circuit involving a dependent voltage 487 00:35:18,000 --> 00:35:23,000 controlled voltage source, and you need to find out vO and 488 00:35:23,000 --> 00:35:27,000 v minus using the node method. Just apply it. 489 00:35:27,000 --> 00:35:31,000 It's simple. Don't freeze. 490 00:35:31,000 --> 00:35:36,000 Just look at it and say I can do it and apply the node method. 491 00:35:36,000 --> 00:35:40,000 It will simply work. So, let's do that. 492 00:35:40,000 --> 00:35:45,000 What I can do here is vO is A times v plus minus v minus. 493 00:35:45,000 --> 00:35:50,000 This is actually really simple. And then, if I take v plus 494 00:35:50,000 --> 00:35:55,000 here, I know v plus is simply vIN so I will just make that 495 00:35:55,000 --> 00:36:01,000 substitution right away. So, v plus is simply vIN. 496 00:36:01,000 --> 00:36:10,000 What is v minus? v minus here is vO -- 497 00:36:25,000 --> 00:36:27,000 What is v plus? I'm sorry, v minus. 498 00:36:27,000 --> 00:36:33,000 v minus is simply the voltage that is between R1 and R2. 499 00:36:33,000 --> 00:36:37,000 Notice that no current flows in to the v minus node. 500 00:36:37,000 --> 00:36:42,000 There is no current flowing in. Voltage at v minus is simply 501 00:36:42,000 --> 00:36:46,000 the voltage given by the resistive divider, 502 00:36:46,000 --> 00:36:50,000 which is vO times R2 divided by R1 plus R2. 503 00:36:50,000 --> 00:36:52,000 Stare at that for another second. 504 00:36:52,000 --> 00:36:58,000 The voltage at this node here is simply given by the resistive 505 00:36:58,000 --> 00:37:02,000 divider. Because no current is flowing 506 00:37:02,000 --> 00:37:06,000 in this direction. And no current flows in because 507 00:37:06,000 --> 00:37:10,000 I am telling you there is no current there based on my 508 00:37:10,000 --> 00:37:14,000 abstraction. I am telling you i minus is 509 00:37:14,000 --> 00:37:16,000 zero. That voltage is simply the 510 00:37:16,000 --> 00:37:19,000 voltage at this resistive divider. 511 00:37:19,000 --> 00:37:23,000 And so I can simplify it further and write this as vO. 512 00:37:23,000 --> 00:37:28,000 So I get, there is a one here. And I move this thing over to 513 00:37:28,000 --> 00:37:35,000 this side so I get one plus A times R2 divided by R1 plus R2. 514 00:37:35,000 --> 00:37:42,000 And that is equal to AvIN. And simplifying it some more, 515 00:37:42,000 --> 00:37:51,000 I get vO is AvIN divided by one plus AR2 divided by R1 plus R2. 516 00:37:51,000 --> 00:38:00,000 Notice how simple this is, and this is the hard method. 517 00:38:00,000 --> 00:38:05,000 All I have done is analyze the circuit using the basic circuit 518 00:38:05,000 --> 00:38:09,000 analysis principle that you learned the first week of the 519 00:38:09,000 --> 00:38:12,000 course, and I have the output for you. 520 00:38:12,000 --> 00:38:17,000 I just noted very carefully what the relationships were 521 00:38:17,000 --> 00:38:20,000 between the various elements in the abstraction. 522 00:38:20,000 --> 00:38:25,000 Notice here that I am told that A is extremely large. 523 00:38:25,000 --> 00:38:30,000 A is on the order of ten to the six and so on. 524 00:38:30,000 --> 00:38:36,000 And suppose it is the case that, let me write that down 525 00:38:36,000 --> 00:38:40,000 again. vO is AvIN, one plus AR2, 526 00:38:40,000 --> 00:38:44,000 R2. Suppose R1 and R2 are more or 527 00:38:44,000 --> 00:38:52,000 less comparable and A is ten to the six, it's a huge number, 528 00:38:52,000 --> 00:39:00,000 so this whole number is much, much greater than one. 529 00:39:00,000 --> 00:39:06,000 If it is much huger than one, what I can do is I can then 530 00:39:06,000 --> 00:39:13,000 write this as follows. I can say that this is more or 531 00:39:13,000 --> 00:39:20,000 less equal to AvIN divided by AR2 divided by R1 plus R2. 532 00:39:20,000 --> 00:39:26,000 I am ignoring the one here. As soon as I do that, 533 00:39:26,000 --> 00:39:34,000 notice I can cancel out A and I get vO to be approximately equal 534 00:39:34,000 --> 00:39:40,000 to vIN times R1 plus R2 divided by R2. 535 00:39:40,000 --> 00:39:45,000 Notice now that when the gain is very large the output is a 536 00:39:45,000 --> 00:39:49,000 function of the input multiplied by some number. 537 00:39:49,000 --> 00:39:54,000 The beauty of this thing here is that when A is very large, 538 00:39:54,000 --> 00:39:59,000 or this expression is very large, A cancels out and there 539 00:39:59,000 --> 00:40:06,000 is no A in this relationship. This means that even though the 540 00:40:06,000 --> 00:40:11,000 basic amplifier was very skittish, the output here 541 00:40:11,000 --> 00:40:16,000 relates to the input based on components that I have control 542 00:40:16,000 --> 00:40:20,000 over. These are soldiers in my army. 543 00:40:20,000 --> 00:40:25,000 I control them. So, to give you a sense of some 544 00:40:25,000 --> 00:40:29,000 numbers here, suppose A was ten to the six. 545 00:40:29,000 --> 00:40:35,000 And I choose R1 to be 9R. And R to be some R. 546 00:40:35,000 --> 00:40:44,000 Then vO is ten to the sixth vIN divided by one plus ten to the 547 00:40:44,000 --> 00:40:52,000 six R divided by 9R plus R. So, that is ten to the six vIN 548 00:40:52,000 --> 00:41:01,000 divided by one plus ten to the six divided by ten. 549 00:41:01,000 --> 00:41:05,000 All right. If I ignore the one here, 550 00:41:05,000 --> 00:41:11,000 the ten to the six and ten to the six cancel out, 551 00:41:11,000 --> 00:41:17,000 this ends up giving me 10vIN. So, I get a really nice 552 00:41:17,000 --> 00:41:23,000 amplifier whose output is simply ten times the input and 553 00:41:23,000 --> 00:41:30,000 determined solely by some resistor values. 554 00:41:30,000 --> 00:41:34,000 Let me show you another quick demo this time and show you the 555 00:41:34,000 --> 00:41:37,000 amplifier again, but with resistors connected 556 00:41:37,000 --> 00:41:41,000 like that. And then I show you that I want 557 00:41:41,000 --> 00:41:45,000 to heat the amplifier to the wazoo, the op amp to the wazoo, 558 00:41:45,000 --> 00:41:48,000 but vO is going to be absolutely rock solid. 559 00:41:48,000 --> 00:41:51,000 Let's try that out. 560 00:42:00,000 --> 00:42:03,000 This time around, this is the transfer function, 561 00:42:03,000 --> 00:42:07,000 the vO versus vIN. And notice that this time 562 00:42:07,000 --> 00:42:11,000 around I have similar scales on the X and Y axes, 563 00:42:11,000 --> 00:42:15,000 and this has a slope of 10. This is the point where the 564 00:42:15,000 --> 00:42:20,000 amplifier saturates at plus 12 volts, and this is minus 12 565 00:42:20,000 --> 00:42:23,000 volts, and this point here is a zero. 566 00:42:23,000 --> 00:42:25,000 So, this is vIN, vOUT, plus 12, 567 00:42:25,000 --> 00:42:31,000 minus 12 and this slope is 10. What I am going to do now is 568 00:42:31,000 --> 00:42:36,000 heat the op amp to the wazoo and this ain't going to change 569 00:42:36,000 --> 00:42:40,000 because it's my external resistors that control it 570 00:42:40,000 --> 00:42:45,000 independent of the value of A, provided A continues to be very 571 00:42:45,000 --> 00:42:47,000 large. I am just articulating the 572 00:42:47,000 --> 00:42:51,000 vOUT, vIN curve. And let me start heating the op 573 00:42:51,000 --> 00:42:53,000 amp. 574 00:43:01,000 --> 00:43:06,000 Notice that it's pretty stable. It doesn't change because it is 575 00:43:06,000 --> 00:43:09,000 independent of the amplifier values. 576 00:43:09,000 --> 00:43:14,000 What I have done now is by connecting these resistors in 577 00:43:14,000 --> 00:43:18,000 this way, I have a nice amplifier with a gain of ten. 578 00:43:18,000 --> 00:43:22,000 The question you may ask yourselves is why? 579 00:43:22,000 --> 00:43:27,000 There is this little sucker in there that wants to shoot things 580 00:43:27,000 --> 00:43:32,000 up by ten to the sixth. Wants to knock things off the 581 00:43:32,000 --> 00:43:36,000 one rail or the negative rail. Why is it that it's behaving 582 00:43:36,000 --> 00:43:39,000 like a docile lamb here and giving us a nice little factor 583 00:43:39,000 --> 00:43:41,000 of ten gain no matter what I do to it? 584 00:43:41,000 --> 00:43:44,000 Why is it doing that? What is the intuition behind 585 00:43:44,000 --> 00:43:46,000 it? I will draw something on the 586 00:43:46,000 --> 00:43:50,000 board, but for the next ten seconds I want you think about 587 00:43:50,000 --> 00:43:51,000 it. See if you can come up with 588 00:43:51,000 --> 00:43:54,000 some insight as to why is it doing that. 589 00:43:54,000 --> 00:43:57,000 Why is it exactly ten? Why isn't the ten to the sixth 590 00:43:57,000 --> 00:44:01,000 kind of killing me somehow? Why am I getting exactly ten no 591 00:44:01,000 --> 00:44:04,000 matter what happens? See if you can come up with 592 00:44:04,000 --> 00:44:07,000 some intuition and then I will show you how it works. 593 00:44:07,000 --> 00:44:10,000 I will redraw the circuit in the meantime. 594 00:44:28,000 --> 00:44:30,000 Let me see if I can give you some intuition. 595 00:44:30,000 --> 00:44:34,000 This is my circuit, and let's say this is R and 596 00:44:34,000 --> 00:44:36,000 this is R. As an example, 597 00:44:36,000 --> 00:44:42,000 let's assume that the input is 5 volts, vIN is 5 volts. 598 00:44:42,000 --> 00:44:46,000 If R and R are equal, what should the output be? 599 00:44:46,000 --> 00:44:50,000 It's R and R, so it's R1 plus R2 divided by 600 00:44:50,000 --> 00:44:53,000 R2, right? It's 2R divided by R, 601 00:44:53,000 --> 00:44:59,000 so it has a gain of two. My amplifier has a gain of two 602 00:44:59,000 --> 00:45:03,000 because R1 plus R2 divided by R2, which is my gain, 603 00:45:03,000 --> 00:45:09,000 is R plus R divided by R equals two. 604 00:45:09,000 --> 00:45:13,000 So, this will be 10 volts. If that is 10 volts this is 605 00:45:13,000 --> 00:45:16,000 going to be 5 volts, correct? 606 00:45:16,000 --> 00:45:18,000 This R and R, voltage divider, 607 00:45:18,000 --> 00:45:22,000 this is five, so I get 5 volts here. 608 00:45:22,000 --> 00:45:24,000 This is v plus. This is v minus. 609 00:45:24,000 --> 00:45:27,000 I get R and R, 5 volts here, 610 00:45:27,000 --> 00:45:32,000 that's how the circuit looks. Now let's understand what is 611 00:45:32,000 --> 00:45:34,000 going on. And listen very carefully. 612 00:45:34,000 --> 00:45:37,000 This is going to be a key insight that I hope you will 613 00:45:37,000 --> 00:45:40,000 carry with you for the rest of your lives. 614 00:45:40,000 --> 00:45:41,000 This is really, really key. 615 00:45:41,000 --> 00:45:45,000 What you are going to see is, I think, the third big ah-ha 616 00:45:45,000 --> 00:45:47,000 moment in 6.002. Like small signal analysis, 617 00:45:47,000 --> 00:45:51,000 like the frequency domain stuff we saw, I think this is the 618 00:45:51,000 --> 00:45:54,000 third big one in the next 30 or 40 seconds, things that are 619 00:45:54,000 --> 00:45:57,000 completely either not necessarily intuitive but are 620 00:45:57,000 --> 00:46:02,000 just spectacular in terms of what they can do for you. 621 00:46:02,000 --> 00:46:04,000 Let's see. Let's suppose that because I am 622 00:46:04,000 --> 00:46:08,000 heating it, let's suppose that A suddenly tends to increase. 623 00:46:08,000 --> 00:46:11,000 It wants to increase because I have heated it. 624 00:46:11,000 --> 00:46:15,000 A is saying I want to get out this mold here and starts to 625 00:46:15,000 --> 00:46:19,000 break through its shackles here. Let's say, as a Gedanken 626 00:46:19,000 --> 00:46:22,000 experiment, that it tries to shoot up this to 12 volts. 627 00:46:22,000 --> 00:46:26,000 It tries to push it up higher. This is just a Gedanken 628 00:46:26,000 --> 00:46:30,000 experiment. The up arrow says that the 629 00:46:30,000 --> 00:46:34,000 increase in A is trying to push up vO momentarily. 630 00:46:34,000 --> 00:46:38,000 Let's see what happens. It is trying to push up vO 631 00:46:38,000 --> 00:46:43,000 momentarily, so let's say this goes to 12 hypothetically. 632 00:46:43,000 --> 00:46:47,000 If that goes to 12, what should this volt node go 633 00:46:47,000 --> 00:46:49,000 to? Six, exactly. 634 00:46:49,000 --> 00:46:52,000 This goes to 6 volts. If that goes to six, 635 00:46:52,000 --> 00:46:56,000 what does v minus go to? 6 volts again. 636 00:46:56,000 --> 00:47:02,000 So, v minus goes to 6 volts. Now at the input I have 5 volts 637 00:47:02,000 --> 00:47:06,000 at v plus and 6 volts at v minus, so where should the 638 00:47:06,000 --> 00:47:09,000 output go? The output should go down 639 00:47:09,000 --> 00:47:13,000 because the voltage of the negative terminal is higher. 640 00:47:13,000 --> 00:47:17,000 And so the output is A times v plus minus v minus. 641 00:47:17,000 --> 00:47:22,000 And because this has gone down, this has gone up here it is 642 00:47:22,000 --> 00:47:25,000 going to try to pull the output down. 643 00:47:25,000 --> 00:47:29,000 That is going to pull the output down let's say to 9 volts 644 00:47:29,000 --> 00:47:34,000 or something. Cachunk, there is a big battle 645 00:47:34,000 --> 00:47:35,000 going on here. A has gone up, 646 00:47:35,000 --> 00:47:39,000 it has boosted it up to 12, but the moment that goes to 12, 647 00:47:39,000 --> 00:47:41,000 this goes to 6, this goes to 6, 648 00:47:41,000 --> 00:47:45,000 and the op amp output has to go down to 9 volts now because this 649 00:47:45,000 --> 00:47:48,000 input is higher here. If this goes to 9, 650 00:47:48,000 --> 00:47:51,000 this goes to 4.5. If that goes to 4.5, 651 00:47:51,000 --> 00:47:53,000 this goes to 4.5. What happens now? 652 00:47:53,000 --> 00:47:55,000 If this goes to 4.5, what happens? 653 00:47:55,000 --> 00:48:00,000 It wants to go back up. Can't it make up its mind? 654 00:48:00,000 --> 00:48:04,000 This guy wants to go back up now because v plus is higher 655 00:48:04,000 --> 00:48:07,000 than v minus. What am I seeing here? 656 00:48:07,000 --> 00:48:11,000 This whole circuit here behaves like my little son, 657 00:48:11,000 --> 00:48:14,000 my 9-year-old. If say do this, 658 00:48:14,000 --> 00:48:17,000 he wants to do the exact opposite. 659 00:48:17,000 --> 00:48:21,000 So, there is a trick in how you make them do things for you. 660 00:48:21,000 --> 00:48:25,000 Look at this. Because of this arrangement of 661 00:48:25,000 --> 00:48:29,000 the circuit when A tries to push the output up, 662 00:48:29,000 --> 00:48:34,000 the rest of the circuit tries to pull it back down to where it 663 00:48:34,000 --> 00:48:39,000 used to be. If the circuit tries not to 664 00:48:39,000 --> 00:48:43,000 follow the true path, the rest of the circuit tries 665 00:48:43,000 --> 00:48:48,000 to whack it into shape so it follows a true path. 666 00:48:48,000 --> 00:48:52,000 And what's happening is because, in this arrangement, 667 00:48:52,000 --> 00:48:57,000 I have fed back a portion of the output to the negative 668 00:48:57,000 --> 00:49:01,000 input. I have fed back some of the 669 00:49:01,000 --> 00:49:06,000 output to the negative input. And by providing this feedback 670 00:49:06,000 --> 00:49:09,000 of a portion of the output to the negative input, 671 00:49:09,000 --> 00:49:14,000 I have arranged it in a way that I have something called 672 00:49:14,000 --> 00:49:18,000 negative feedback. What negative feedback does is 673 00:49:18,000 --> 00:49:23,000 that if this wanted to go wild and crazy, the circuit provides 674 00:49:23,000 --> 00:49:27,000 it with some negative feedback like you just saw. 675 00:49:27,000 --> 00:49:32,000 Feedback, a big word. If you take a poll of all the 676 00:49:32,000 --> 00:49:35,000 EECS faculty, I suspect that feedback would 677 00:49:35,000 --> 00:49:39,000 rank at least as the ninth or tenth most important word in the 678 00:49:39,000 --> 00:49:41,000 EECS. If abstract is number one, 679 00:49:41,000 --> 00:49:46,000 I think this would rank like a nine or a ten or something. 680 00:49:46,000 --> 00:49:48,000 So, that's the reason why it worked. 681 00:49:48,000 --> 00:49:53,000 In the last couple of minutes, let me give you some insight, 682 00:49:53,000 --> 00:49:57,000 based on something that you know, on how feedback works. 683 00:49:57,000 --> 00:50:02,000 This is a road here. Let's look at anti lock breaks. 684 00:50:02,000 --> 00:50:05,000 This is my tire. And let's say I have a set of 685 00:50:05,000 --> 00:50:09,000 disk brakes here. As the car is moving forward, 686 00:50:09,000 --> 00:50:13,000 if I apply the brakes the tire stops rolling, 687 00:50:13,000 --> 00:50:18,000 but if I apply the breaks too hard it can lock up the tire and 688 00:50:18,000 --> 00:50:22,000 the whole car can skid. The way anti lock breaks work 689 00:50:22,000 --> 00:50:26,000 is as follows. There is a controller that sits 690 00:50:26,000 --> 00:50:30,000 here. And there is a little person 691 00:50:30,000 --> 00:50:34,000 looking at the wheel and seeing is it turning. 692 00:50:34,000 --> 00:50:39,000 So, this is a feedback. And it is saying is it turning? 693 00:50:39,000 --> 00:50:42,000 Yes. Or, is it not turning? 694 00:50:42,000 --> 00:50:45,000 No. All this person watching the 695 00:50:45,000 --> 00:50:50,000 tire is doing is saying is it turning or is it not turning. 696 00:50:50,000 --> 00:50:54,000 That is it. That is a negative feedback. 697 00:50:54,000 --> 00:50:59,000 And so, if it is no and if it is yes. 698 00:50:59,000 --> 00:51:03,000 If it is yes then what this does is it applies the brakes 699 00:51:03,000 --> 00:51:06,000 even more strongly. It is turning so I can apply 700 00:51:06,000 --> 00:51:08,000 more brakes. But if it says oops, 701 00:51:08,000 --> 00:51:11,000 it stopped turning, what it does is it simply 702 00:51:11,000 --> 00:51:15,000 releases, the controller releases the brakes. 703 00:51:15,000 --> 00:51:18,000 And when the controller releases the brakes this one 704 00:51:18,000 --> 00:51:23,000 tends to loosen up a little bit and the tire starts turning 705 00:51:23,000 --> 00:51:25,000 again. So, this way you are constantly 706 00:51:25,000 --> 00:51:30,000 keeping the tire in its region of critical friction so that it 707 00:51:30,000 --> 00:51:34,000 is constantly moving. And static friction applies to 708 00:51:34,000 --> 00:51:37,000 how hard you can brake and it doesn't start skidding. 709 00:51:37,000 --> 00:51:41,000 In fact, if you take your car out, and I don't say you do 710 00:51:41,000 --> 00:51:42,000 this. Let's say go onto the Charles 711 00:51:42,000 --> 00:51:46,000 River in the dead of winter and you drive on the lake and you 712 00:51:46,000 --> 00:51:49,000 slam your anti lock brakes on, on an icy patch, 713 00:51:49,000 --> 00:51:52,000 you will notice that there is a constant sound that looks like 714 00:51:52,000 --> 00:51:55,000 something is vibrating in there. That is exactly what is 715 00:51:55,000 --> 00:51:57,000 happening. Oops, the tire is locked. 716 00:51:57,000 --> 00:52:01,000 Release the brakes. The wheel is turning. 717 00:52:01,000 --> 00:52:03,000 Jam the brakes on. That is exactly what is 718 00:52:03,000 --> 00:52:05,000 happening. The same way as out there, 719 00:52:05,000 --> 00:52:08,000 you notice that oops, the output is going up, 720 00:52:08,000 --> 00:52:10,000 pull it down, oops, it's going down, 721 00:52:10,000 --> 00:52:12,000 pull it up. So, there is constant negative 722 00:52:12,000 --> 00:52:15,000 feedback that is keeping the output stable. 723 00:52:15,000 --> 00:52:18,000 A very important concept. And I will ask your recitation 724 00:52:18,000 --> 00:52:21,000 instructors to cover the very simple method that is on page 9.