 Hi everyone, welcome to this lesson which will walk you through the derivation of the limit definition of the derivative, or as I like to say, welcome to differential calculus. So central to this derivation are rates of change. And you have probably studied two types of rates of change, average rates of change, and instantaneous rates of change. Remember, our rates of change between two specified points, whereas an instantaneous rate of change is the rate of change at one point. And the instantaneous rates of change you've probably simply been estimating by finding the slope of the tangent line to the curve at the point. And it's probably been your experience with that, that it does not always provide for a really accurate answer. So there has to be a better way to get one, and there is. So we're going to use an applet to facilitate our understanding of where the limit definition of a derivative comes from. So if we take a look at what we have here, we have a blue exponential curve, and we have two lines associated with it. We have a secant line, that's the green line, which passes through this point, which you'll notice I can move along the curve, and also that y-intercept point at 0, 1. Then we also have the red tangent to the curve at that point, 0, 1, the y-intercept. So what we're trying to achieve in the end is a way in which we can determine the slope of that red tangent line. And the way we're going to do it is by talking about average rates of change, which in this case would be the slope of this green secant line, at any point at which we opt to stop this movable point, and the idea of a limit. So let's start by coming up with an expression as to how we get slope. So we all know slope to be change in y over change in x. So what we want to come up with is a general expression for the slope of that secant line. So let's take a look at another diagram, which will allow us to establish some variables we can use to do that. So we have a boldface curve, f of x, and you'll notice on it we have two points, a and b. The line passing through the points a and b is the secant line, and we have the tangent line to the point at a. So we want to establish some variables that we can use to come up with an expression for the slope of the secant line. So let's simply start by referring to the x coordinate of that point a is x, and that makes of course the y value we can express as f of x. Now the point at b, there's obviously some kind of horizontal distance between the point a and the point b, and we need to establish a variable for that. So we're simply going to call that horizontal distance between point a and point b, we're going to call it h. You'll notice that's what most calculus textbooks call it. Some do call it delta x, but for our applications here we're going to simply use h. So if we know the point a has an x coordinate x, and if we go down the x axis a little bit, we arrive at the x coordinate for point b, we can designate that x coordinate for point b as x plus h. So then the y coordinate then can be expressed as f of x plus h. So this should be enough for us to come up then with an expression for the slope of the secant line. So we know in the numerator we need to subtract the y values. So if we start with the y value, that was for that point b minus the y value for the point a, and then we need to subtract their x coordinates. So the numerator you can't do much to. The denominator though, the x's cancel out and we're simply left with h. So now we have that first step, that general expression for the slope of the secant line. So let's go back to our applet. So that green line, if we wanted to find the slope of it, that expression we came up with should give us that slope we want no matter where this point is. So no matter where I put this green point, that expression we found should give us the slope we need. So if I started doing that, if I started moving this green point and everywhere I stopped it, I was going to come up with the slope at that time. So if I had the green point here, I would go ahead and calculate the slope of the green line. If I moved the point a little bit closer to the red point, I'd stop again, calculate a new slope of that green line. And this is where the limit idea comes in because notice what's happening to that green secant line as I move the green point closer to the red point. That green line is tilting towards the red tangent line. So if I move the green point again, a little bit closer, calculate a new slope. And this is where the limiting idea comes in. Every time you stop and calculate the slope of that green line, if we were to take a look at that collection of slopes we have, by the time that green point lies right on top of the red point, we should be able to very closely estimate the slope then of the tangent line. And notice another thing that's happening. As the green point gets closer and closer to the red point, that horizontal distance h that we designated as the distance between those two points, that's getting smaller and smaller. So what we can say then is as the red point remains fixed and we move the green point down towards the red point, the value of h is decreasing, and specifically it's approaching zero, because if eventually that green point were to lie right on top of the red point, right there, h is essentially zero. There is no horizontal distance between the two points because they are lying right on top of each other, they coincide. So taking it a step further then, once that green point does coincide with the red point, essentially the secant line becomes the tangent to the curve. Those two lines are one and the same. And it follows that the slope of the secant line that you've been calculating would approach the slope of the tangent to the curve. So let's try to summarize this using some of the limit notation we've talked about and we know that we're trying to come up with some way to find the slope of the tangent. So let's start with a more geometric kind of take on it. So we're trying to do a limit as that point B approach day. So let's go back to the diagram for a second. On here, if you were to envision this point B sliding down the curve towards that point A, hopefully you can envision how that h value is getting smaller and smaller. And as a result, the slope of that secant line is tilting towards what will eventually be the slope of the tangent line. So the way in which we can express that with the notation is to say the limit as that point B approaches point A and we're taking the limit of all those slopes of those secant lines. So let's make it a little bit more algebraic now. So another way to say this is the limit as h approaches zero because remember as that point B slid down the curve towards A that horizontal distance h between the two of them was decreasing. And remember the expression we had for the slope of the secant line. And that everyone is what we know as the first limit definition of the derivative. And this is where I can welcome you officially to differential calculus. There is a second limit definition, which you will soon learn. This one though is designated as the first limit definition. And as you move on, you'll learn how to work with these two limit definitions. But hopefully at least for now, this has helped your understanding of where the limit definition of a derivative comes from and how limits and average rates of change feed into that.