 So why go through all this trouble of inventing calculus? Historically, calculus was created to solve three problems. First, given a region to find the area of the region. Next, given a function to find the greatest or least values of the function over an interval. And third, given a curve, find a line tangent to the curve at a given point. Now it turns out the first problem is actually the easiest problem and was in fact the first calculus problem solved. But for a variety of reasons, we actually begin by trying to solve the third problem. So let's take a look at that one. Now before we try to find the tangent line, let's take a look at what's called the secant line. A secant line is a line that cuts secare in Latin through two points on a curve. Since we know how to write the equation of a line given two points, we can always write the equation of the secant line. For example, let's consider the curve y equals x squared plus 3x minus 7, and we'll find a secant line through the point on the curve where x is equal to 1. So first, we need two points to write the equation of a line, and x equals 1 is a half point. We need the y value to make it a full point. Well, we have a formula that tells us what our y value is, so we'll find our y value when x is equal to 1, which will turn out to be negative 3, and so our line is going to go through the point x equals 1, y equals negative 3, and we need a second point on the secant line. Now as the problem is stated, we can use any point at all. So we'll take x equals 0 as our second half point, and our y-coordinate will be negative 7, and so the second point on our secant line is going to be 0, negative 7. And now we have two points, and we need to write the equation of the line through these two points. Now the easiest way of writing the equation of a line is to know a point on the line and the slope of the line, in which case the equation of the line through the point x0, y0, and the slope m is y equals m x minus x0 plus y0. This requires us to find the slope, so remember that the slope of the line through two points is given by the difference in the y values divided by the difference in the x values. So we have two points on the line, so we'll find the slope between those two points, and now we have the slope at a point on the line, and we can use either point to write the equation of the line. However, it's conventional to use the point that we're given, so here we're told to find the secant line through the point on the curve where x equals 1, so we'll use the point 1, negative 3, and the slope of 4 to write the equation of this line. So how do we solve this problem of, given a curve, find a line tangent to the curve at a given point? To find the equation of the tangent line to a curve y equals f of x, we're going to need two things. First, we'll need a point a f of a on the curve. This is our point of tangency, and the other thing we'll need is the slope of the tangent line. Once we have these two things, we can write down the equation of the tangent line. So how do we get them? Well, let's go back to our secant line. If I take the second point of the secant line close to the point of tangency, then it appears that the slope of the secant line will approximate the slope of the tangent line. And this suggests the following approach. First, I'll find a second point on the curve that's close to the point of tangency. I'll find the slope of the secant line between those two points, and then I'll find the limit of the slope as the second point approaches the first. And this is where the calculus comes in. So let's say I want to find the equation of the tangent line to y equals x squared plus 2x minus 4 at x equals 3. So first, we should find the point of tangency. At x equals 3, y equals 11, so the point of tangency is 3, 11. We'll let our second point be at x equals b. Then y is equal to b squared plus 2b minus 4, and our second point will be b b squared plus 2b minus 4. And now I have two points, so I can write the formula for the slope between those two points. And as the second point approaches 3, 11, the slope of the secant line will approximate the slope of the tangent line. And so the slope of the tangent line will be the limit as b approaches 3 of this expression. And to find the limit, we note that at b equals 3, numerator and denominator are both equal to 0, so both of them will have a factor of b minus 3. We can find the other factor easily, and then simplifying our expression, we find the limit, which will be 8. And so we know the slope of the tangent line, 8. We know the point of tangency, 3, 11, and so we can write down our equation. Now the primary difficulty with finding the slope of the tangent line this way is that evaluating this limit requires us to factor an expression that can become fairly complicated. So to simplify the algebra, we can let our two points be a f of a, the actual point of tangency, and some point that's close by. And one way we can express a point that's close by is to let our x value be a and a little bit more. It'll be at a plus h, and our y value will be f of a plus h, and that'll be our second point on the curve. Then the slope of the secant line will be, and as the second point gets closer to the point of tangency, the slope of the secant line becomes closer to the slope of the tangent line. And so the limit of the slope of the secant line will be the slope of the tangent line. And we might ask ourselves, self, where have we seen this limit before? And in fact, this is the very limit that defines the derivative. And so this leads to an important connection between algebra and geometry. The derivative is an algebraic expression. It's a formula. Meanwhile, slope is a geometric idea, and the important connection to remember is that the derivative is the slope of the line tangent to the curve. If you learn nothing else in a calculus course, you'll probably fail the course. But among the things you should learn in a calculus course is this key concept, the derivative is the slope of the line tangent to the curve.