1 00:00:00,000 --> 00:00:00,000 2 00:00:00,000 --> 00:00:07,420 PROFESSOR: Hi. 3 00:00:07,420 --> 00:00:08,970 Welcome back to recitation. 4 00:00:08,970 --> 00:00:12,680 I have here a little bit of a strange problem for you. 5 00:00:12,680 --> 00:00:16,040 So let me just tell it to you, and then I'll give you some 6 00:00:16,040 --> 00:00:16,640 time to work on it. 7 00:00:16,640 --> 00:00:19,540 So I want to define a function, g of x, and I want 8 00:00:19,540 --> 00:00:21,390 to define it piecewise. 9 00:00:21,390 --> 00:00:26,020 So when x is positive, I just want g of x to be 1 over x. 10 00:00:26,020 --> 00:00:31,320 But when x is negative, I want g of x to be 1 of x plus 2. 11 00:00:31,320 --> 00:00:33,510 So I've got a little graph here of the function. 12 00:00:33,510 --> 00:00:36,120 So you've got, you know, when x is positive, it's just your 13 00:00:36,120 --> 00:00:37,800 usual, y equals 1 over x. 14 00:00:37,800 --> 00:00:40,230 But when x is negative, I've taken, I've 15 00:00:40,230 --> 00:00:41,170 shifted it up by 2. 16 00:00:41,170 --> 00:00:42,510 So this is a perfectly good function. 17 00:00:42,510 --> 00:00:43,627 It's not defined as 0. 18 00:00:43,627 --> 00:00:45,130 OK? 19 00:00:45,130 --> 00:00:48,090 So what I would like you to do is to compute the derivative 20 00:00:48,090 --> 00:00:50,550 of this function, wherever it's defined. 21 00:00:50,550 --> 00:00:54,331 And you'll notice when you get there that you'll have some, 22 00:00:54,331 --> 00:00:58,440 you'll get some answer, and maybe you'll notice something 23 00:00:58,440 --> 00:01:00,730 a little weird about that answer. 24 00:01:00,730 --> 00:01:03,130 So if you notice something weird about it, what I want 25 00:01:03,130 --> 00:01:05,710 you to do is try and explain why this is true. 26 00:01:05,710 --> 00:01:07,340 And if you don't notice something weird, then, you 27 00:01:07,340 --> 00:01:11,000 know, come back and we'll talk about it together. 28 00:01:11,000 --> 00:01:14,350 So why don't you pause the video, go do that computation, 29 00:01:14,350 --> 00:01:16,950 and think about what, if there's something strange 30 00:01:16,950 --> 00:01:18,370 going on here. 31 00:01:18,370 --> 00:01:20,453 And then come back and we can talk about it together. 32 00:01:20,453 --> 00:01:28,510 33 00:01:28,510 --> 00:01:29,180 Welcome back. 34 00:01:29,180 --> 00:01:31,460 Hopefully you had some fun working on this problem and 35 00:01:31,460 --> 00:01:32,200 thinking about it. 36 00:01:32,200 --> 00:01:34,480 So let's do the first part, which is just the 37 00:01:34,480 --> 00:01:36,020 computational part. 38 00:01:36,020 --> 00:01:39,120 Let's have a go at it. 39 00:01:39,120 --> 00:01:41,170 So, because this function is defined piecewise, when we 40 00:01:41,170 --> 00:01:43,950 compute a derivative, we can just compute the derivative on 41 00:01:43,950 --> 00:01:44,630 the different pieces. 42 00:01:44,630 --> 00:01:47,740 So the function isn't defined at 0, so of course, it doesn't 43 00:01:47,740 --> 00:01:48,628 have a derivative at 0. 44 00:01:48,628 --> 00:01:51,600 And so, but then we can compute a derivative when x is 45 00:01:51,600 --> 00:01:54,580 positive, and we can compute a derivative when x is negative. 46 00:01:54,580 --> 00:01:57,320 47 00:01:57,320 --> 00:02:05,630 So when x is bigger than 0, g prime of x, well, that's just 48 00:02:05,630 --> 00:02:10,020 d over dx of 1 over x. 49 00:02:10,020 --> 00:02:11,730 So that's something we're familiar with. 50 00:02:11,730 --> 00:02:14,355 Its minus 1 over x squared. 51 00:02:14,355 --> 00:02:15,875 So that's for x positive. 52 00:02:15,875 --> 00:02:19,870 53 00:02:19,870 --> 00:02:29,140 When x is less than 0, g prime of x is d over dx of 1 over x 54 00:02:29,140 --> 00:02:32,760 plus 2, because that's what g of x is. 55 00:02:32,760 --> 00:02:35,690 And, OK, and so this is, well, the plus 2 gets killed, and so 56 00:02:35,690 --> 00:02:37,910 then we have the derivative of 1 over x. 57 00:02:37,910 --> 00:02:41,350 That's minus 1 over x squared. 58 00:02:41,350 --> 00:02:44,100 So one thing you've noticed is that this is minus 1 over x 59 00:02:44,100 --> 00:02:46,120 squared here, and it's minus 1 over x squared here. 60 00:02:46,120 --> 00:02:48,960 So although we defined this piecewise, we could, we can 61 00:02:48,960 --> 00:02:55,950 summarize this by saying so the derivative is minus 1 over 62 00:02:55,950 --> 00:03:02,850 x squared always, so for all x0 equals-- you know, it 63 00:03:02,850 --> 00:03:04,430 doesn't have a derivative at x equals 0. 64 00:03:04,430 --> 00:03:07,360 It's not defined at 0, it can't have a derivative there. 65 00:03:07,360 --> 00:03:11,720 So, but we don't need the piecewise definition, anymore. 66 00:03:11,720 --> 00:03:14,780 So that was kind of interesting that we can 67 00:03:14,780 --> 00:03:18,320 summarize the derivative of this piecewise function in a 68 00:03:18,320 --> 00:03:19,685 non-piecewise way. 69 00:03:19,685 --> 00:03:24,610 70 00:03:24,610 --> 00:03:27,980 Now, the thing is, we've learned what the 71 00:03:27,980 --> 00:03:30,240 anti-derivative of this function is. 72 00:03:30,240 --> 00:03:40,820 So we know that the anti-derivative of minus 1 73 00:03:40,820 --> 00:03:48,290 over x squared dx is 1 over x plus a constant. 74 00:03:48,290 --> 00:03:51,710 So we know that the functions whose derivative is minus 1 75 00:03:51,710 --> 00:03:53,670 over x squared are of the form, 1 76 00:03:53,670 --> 00:03:55,740 over x plus a constant. 77 00:03:55,740 --> 00:03:59,480 The thing is, this function g that we just talked about, 78 00:03:59,480 --> 00:04:01,125 this function g isn't of that form. 79 00:04:01,125 --> 00:04:02,020 Right? 80 00:04:02,020 --> 00:04:06,080 You don't get this function by taking the function 1 over x 81 00:04:06,080 --> 00:04:07,880 and just shifting it up or down. 82 00:04:07,880 --> 00:04:09,825 You, something weird happens. 83 00:04:09,825 --> 00:04:12,110 You've shifted it up on one piece and not 84 00:04:12,110 --> 00:04:12,970 on the other piece. 85 00:04:12,970 --> 00:04:17,220 And yet, it's still true that the derivative of g is equal 86 00:04:17,220 --> 00:04:19,170 to minus 1 over x squared. 87 00:04:19,170 --> 00:04:21,749 So this is a little bit of a head scratcher. 88 00:04:21,749 --> 00:04:25,450 And I wanted to talk about why this happens. 89 00:04:25,450 --> 00:04:27,680 And the thing is that there's a sort of theoretical reason 90 00:04:27,680 --> 00:04:30,390 for this, which is that you remember that the reason that 91 00:04:30,390 --> 00:04:34,750 we know that anti-derivatives have this form, a function 92 00:04:34,750 --> 00:04:38,500 plus a constant, is because we know that constants are the 93 00:04:38,500 --> 00:04:40,640 functions with derivative 0. 94 00:04:40,640 --> 00:04:44,900 And so we were able to apply the mean value theorem in 95 00:04:44,900 --> 00:04:48,690 order to show that if two functions have the same 96 00:04:48,690 --> 00:04:52,030 derivative, then they differ by each other, differ from 97 00:04:52,030 --> 00:04:53,500 each other by a constant. 98 00:04:53,500 --> 00:04:55,560 If two functions have the same derivative, 99 00:04:55,560 --> 00:04:57,870 they differ by a constant. 100 00:04:57,870 --> 00:05:01,870 And we used, as a really crucial step in that proof, 101 00:05:01,870 --> 00:05:03,830 the mean value theorem. 102 00:05:03,830 --> 00:05:06,170 Now the thing is, the main value theorem has, as one of 103 00:05:06,170 --> 00:05:09,880 its assumptions, as one of its hypotheses, that the functions 104 00:05:09,880 --> 00:05:12,840 that you're working with are continuous and differentiable 105 00:05:12,840 --> 00:05:13,377 in some interval. 106 00:05:13,377 --> 00:05:15,620 OK? 107 00:05:15,620 --> 00:05:18,830 So what's happened here is that the functions that we're 108 00:05:18,830 --> 00:05:23,090 talking about, the function 1 over x and the function minus 109 00:05:23,090 --> 00:05:26,250 1 over x squared, those functions are continuous and 110 00:05:26,250 --> 00:05:28,160 differentiable on certain intervals. 111 00:05:28,160 --> 00:05:31,280 So if we look, if we go back to this picture here we see 112 00:05:31,280 --> 00:05:35,620 that this function g of x, just like the function 1 over 113 00:05:35,620 --> 00:05:39,570 x, it's continuous and differentiable for positive x, 114 00:05:39,570 --> 00:05:42,040 it's continuous and differentiable for negative x, 115 00:05:42,040 --> 00:05:44,960 but at 0, there's a discontinuity. 116 00:05:44,960 --> 00:05:48,360 So there's no interval that crosses 0 on which this 117 00:05:48,360 --> 00:05:51,260 function is continuous or differentiable. 118 00:05:51,260 --> 00:05:55,070 As a result, the mean value theorem can't tell us anything 119 00:05:55,070 --> 00:05:58,080 about intervals that cross 0. 120 00:05:58,080 --> 00:06:00,850 So if the mean value theorem doesn't tell us anything in 121 00:06:00,850 --> 00:06:03,620 that case, it means the conclusion isn't true and we 122 00:06:03,620 --> 00:06:05,200 get a situation-- 123 00:06:05,200 --> 00:06:05,710 sorry. 124 00:06:05,710 --> 00:06:07,070 I should rephrase that. 125 00:06:07,070 --> 00:06:10,120 It means the conclusion doesn't have to be true. 126 00:06:10,120 --> 00:06:13,210 Our proof doesn't work in a case where we have a 127 00:06:13,210 --> 00:06:15,150 discontinuity. 128 00:06:15,150 --> 00:06:18,360 And what happens, in fact, is right what we have here, which 129 00:06:18,360 --> 00:06:21,210 is that when you have a function that has a 130 00:06:21,210 --> 00:06:25,090 discontinuity and you look at its anti-derivatives, what you 131 00:06:25,090 --> 00:06:28,410 can do is that, in addition to shifting the whole thing up 132 00:06:28,410 --> 00:06:31,870 and down, you can shift the pieces on either side of the 133 00:06:31,870 --> 00:06:33,660 discontinuity separately. 134 00:06:33,660 --> 00:06:37,460 Just like in this case we can shift the piece to the left of 135 00:06:37,460 --> 00:06:39,960 0 separately from the piece to the right of 0 and get a 136 00:06:39,960 --> 00:06:42,690 function whose derivative is still what we started with. 137 00:06:42,690 --> 00:06:47,130 So this function, g of x we, get by shifting part of 1 over 138 00:06:47,130 --> 00:06:49,730 x up, and it gives us a function whose derivative is 139 00:06:49,730 --> 00:06:53,020 still minus 1 over x squared. 140 00:06:53,020 --> 00:06:55,650 So this is true anytime you have a function with a 141 00:06:55,650 --> 00:06:55,735 discontinuity. 142 00:06:55,735 --> 00:06:58,590 So one consequence of this-- 143 00:06:58,590 --> 00:07:00,910 I'm going to go back over here and just write down one 144 00:07:00,910 --> 00:07:02,790 special case of this-- 145 00:07:02,790 --> 00:07:11,540 is that to say, we say that the anti-derivative of 1 over 146 00:07:11,540 --> 00:07:19,010 x dx is equal to ln of the absolute value of x plus c. 147 00:07:19,010 --> 00:07:24,840 What this really means is that when x is positive, we have a 148 00:07:24,840 --> 00:07:27,700 single kind of anti-derivative, and they're 149 00:07:27,700 --> 00:07:30,470 of the form, ln x plus a constant. 150 00:07:30,470 --> 00:07:33,115 And when x is negative, we have a single anti-derivative, 151 00:07:33,115 --> 00:07:37,370 that's, or single family of anti-derivatives, of the form 152 00:07:37,370 --> 00:07:40,630 ln of minus x-- remember, absolutely value of x is minus 153 00:07:40,630 --> 00:07:41,770 x when x is negative-- 154 00:07:41,770 --> 00:07:42,740 plus c. 155 00:07:42,740 --> 00:07:45,040 But if we consider x to be positive and negative at the 156 00:07:45,040 --> 00:07:47,330 same time, the two constants don't 157 00:07:47,330 --> 00:07:48,670 necessarily have to agree. 158 00:07:48,670 --> 00:07:50,770 You can have the same situation that you had before 159 00:07:50,770 --> 00:07:53,960 where one side can shift up and down independently of the 160 00:07:53,960 --> 00:07:57,490 other because there's that discontinuity at 0 there. 161 00:07:57,490 --> 00:07:59,710 So this is just something to keep in mind. 162 00:07:59,710 --> 00:08:01,980 It also means you have to be careful with certain 163 00:08:01,980 --> 00:08:02,820 substitutions. 164 00:08:02,820 --> 00:08:04,970 You don't want to do substitutions that have 165 00:08:04,970 --> 00:08:06,290 discontinuities. 166 00:08:06,290 --> 00:08:08,880 If you do substitutions that have discontinuities, you 167 00:08:08,880 --> 00:08:13,030 might accidentally introduce a discontinuity and bad things 168 00:08:13,030 --> 00:08:16,020 can happen that I won't go into now. 169 00:08:16,020 --> 00:08:19,100 You can make, end up with statements that don't make any 170 00:08:19,100 --> 00:08:23,020 sense by making a substitution where the function that you're 171 00:08:23,020 --> 00:08:25,920 substituting has a discontinuity in it. 172 00:08:25,920 --> 00:08:27,720 So you, or another way of saying it is you have to 173 00:08:27,720 --> 00:08:33,630 restrict to some interval on which it really is continuous. 174 00:08:33,630 --> 00:08:36,370 And then on each of those intervals it makes sense, but 175 00:08:36,370 --> 00:08:38,170 bad things could happen when you cross those 176 00:08:38,170 --> 00:08:39,850 discontinuities. 177 00:08:39,850 --> 00:08:42,130 So this is a little bit theoretical, but I think it's 178 00:08:42,130 --> 00:08:45,370 a nice thing to be aware of, a nice thing to keep in mind 179 00:08:45,370 --> 00:08:49,460 when you're working with some of these expressions. 180 00:08:49,460 --> 00:08:51,270 So I'll end there. 181 00:08:51,270 --> 00:08:51,464