Achievable logoAchievable logo
AP Calculus AB
Sign in
Sign up
Purchase
Textbook
Practice exams
Support
How it works
Exam catalog
Mountain with a flag at the peak
Textbook
Introduction
1. Limits
2. Derivative basics
2.1 The derivative
2.2 Tangent lines & slopes
2.3 Power rule
2.4 Product & quotient rules
2.5 Special derivatives
2.6 Differentiability & continuity
3. Advanced differentiation
4. Contextual uses
5. Analytical uses
6. Integration
7. Differential equations
8. Applications of integrals
Wrapping up
Achievable logoAchievable logo
2.2 Tangent lines & slopes
Achievable AP Calculus AB
2. Derivative basics
Our AP Calculus AB course is now in "early access" - get 50% off for a limited time.

Tangent lines & slopes

9 min read
Font
Discuss
Share
Feedback

What you’ll learn

  • Secant vs. tangent lines
  • How the derivative represents the slope of a tangent line
  • How to write equations of tangent and normal lines

Previously, the derivative was introduced as an instantaneous rate of change, which describes how quickly a function changes at a specific point.

The derivative also provides the slope of the tangent line to the graph at that point.

To understand the tangent line, it helps to start with the secant line, a closely related concept.

Secant line:

A straight line that passes through two points on a curve.

  • Its slope represents the average rate of change between those two points.

As one of the points moves closer to the other (with x approaching a) the secant line transforms into the tangent line at that point.

Tangent line:

A straight line that touches the graph of f at (a,f(a)) while following the same direction as the curve.

The slope of the tangent line is defined mathematically by:

f′(a)=x→alim​x−af(x)−f(a)​

This is the same limit definition used for the instantaneous rate of change at x=a. So to find the slope of the tangent line to a function f at x=a, simply evaluate the derivative f′(a).

AP tip:

Whenever you see the keyword “tangent line” in a problem, immediately think “derivative.” Tangent lines always involve the derivative of a function.

Equation of a tangent line

The equation of a line can be written in point-slope form

y−y1​=m(x−x1​)

where m is the slope of the line at the point (x1​,y1​).

In calculus notation, the tangent line at x=a is written as:

Equation of a tangent line:

y=f(a)+f′(a)(x−a)

Here,

  • The point (a,f(a)) replaces (x1​,y1​)

  • f′(a) replaces m, the slope.

Either form can be used as long as you correctly identify the point and the slope.

Equation of the tangent line to f at x = a
Equation of the tangent line to f at x = a

Example

Let f be the function defined by

f(x)=x2

a) Find the equation of the tangent line to f at x=−3.

b) Find the equation of the tangent line to f that is parallel to the line 2x+y=6. (Hint: parallel lines have the same slope.)

Solutions

a) Tangent line equation at x=−3

(spoiler)

1. Identify the point of tangency (a,f(a)):

The point of tangency is where the tangent line meets the curve. This is the function value:

f(−3)=(−3)2=9

2. Find the slope of the tangent line f′(a):

In chapter 2.1.1, the derivative of f(x)=x2 was found to be

f′(x)=2x

The slope of the tangent line at x=−3 is the derivative evaluated at the point:

f′(−3)=2(−3)=−6

3. Construct the equation of the tangent line:

The tangent line meets the curve at (−3,9) and has a slope of −6, so its equation is:

y−9=−6(x+3)

or in slope-intercept form,

y=−6x−9.

It helps to plot both y=x2 and y=−6x−9 in Desmos to see what a tangent line looks like relative to the curve.

b) Tangent line that is parallel to 2x+y=6

(spoiler)

1. Find the slope of the given line:

First, rewrite the line 2x+y=6 in slope-intercept form:

y=−2x+6

This equation shows the slope of the line is −2. Since parallel lines have the same slope, the tangent line to f that we’re looking also has a slope of −2.

2. Find the point of tangency (a,f(a)):

At the target point x=a, the tangent line to f has slope −2. In other words, f′(a)=−2. We just need to find a.

Since the derivative of f(x)=x2 is f′(x)=2x, we solve:

f′(a)−2a​=2a=2a=−1​

Then the corresponding y-value is

f(−1)=(−1)2=1

So the tangent line to f meets it at (−1,1).

3. Construct the equation of the tangent line:

The tangent line passes through (−1,1) and has a slope of −2, so its equation is

y−1=−2(x+1)

or in slope-intercept form,

y=−2x−1.

Normal lines

A normal line is perpendicular to the tangent line at the point of tangency.

Perpendicular slopes are negative reciprocals of each other. For example, if the slope of the tangent line is f′(a)=3, then the slope of the normal line at a is

−f′(a)1​=−31​

If f′(a)=0 (a horizontal tangent), the normal line is vertical and defined by x=a.

Example

Find the equation of the normal line to

f(x)=x2

at x=4.

Solution

(spoiler)

1. Identify (a,f(a)):

The function value at x=4 is

f(4)=42=16

2. Find the slope of the normal line:

The derivative of x2 is f′(x)=2x. Evaluate at x=4 for the slope of the tangent line:

f′(4)=2(4)=8

The slope of the normal line is the negative reciprocal, or −81​.

3. Construct the equation of the normal line:

Since the normal line to f at the point (4,16) has a slope of −81​, its equation is

y−16=−81​(x−4)

It helps to confirm visually by plotting the original function f(x)=x2, the equation of the tangent line, and the equation of the normal line.

Challenge problems

  1. A ball is tossed into the air and follows the path h(t)=−t2+4t, which represents its height (in meters) as a function of time (in seconds). At what time is the instantaneous rate of change of the ball’s height equal to 0?
(spoiler)

The instantaneous rate of change of the height means the derivative, h′(t). Our goal is to find the time t such that h′(t)=0.

Below is the derivative using the limit definition. To keep the notation clear, the height function is rewritten as f(x)=−x2+4x.

f′(x)​=h→0lim​hf(x+h)−f(x)​=h→0lim​h[−(x+h)2+4(x+h)]−(−x2+4x)​=h→0lim​h−(x2+2xh+h2)+4x+4h+x2−4x​=h→0lim​h−2xh−h2+4h​=h→0lim​h​h​(−2x−h+4)​=−2x+4​

Setting this equal to 0:

−2x+4=0x=2

Therefore, the instantaneous rate of change of the ball’s height is 0 when t=2.

Observing the graph of the parabola, this is the highest point the ball reaches (the vertex), and the slope of the tangent line to the curve is 0.

  1. A line with slope m, where m<0, passes through the point (0,−1) and is tangent to the graph of y=x2. Find m.

Solution

(spoiler)

It’s highly recommended that you sketch a quick graph of y=x2. Try drawing the tangent line that passes through (0,−1) with a negative slope to see where it might meet the curve.

1. Identify the point of tangency:

The tangent line to y=x2 meets it at the point (a,a2).

2. Slope of the line

The slope m can be expressed in two ways:

1. Using algebra:

Since the line passes through (0,−1) and (a,a2), the slope can be expressed in terms of a as:

Slopem​=x2​−x1​y2​−y1​​=aa2+1​​

2. Using calculus:

The slope of the tangent line at any point on y=x2 is the derivative. Since f′(x)=2x, and m is the slope at x=a, then

m=2a

3. Solve for a:

Set the two expressions for m equal to each other.

2a2a2a2a​=aa2+1​=a2+1=1=±1​

Since we want the line with a negative slope, take a=−1, which gives

m=−2

Note that if the question asked for the positive slope (m>0), we would take a=1 such that m=2(1)=2. This second tangent line also passes through (0,−1) but meets y=x2 at (1,1) instead.

  1. A secant line connects 2 points and represents the average rate of change.
  2. A tangent line touches effectively touches just 1 point (and does not cross it) and represents the instantaneous rate of change.
  3. The tangent line equation is:

y−f(a)=f′(a)(x−a)

  1. A normal line is perpendicular to the tangent line, with a slope that is the negative reciprocal of the tangent line’s slope, or f′(a)1​.

Sign up for free to take 8 quiz questions on this topic

All rights reserved ©2016 - 2026 Achievable, Inc.

Tangent lines & slopes

What you’ll learn

  • Secant vs. tangent lines
  • How the derivative represents the slope of a tangent line
  • How to write equations of tangent and normal lines

Previously, the derivative was introduced as an instantaneous rate of change, which describes how quickly a function changes at a specific point.

The derivative also provides the slope of the tangent line to the graph at that point.

To understand the tangent line, it helps to start with the secant line, a closely related concept.

Secant line:

A straight line that passes through two points on a curve.

  • Its slope represents the average rate of change between those two points.

As one of the points moves closer to the other (with x approaching a) the secant line transforms into the tangent line at that point.

Tangent line:

A straight line that touches the graph of f at (a,f(a)) while following the same direction as the curve.

The slope of the tangent line is defined mathematically by:

f′(a)=x→alim​x−af(x)−f(a)​

This is the same limit definition used for the instantaneous rate of change at x=a. So to find the slope of the tangent line to a function f at x=a, simply evaluate the derivative f′(a).

AP tip:

Whenever you see the keyword “tangent line” in a problem, immediately think “derivative.” Tangent lines always involve the derivative of a function.

Equation of a tangent line

The equation of a line can be written in point-slope form

y−y1​=m(x−x1​)

where m is the slope of the line at the point (x1​,y1​).

In calculus notation, the tangent line at x=a is written as:

Equation of a tangent line:

y=f(a)+f′(a)(x−a)

Here,

  • The point (a,f(a)) replaces (x1​,y1​)

  • f′(a) replaces m, the slope.

Either form can be used as long as you correctly identify the point and the slope.

Example

Let f be the function defined by

f(x)=x2

a) Find the equation of the tangent line to f at x=−3.

b) Find the equation of the tangent line to f that is parallel to the line 2x+y=6. (Hint: parallel lines have the same slope.)

Solutions

a) Tangent line equation at x=−3

(spoiler)

1. Identify the point of tangency (a,f(a)):

The point of tangency is where the tangent line meets the curve. This is the function value:

f(−3)=(−3)2=9

2. Find the slope of the tangent line f′(a):

In chapter 2.1.1, the derivative of f(x)=x2 was found to be

f′(x)=2x

The slope of the tangent line at x=−3 is the derivative evaluated at the point:

f′(−3)=2(−3)=−6

3. Construct the equation of the tangent line:

The tangent line meets the curve at (−3,9) and has a slope of −6, so its equation is:

y−9=−6(x+3)

or in slope-intercept form,

y=−6x−9.

It helps to plot both y=x2 and y=−6x−9 in Desmos to see what a tangent line looks like relative to the curve.

b) Tangent line that is parallel to 2x+y=6

(spoiler)

1. Find the slope of the given line:

First, rewrite the line 2x+y=6 in slope-intercept form:

y=−2x+6

This equation shows the slope of the line is −2. Since parallel lines have the same slope, the tangent line to f that we’re looking also has a slope of −2.

2. Find the point of tangency (a,f(a)):

At the target point x=a, the tangent line to f has slope −2. In other words, f′(a)=−2. We just need to find a.

Since the derivative of f(x)=x2 is f′(x)=2x, we solve:

f′(a)−2a​=2a=2a=−1​

Then the corresponding y-value is

f(−1)=(−1)2=1

So the tangent line to f meets it at (−1,1).

3. Construct the equation of the tangent line:

The tangent line passes through (−1,1) and has a slope of −2, so its equation is

y−1=−2(x+1)

or in slope-intercept form,

y=−2x−1.

Normal lines

A normal line is perpendicular to the tangent line at the point of tangency.

Perpendicular slopes are negative reciprocals of each other. For example, if the slope of the tangent line is f′(a)=3, then the slope of the normal line at a is

−f′(a)1​=−31​

If f′(a)=0 (a horizontal tangent), the normal line is vertical and defined by x=a.

Example

Find the equation of the normal line to

f(x)=x2

at x=4.

Solution

(spoiler)

1. Identify (a,f(a)):

The function value at x=4 is

f(4)=42=16

2. Find the slope of the normal line:

The derivative of x2 is f′(x)=2x. Evaluate at x=4 for the slope of the tangent line:

f′(4)=2(4)=8

The slope of the normal line is the negative reciprocal, or −81​.

3. Construct the equation of the normal line:

Since the normal line to f at the point (4,16) has a slope of −81​, its equation is

y−16=−81​(x−4)

It helps to confirm visually by plotting the original function f(x)=x2, the equation of the tangent line, and the equation of the normal line.

Challenge problems

  1. A ball is tossed into the air and follows the path h(t)=−t2+4t, which represents its height (in meters) as a function of time (in seconds). At what time is the instantaneous rate of change of the ball’s height equal to 0?
(spoiler)

The instantaneous rate of change of the height means the derivative, h′(t). Our goal is to find the time t such that h′(t)=0.

Below is the derivative using the limit definition. To keep the notation clear, the height function is rewritten as f(x)=−x2+4x.

f′(x)​=h→0lim​hf(x+h)−f(x)​=h→0lim​h[−(x+h)2+4(x+h)]−(−x2+4x)​=h→0lim​h−(x2+2xh+h2)+4x+4h+x2−4x​=h→0lim​h−2xh−h2+4h​=h→0lim​h​h​(−2x−h+4)​=−2x+4​

Setting this equal to 0:

−2x+4=0x=2

Therefore, the instantaneous rate of change of the ball’s height is 0 when t=2.

Observing the graph of the parabola, this is the highest point the ball reaches (the vertex), and the slope of the tangent line to the curve is 0.

  1. A line with slope m, where m<0, passes through the point (0,−1) and is tangent to the graph of y=x2. Find m.

Solution

(spoiler)

It’s highly recommended that you sketch a quick graph of y=x2. Try drawing the tangent line that passes through (0,−1) with a negative slope to see where it might meet the curve.

1. Identify the point of tangency:

The tangent line to y=x2 meets it at the point (a,a2).

2. Slope of the line

The slope m can be expressed in two ways:

1. Using algebra:

Since the line passes through (0,−1) and (a,a2), the slope can be expressed in terms of a as:

Slopem​=x2​−x1​y2​−y1​​=aa2+1​​

2. Using calculus:

The slope of the tangent line at any point on y=x2 is the derivative. Since f′(x)=2x, and m is the slope at x=a, then

m=2a

3. Solve for a:

Set the two expressions for m equal to each other.

2a2a2a2a​=aa2+1​=a2+1=1=±1​

Since we want the line with a negative slope, take a=−1, which gives

m=−2

Note that if the question asked for the positive slope (m>0), we would take a=1 such that m=2(1)=2. This second tangent line also passes through (0,−1) but meets y=x2 at (1,1) instead.

Key points
  1. A secant line connects 2 points and represents the average rate of change.
  2. A tangent line touches effectively touches just 1 point (and does not cross it) and represents the instantaneous rate of change.
  3. The tangent line equation is:

y−f(a)=f′(a)(x−a)

  1. A normal line is perpendicular to the tangent line, with a slope that is the negative reciprocal of the tangent line’s slope, or f′(a)1​.

More from Derivative basics

  • Power rule
  • Product & quotient rules
  • Special derivatives
  • Differentiability & continuity