Main content

### Course: AP®︎/College Calculus AB > Unit 2

Lesson 2: Defining the derivative of a function and using derivative notation- Formal definition of the derivative as a limit
- Formal and alternate form of the derivative
- Worked example: Derivative as a limit
- Worked example: Derivative from limit expression
- Derivative as a limit
- The derivative of x² at x=3 using the formal definition
- The derivative of x² at any point using the formal definition
- Finding tangent line equations using the formal definition of a limit

© 2024 Khan AcademyTerms of usePrivacy PolicyCookie Notice

# Formal definition of the derivative as a limit

Discover how to define the derivative of a function at a specific point using the limit of the slope of the secant line. We'll explore the concept of finding the slope as the difference in function values approaches zero, represented by the limit of [f(c)-f(c+h)]/h as h→0. Created by Sal Khan.

## Want to join the conversation?

- I know this concept is important in math, but how is it useful?(79 votes)
- First of all, there are numerous applications.

For example, you could find the rate at which a chemical reaction is happening.

You could maximize the profit made by a company, given functions for demand and price.

Many topics covered in Algebra can become even broader and more specific.

While creating graphs, you can find the maximums and minimums of the function and where the function will increase or decrease and by what rate.

Secondly,

in calculus, the concept of derivatives will be used with the concept of integrals (anti-derivatives).

Integrals also have numerous applications, such as finding the volumes and surface areas of solids.

I cannot cover all of the applications and uses of derivatives in this one answer box, but calculus can be and is applied everywhere you look.

Trust me.(264 votes)

- This almost sounds ridiculous asking this in the calculus playlist, but why is Sal subtracting the point of lesser value from the point of greater value i.e.: [f(x0 +h)-f(x)] why that order? I realize he is applying the slope formula from Algebra, but I've forgotten (if that makes any sense) why we would subtract the points in that order. Well, thanks to anyone who answers this silly and rather minor question XD.(49 votes)
- (x₁ - x₂)/(y₁ - y₂)

= (-1(-x₁ + x₂))/(-1(-y₁ + y₂))

= (x₂ - x₁)/(y₂ - y₁)

So it doesn't matter what order you use :)

Don't feel bad about asking questions, ever!(172 votes)

- At9:37Sal said "secant line" he also referred to a tangent line, Do these lines have anything to do with the trig functions tangent and secant?(35 votes)
- It would be clearer to say that both of those uses go back to the definition of tangents and secants in circles. That is, a tangent is a line that meets a circle in exactly one point and a secant is a line that intersects a circle in two points, just like it is for an arbitrary curve in calculus.

Here's a quickie program I drew up that illustrates why two of the trig functions got named after the tangent and secant lines of a circle. Hope you enjoy it!

http://www.khanacademy.org/cs/why-is-it-called-tangent-and-secant/1269121217(93 votes)

- Why did he use a secant line? When do you use secant versus tangent lines?(14 votes)
- I can answer your second question, secant lines are used when you are given 2 points on a curve and you just find the slope. This slope of those points is average slope of the curve aka mSec. The tangent line is used when you only have one point to get the tangent slope of the curve.(39 votes)

- So, does that mean a curve is made up of tangent lines that are infinitly close to each other?(21 votes)
- Infinitely close and have zero length, ie. a point.(19 votes)

- At14:40he takes the limit as h approaches 0. Why doesn't he take the limit as h approaches x(14 votes)
- h is the step size. You want it approaching 0 so that x and x+h are very close.

There is an alternate (equivalent) definition of the derivative that does have the variable approaching a (nonzero) number.(18 votes)

- At13:10, when you take the limit of this function, are you trying to find the slope of the tangent line? Is that why h yields to zero?(6 votes)
- Yeah, that's one of the definitions of the derivative, the slope of the tangent line.(17 votes)

- Okay I understand the video but I just tried some of the practice problems and I don't understand how I'm supposed to find the derivative of this f(x)=6x4−7x3+7x2+3x−4 using that formula he gave us.(9 votes)
- Why to indicate a derivative is used the notation d/dx ?

And can this notation be considered as a ratio of "d" over "dx" , or is just a symbol?(8 votes)- It is a symbol, though there are good reasons that you will learn about later for depicting it is a fraction. But it is not a ratio in the sense you mentioned.

For the moment, though, you should regard d/dx as being a symbol that means "the derivative with respect to x of the following function".(10 votes)

- How would you use this to find the perpendicular tangent line to a function?(6 votes)
- A normal line would more approximate a perpendicular relationship to the function, while the tangent line would more approximate a parallel relationship to the function.

Technically neither tangent or normal are truly parallel or perpendicular to the function. Suppose a function where its curve is approaching a strait line. The tangent line will start to look co-linear with the curve, or parallel with an offset of 0. However, by the strict definition of parallel lines:

*Parallel lines are lines in a plane which do not meet.*

So parallel can't really be applied to the tangent line.(6 votes)

## Video transcript

We're first exposed to the idea
of a slope of a line early on in our algebra careers, but I
figure it never hurts to review it a bit. So let me draw some axes. That is my y-axis. Maybe I should call
it my f of x-axis. y is equal to f of x. Let me draw my x-axis, just
like that, that is my x-axis. And let me draw a line, let
me draw a line like this. And what we want to do is
remind ourselves, how do we find the slope of that line? And what we do is, we take
two points on the line, so let's say we take
this point, right here. Let's say that that is the
point x is equal to a. And then what would this be? This would be the point f of
a, where the function is going to be some line. We could write f of x is going
to be equal to mx plus b. We don't know what m and
b are, but this is all a little bit of review. So this is a. And then the y-value is what
happens to the function when you evaluated it at a, so
that's that point right there. And then we could take
another point on this line. Let's say we take
point b, right there. And then this coordinate
up here is going to be the point b, f of b. Right? Because this is just the
point when you evaluate the function at b. You put b in here, you're going
to get that point right there. So let me just draw a
little line right there. So that is f of b, right there. Actually, let me make it clear
that this coordinate right is the point a, f of a. So how do we find the slope
between these 2 points, or more generally, of this entire line? Because whole the slope
is consistent the whole way through it. And we know that once we
find the slope, that's actually going to be
the value of this m. That's all a review of your
algebra, but how do we do it? Well, a couple of ways
to think about it. Slope is equal to
rise over run. You might have seen that when
you first learned algebra. Or another way of writing
it, it's change in y over change in x. So let's figure out what the
change in why over the change in x is for this
particular case. So the change in y
is equal to what? Well, let's just take, you can
take this guy as being the first point, or that guy
as being the first point. But since this guy has a
larger x and a larger y, let's start with him. The change in y between that
guy and that guy is this distance, right here. So let me draw a
little triangle. That distance right
there is a change in y. Or I could just transfer
it to the y-axis. This is the change in y. That is your change
in y, that distance. So what is that distance? It's f of b minus f of a. So it equals f of
b minus f of a. That is your change in y. Now what is your change
in x The slope is change in y over change in x. So what our change in x? What's this distance? Remember, we're taking this
to be the first point, so we took its y minus
the other point's y. So to be consistent, we're
going to have to take this point x minus this point x. So this point's
x-coordinate is b. So it's going to be b minus a. And just like that, if you knew
the equation of this line, or if you had the coordinates of
these 2 points, you would just plug them in right here and
you would get your slope. That straightforward. And that comes straight out
of your Algebra 1 class. And let me just, just to make
sure it's concrete for you, if this was the point 2, 3, and
let's say that this, up here, was the point 5, 7, then if we
wanted to find the slope of this line, we would do 7 minus
3, that would be our change in y, this would be 7 and this
would be 3, and then we do that over 5 minus 2. Because this would be a 5, and
this would be a 2, and so this would be your change in x. 5 minus 2. So 7 minus 3 is 4, and 5
minus 2 is 3. so your slope would be 4/3. Now let's see if we
can generalize this. And this is what the new
concept that we're going to be learning as we
delve into calculus. Let's see if we can generalize
this somehow to a curve. So let's say I have a curve. We have to have a curve
before we can generalize it to a curve. Let me scroll down a little. Well, actually, I want to
leave this up here, show you the similarity. Let's say I have, I'll keep
it pretty general right now. Let's say I have a curve. I'll make it a
familiar-looking curve. Let's say it's the curve y is
equal to x squared, which looks something like that. And I want to find the slope. Let's say I want to find
the slope at some point. And actually, before even
talking about it, let's even think about what it means to
find the slope of a curve. Here, the slope was the same
the whole time, right? But on a curve your
slope is changing. And just to get an intuition
for that means, is, what's the slope over here? Your slope over here is the
slope of the tangent line. The line just
barely touches it. That's the slope over there. It's a negative slope. Then over here, your slope is
still negative, but it's a little bit less negative. It goes like that. I don't know if I did
that, drew that. Let me do it in a
different color. Let me do it in purple. So over here, your slope is
slightly less negative. It's a slightly less
downward-sloping line. And then when you go over here,
at the 0 point, right here, your slope is pretty much flat,
because the horizontal line, y equals 0, is tangent
to this curve. And then as you go to more
positive x's, then your slope starts increasing. I'm trying to draw
a tangent line. And here it's increasing even
more, it's increased even more. So your slope is changing the
entire time, and this is kind of the big change that happens
when you go from a line to a curve. A line, your slope is the
same the entire time. You could take any two points
of a line, take the change in y over the change in x, and you
get the slope for the entire line. But as you can see already,
it's going to be a little bit more nuanced when
we do it for a curve. Because it depends what
point we're talking about. We can't just say, what is
the slope for this curve? The slope is different at
every point along the curve. It changes. If we go up here, it's
going to be even steeper. It's going to look
something like that. So let's try a bit
of an experiment. And I know how this experiment
turns out, so it won't be too much of a risk. Let me draw better than that. So that is my y-axis,
and that's my x-axis. Let's call this, we can call
this y, or we can call this the f of x axis. Either way. And let me draw my curve again. And I'll just draw it in the
positive coordinate, like that. That's my curve. And what if I want to find
the slope right there? What can I do? Well, based on our definition
of a slope, we need 2 points to find a slope, right? Here, I don't know how to
find the slope with 1 point. So let's just call this
point right here, that's going to be x. We're going to be general. This is going to
be our point x. But to find our slope,
according to our traditional algebra 1 definition of a
slope, we need 2 points. So let's get another
point in here. Let's just take a slightly
larger version of this x. So let's say, we want to take,
actually, let's do it even further out, just because it's
going to get messy otherwise. So let's say we have
this point right here. And the difference, it's
just h bigger than x. Or actually, instead of saying
h bigger, let's just, well let me just say h bigger. So this is x plus h. That's what that point
is right there. So what going to be their
corresponding y-coordinates on the curve? Well, this is the curve
of y is equal to f of x. So this point right here
is going to be f of our particular x right here. And maybe to show you that I'm
taking a particular x, maybe I'll do a little 0 here. This is x naught, this
is x naught plus h. This is f of x naught. And then what is this going
to be up here, this point up here, that point up here? Its y-coordinate is going to be
f of f of this x-coordinate, which I shifted
over a little bit. It's right there. f of this
x-coordinate, which is f of x naught plus h. That's its y-coordinate. So what is a slope going to be
between these two points that are relatively close
to each other? Remember, this isn't
going to be the slope just at this point. This is the slope of the line
between these two points. And if I were to actually draw
it out, it would actually be a secant line between,
to the curve. So it would intersect the curve
twice, once at this point, once at this point. You can't see it. If I blew it up a little
bit, it would look something like this. This is our coordinate x naught
f of x naught, and up here is our coordinate for this
point, which would be, the x-coordinate would be x naught
plus h, and the y-coordinate would be f of x naught plus h. Just whatever this function is,
we're evaluating it at this x-coordinate That's all it is. So these are the 2 points. So maybe a good start is to
just say, hey, what is the slope of this secant line? And just like we did in the
previous example, you find the change in y, and you divide
that by your change in x. Let me draw it here. Your change in y would be that
right here, change in y, and then your change in x would
be that right there. So what is the slope going
to be of the secant line? The slope is going to be equal
to, let's start with this point up here, just because
it seems to be larger. So we want a change in y. so
this value right here, this y-value, is f of
x naught plus h. I just evaluated
this guy up here. Looks like a fancy term,
but all it means is, look. The slightly larger x
evaluate its y-coordinate. Where the curve is
at that value of x. So that is going to be, so the
change in y is going to be a f of x naught plus h. That's just the
y-coordinate up here. Minus this y-coordinate
over here. So minus f of x naught. So that equals our change in y. And you want to divide
that by your change in x. So what is this? This is the larger x-value. We started with this
coordinate, so we start with its x-coordinate. So it's x naught plus
h, x naught plus h. Minus this x-coordinate. Well, we just picked
a general number. It's x naught. So that is over
your change in x. Just like that. So this is the slope
of the secant line. We still haven't answered what
the slope is right at that point, but maybe this
will help us get there. If we simplify this, so let
me write it down like this. The slope of the secant, let
me write that properly. The slope of the secant line is
equal to the value of the function at this point, f of x
naught plus h, minus the value of the function here,
mine f of x naught. So that just tells
us the change in y. It's the exact same definition
of slope we've always used. Over the change in x. And we can simplify this. We have x naught plus
h minus x naught. So x naught minus x naught
cancel out, so you have that over h. So this is equal to our change
in y over change in x. Fair enough. But I started off saying, I
want to find the slope of the line at that point, at
this point, right here. This is the zoomed-out
version of it. So what can I do? Well, I defined second point
here as just the first point plus some h. And we have something in our
toolkit called a limit. This h is just a
general number. It could be 10, it could be 2,
it could be 0.02, it could be 1 times 10 to the negative 100. It could be an arbitrarily
small number. So what happens, what would
happen, at least theoretically, if I were take the limit
as h approaches 0? So, you know, first, maybe h is
this fairly large number over here, and then if I take h a
little bit smaller, then I'd be finding the slope of
this secant line. If I took h to be even a little
bit smaller, I'd be finding the slope of that secant line. If h is a little bit
smaller, I'd be finding the slope of that line. So as h approaches 0, I'll be
getting closer and closer to finding the slope of the line
right at my point in question. Obviously, if h is a large
number, my secant line is going to be way off from the slope at
exactly that point right there. But if h is 0.0000001, if it's
an infinitesimally small number, then I'm going
to get pretty close. So what happens if I
take the limit as h approaches zero of this? So the limit as h approaches
0 of my secant slope. Of, let me switch to green. f of x naught plus h minus f of
x naught, that was my change in y, over h, which is
my change in x. And now just to clarify
something, and sometimes you'll see it in different calculus
books, sometimes instead of an h, they'll write
a delta x here. Where this second point would
have been defined as x naught plus delta x, and then, this
would have simplified to just delta x over there, and we'd
be taking the limit as delta x approaches 0. The exact same thing. h, delta x, doesn't matter. We're taking h as the
difference between one x point and then the higher x point,
and then we're just going to take the limit as that
approaches zero. We could have called that
delta x just as easily. But I'm going to call this
thing, which equals the slope of the tangent line, and it
does equal the slope of the tangent line, I'm going to call
this the derivative of f. Let me write that down. And I'm going to say that this
is equal to f prime of x. And this is going to
be another function. Because remember, the slope
changes at every x-value. No matter what x-value
you pick, the slope is going to be different. Doesn't have to be, but the
way I drew this curve, it is different. It can be different. So now, you give me an x-value
in here, I'll apply this formula over here, and
then I can tell you the slope at that point. And it all seems very
confusing and maybe abstract at this point. In the next video, I'll
actually do an example of calculating a slope, and
it'll make it everything a little bit more concrete.