Skip to contentSkip to lesson map

Rates of Change

Reading
MMAC Ch 4.1, pp 347-359
Lesson map

Objectives

  1. Compute the average rate of change of a function over an interval (slope of a secant line), including dimension and units.
  2. Compute the average rate of change over multiple small intervals to estimate the instantaneous rate of change at a given input.
  3. Describe the derivative at a given input as the instantaneous rate of change and as the slope of a tangent line.
  4. Given a function and a scenario, interpret the meaning of the derivative at a given input, including units.
  5. Write and understand Lagrange (“prime”) and Leibniz (“fraction”) derivative notation.
  6. Given a function and input value, give the equation of the tangent line at that input.

1. Average Rate of Change

Objective. Compute the average rate of change of a function over an interval (slope of a secant line), including dimension and units.

Figure

Definition 1 (Average rate of change).

The average rate of change of a function f(x)f(x) over the interval [a,b][a, b] is the total change in output values of f(x)f(x) divided by the total change in input values:

average rate of change of f(x) over [a,b]=change in outputschange in inputs=f(b)−f(a)b−a. \text{average rate of change of } f(x) \text{ over } [a, b] = \frac{\text{change in outputs}}{\text{change in inputs}} = \frac{f(b) - f(a)}{b - a}.

A single input has no average rate of change. Over [2,2][2, 2] the change in inputs is 2−2=02 - 2 = 0, and the quotient (f(2)−f(2))/0\bigl(f(2) - f(2)\bigr)/0 is undefined; the definition applies only to an interval [a,b][a, b] with a<ba < b.

Definition 2 (Secant line).

A secant line is a line connecting two points on the graph of a function.

The line y=0y = 0 meets the graph of f(x)=x2f(x) = x^2 only at (0,0)(0, 0). It is not a secant line, because the definition requires two points on the graph.

The average rate of change of f(x)f(x) over [a,b][a, b] is the slope of the secant line through (a,f(a))(a, f(a)) and (b,f(b))(b, f(b)).

Units and dimension. The units of an average rate of change are output units per input unit, as in miles per hour. The dimension is [output]/[input][\text{output}]/[\text{input}].

When the output is itself a rate, the units of its rate of change have a second “per input unit.” A velocity in meters per second, with time in seconds, has a rate of change in meters per second per second, written m/s2^2. Its dimension follows from the dimension arithmetic of the Lesson 12 Notes, section 3:

[velocity][time]=LT−1T=LT−2. \frac{[\text{velocity}]}{[\text{time}]} = \frac{LT^{-1}}{T} = LT^{-2}.

Example 1

Compute the average rate of change of ff over [0,2][0, 2] and over [1,2][1, 2]:

f(x)=x3−5x. f(x) = x^3 - 5x.
ShowHide solution

By the definition of average rate of change, the average rate of change of f(x)f(x) over [a,b][a, b] is

f(b)−f(a)b−a. \frac{f(b) - f(a)}{b - a}.

Over [0,2][0, 2], evaluate ff at the endpoints x=0x = 0 and x=2x = 2:

f(0)=03−5(0)=0,f(2)=23−5(2)=8−10=−2. f(0) = 0^3 - 5(0) = 0, \qquad f(2) = 2^3 - 5(2) = 8 - 10 = -2.

Substitute a=0a = 0 and b=2b = 2 into the formula for the average rate of change:

f(2)−f(0)2−0=−2−02−0=−22=−1. \frac{f(2) - f(0)}{2 - 0} = \frac{-2 - 0}{2 - 0} = \frac{-2}{2} = -1.

Over [1,2][1, 2], evaluate ff at the endpoints x=1x = 1 and x=2x = 2. The output f(2)=−2f(2) = -2 comes from the first interval:

f(1)=13−5(1)=1−5=−4. f(1) = 1^3 - 5(1) = 1 - 5 = -4.

Substitute a=1a = 1 and b=2b = 2 into the formula for the average rate of change:

f(2)−f(1)2−1=−2−(−4)2−1=21=2. \frac{f(2) - f(1)}{2 - 1} = \frac{-2 - (-4)}{2 - 1} = \frac{2}{1} = 2.

The average rate of change is −1-1 over [0,2][0, 2] and 22 over [1,2][1, 2]. The signs differ because f(2)=−2f(2) = -2 lies below f(0)=0f(0) = 0 and above f(1)=−4f(1) = -4. By the definition of a secant line, the line through the graph points (0,0)(0, 0) and (2,−2)(2, -2) is a secant line; it falls with slope −1-1, and the secant line through (1,−4)(1, -4) and (2,−2)(2, -2) rises with slope 2.

Figure

Example 2

The table gives the median home price in thousands of dollars from 2001 to 2010 (MMAC 4.1 Question 1). Compute the average rate of change in median home price from 2004 to 2007, with its units and dimension.

Year2001200220032004200520062007200820092010
Price175.2187.6195.0221.0240.9246.5247.9232.1216.7221.8
ShowHide solution

Read the 2004 and 2007 prices from the table and substitute them into the formula for the average rate of change:

price in 2007−price in 20042007−2004=247.9−221.02007−2004=26.93≈8.967. \frac{\text{price in 2007} - \text{price in 2004}}{2007 - 2004} = \frac{247.9 - 221.0}{2007 - 2004} = \frac{26.9}{3} \approx 8.967.

The units are thousand dollars per year, and the dimension is [price]/[year]=BT−1[\text{price}]/[\text{year}] = BT^{-1}. From 2004 to 2007, the median home price rose by an average of about 8.967 thousand dollars, or about $8,967, per year.

Example 3

Compute the average rate of change of ff over [0,2][0, 2] and over [1,2][1, 2] in R:

f(x)=x3−5x. f(x) = x^3 - 5x.
ShowHide solution

Define ff with makeFun(), then define f_change(a, b), which computes the average rate of change of ff over [a,b][a, b] from its formula. Evaluate it on each interval. Used R.

f = makeFun(x^3 - 5*x ~ x)
f_change = makeFun((f(b) - f(a))/(b - a) ~ a & b)
f_change(0, 2)
[1] -1
f_change(1, 2)
[1] 2

R returns

f(2)−f(0)2−0=−1,f(2)−f(1)2−1=2. \frac{f(2) - f(0)}{2 - 0} = -1, \qquad \frac{f(2) - f(1)}{2 - 1} = 2.

Both values match Example 1.

Parentheses. The line f(2) - f(0)/(2 - 0) returns −2-2, because R divides f(0)f(0) by 2 before subtracting. Put the numerator and the denominator each in their own parentheses: (f(2) - f(0))/(2 - 0).

Lesson map

2. Estimating the Instantaneous Rate of Change

Objective. Compute the average rate of change over multiple small intervals to estimate the instantaneous rate of change at a given input.

A car’s average speed over a trip is an average rate of change. The speedometer reading at one moment is an instantaneous rate of change.

Definition 3 (Instantaneous rate of change).

The instantaneous rate of change of a function f(x)f(x) when x=ax = a is the value approached by the average rates of change of f(x)f(x) when these rates are computed over smaller and smaller intervals containing x=ax = a. If the average rates of change do not approach a unique, fixed value, then the instantaneous rate of change is undefined when x=ax = a.

The function f(x)=∣x∣f(x) = |x| has no instantaneous rate of change when x=0x = 0. For every h>0h > 0, its average rate of change over [0,h][0, h] is (∣h∣−0)/h=1(|h| - 0)/h = 1, and over [−h,0][-h, 0] it is (0−∣−h∣)/h=−1(0 - |{-h}|)/h = -1. The average rates from the two sides stay apart, and the definition requires them to approach one unique, fixed value.

Intervals. An interval containing x=ax = a may be symmetric, as in [a−0.01,a+0.01][a - 0.01, a + 0.01]. It may also be one-sided, as in [a,a+0.01][a, a + 0.01] or [a−0.01,a][a - 0.01, a]. When the instantaneous rate of change exists, the average rates over symmetric and one-sided intervals approach the same value.

Stopping test. To estimate the instantaneous rate of change when x=ax = a, follow these steps:

  1. Compute average rates of change over intervals containing x=ax = a, shrinking hh, the distance from aa to the far end of each interval, by a factor of 10 at each step. Early steps may use symmetric intervals; every step tested for stopping uses both one-sided intervals, [a,a+h][a, a + h] and [a−h,a][a - h, a].
  2. Stop at a step where, to three decimals, the two one-sided rates agree with each other and with the rate or rates on the step before. A rounded −0.000-0.000 counts as 0.0000.000.

Example 4

Use R to estimate the instantaneous rate of change of ff when x=0x = 0:

f(x)=x3−5x. f(x) = x^3 - 5x.
ShowHide solution

By the definition of instantaneous rate of change, the rate is the value that the average rates of change approach over smaller and smaller intervals containing x=0x = 0. Define ff and the average-rate function f_change(a, b). Compute average rates of change over symmetric intervals that shrink toward x=0x = 0, then over one-sided intervals on each side of x=0x = 0, and apply the stopping test. Used R.

f = makeFun(x^3 - 5*x ~ x)
f_change = makeFun((f(b) - f(a))/(b - a) ~ a & b)
f_change(-1, 1)
[1] -4
f_change(-0.1, 0.1)
[1] -4.99
f_change(-0.01, 0.01)
[1] -4.9999
f_change(0, 0.001)
[1] -4.999999
f_change(-0.001, 0)
[1] -4.999999

Rounded to three decimals, the rates over [−0.1,0.1][-0.1, 0.1] and [−0.01,0.01][-0.01, 0.01] are −4.990-4.990 and −5.000-5.000. On the next step both one-sided rates round to −5.000-5.000: the rounded rate is unchanged, and the rates from the two sides agree. Both conditions of the stopping test are met:

f(0.001)−f(0)0.001−0=−4.999999≈−5.000,f(0)−f(−0.001)0−(−0.001)=−4.999999≈−5.000. \frac{f(0.001) - f(0)}{0.001 - 0} = -4.999999 \approx -5.000, \qquad \frac{f(0) - f(-0.001)}{0 - (-0.001)} = -4.999999 \approx -5.000.

The instantaneous rate of change of ff when x=0x = 0 is approximately −5.000-5.000. The size is reasonable: near x=0x = 0 the term x3x^3 is tiny, and f(x)f(x) behaves like the line y=−5xy = -5x.

Data tables. At the first or last input of a table, use the one-sided interval between that input and its neighboring input. At an interior input, use the interval between the neighboring inputs on each side. For 2005 in the table of Example 2, that interval is [2004,2006][2004, 2006], and the estimate is

price in 2006−price in 20042006−2004=246.5−221.02006−2004=25.52=12.75 \frac{\text{price in 2006} - \text{price in 2004}}{2006 - 2004} = \frac{246.5 - 221.0}{2006 - 2004} = \frac{25.5}{2} = 12.75

thousand dollars per year.

Example 5

The last two entries of a table of median home price in thousands of dollars are 216.7 for 2009 and 221.8 for 2010. Estimate the instantaneous rate of change in median home price in 2010.

ShowHide solution

The year 2010 is the last input in the table. Use the one-sided interval [2009,2010][2009, 2010], from the neighboring year to 2010, and substitute its prices into the formula for the average rate of change:

price in 2010−price in 20092010−2009=221.8−216.72010−2009=5.11=5.1. \frac{\text{price in 2010} - \text{price in 2009}}{2010 - 2009} = \frac{221.8 - 216.7}{2010 - 2009} = \frac{5.1}{1} = 5.1.

In 2010, the median home price is increasing at about 5.1 thousand dollars, or about $5,100, per year.

Lesson map

3. Derivative

Objective. Describe the derivative at a given input as the instantaneous rate of change and as the slope of a tangent line.

Figure

The figure shows secant lines of f(x)=x3−5xf(x) = x^3 - 5x over [0,2][0, 2], [0,1][0, 1], and [0,0.5][0, 0.5]. The slope over [0,2][0, 2] is −1-1, from Example 1. The other two slopes are

f(1)−f(0)1−0=−4−01=−4,f(0.5)−f(0)0.5−0=−2.375−00.5=−4.75. \frac{f(1) - f(0)}{1 - 0} = \frac{-4 - 0}{1} = -4, \qquad \frac{f(0.5) - f(0)}{0.5 - 0} = \frac{-2.375 - 0}{0.5} = -4.75.

As the interval shrinks toward x=0x = 0, the slopes approach −5-5, the instantaneous rate of change estimated in Example 4, and the secant lines approach the dashed line through (0,0)(0, 0) with slope −5-5. That line is the tangent line, defined next.

Definition 4 (Tangent line).

The tangent line to the graph of a function f(x)f(x) at the point (a,f(a))(a, f(a)) is the line through (a,f(a))(a, f(a)) whose slope is the instantaneous rate of change of f(x)f(x) when x=ax = a.

The vertical line x=0x = 0 meets the graph of f(x)=x3−5xf(x) = x^3 - 5x only at (0,0)(0, 0), and it is not the tangent line there, because a vertical line has no slope. The definition requires a slope equal to the instantaneous rate of change, here about −5-5.

Definition 5 (Derivative).

The instantaneous rate of change of a function f(x)f(x) when x=ax = a is called the derivative of f(x)f(x) when x=ax = a and is denoted by f′(a)f'(a). The following names are used interchangeably:

  • the instantaneous rate of change of f(x)f(x) when x=ax = a
  • the derivative of f(x)f(x) when x=ax = a
  • the rate of change of f(x)f(x) when x=ax = a
  • the slope of the tangent line to f(x)f(x) when x=ax = a
  • the slope of the graph of f(x)f(x) when x=ax = a

The function f(x)=∣x∣f(x) = |x| has no derivative when x=0x = 0, because its instantaneous rate of change there is undefined: its average rates are 1 from the right and −1-1 from the left, as shown after the definition of instantaneous rate of change.

Height and slope. The output f(1)=−4f(1) = -4 is the height of the graph of f(x)=x3−5xf(x) = x^3 - 5x at x=1x = 1. The derivative f′(1)f'(1) is the slope of the tangent line there.

Example 6

The graph shows four lines near the point (1,−4)(1, -4) on the graph of

f(x)=x3−5x. f(x) = x^3 - 5x.

The derivative at that point is f′(1)=−2f'(1) = -2. Which line is the tangent line to f(x)f(x) when x=1x = 1?

Figure
ShowHide solution

By the definition of a tangent line, the tangent line to f(x)f(x) when x=1x = 1 passes through (1,−4)(1, -4) with slope f′(1)=−2f'(1) = -2. Line C does both, and it is the tangent line. Line A is not the tangent line. It passes through the graph points (1,−4)(1, -4) and (2,−2)(2, -2), and its slope is (−2−(−4))/(2−1)=2\bigl(-2 - (-4)\bigr)/(2 - 1) = 2 instead of f′(1)=−2f'(1) = -2; it is the secant line over [1,2][1, 2]. Line B is not the tangent line, because it is horizontal, with slope 0 instead of −2-2. Line D is not the tangent line: it passes through (0,0)(0, 0) and (1,−2)(1, -2), with slope −2-2, and misses the point (1,−4)(1, -4).

Example 7

The graph shows g(x)=xg(x) = \sqrt{x} and its tangent line at (4,2)(4, 2). The tangent line also passes through (0,1)(0, 1). Find g′(4)g'(4), and describe it as a slope and as a rate of change.

Figure
ShowHide solution

By the definition of a tangent line, the slope of the tangent line at (4,2)(4, 2) is the instantaneous rate of change of g(x)g(x) when x=4x = 4, which the definition of the derivative names g′(4)g'(4). Compute the slope from the two marked points on the tangent line:

g′(4)=2−14−0=14=0.25. g'(4) = \frac{2 - 1}{4 - 0} = \frac{1}{4} = 0.25.

The derivative g′(4)=0.25g'(4) = 0.25 is the slope of the tangent line at (4,2)(4, 2). It is also the instantaneous rate of change: when x=4x = 4, g(x)g(x) is increasing at 0.25 output units per input unit. As a check, the average rate of change over [4,4.01][4, 4.01] is (4.01−4)/(4.01−4)≈(2.002498−2)/0.01≈0.2498\bigl(\sqrt{4.01} - \sqrt{4}\bigr)/(4.01 - 4) \approx (2.002498 - 2)/0.01 \approx 0.2498, close to 0.25.

Lesson map

4. Interpreting the Derivative

Objective. Given a function and a scenario, interpret the meaning of the derivative at a given input, including units.

The height HH in meters of a ball thrown straight up, tt seconds after release, is

H(t)=19.6t−4.9t2. H(t) = 19.6t - 4.9t^{2}.

The graphs show HH with its tangent line at t=0.5t = 0.5, 1, 2, and 3. The derivatives are estimated from one-sided average rates on each side of each input. Used R.

H = makeFun(19.6*t - 4.9*t^2 ~ t)
H_change = makeFun((H(b) - H(a))/(b - a) ~ a & b)
H_change(0.5, 0.5001)
[1] 14.69951
H_change(0.4999, 0.5)
[1] 14.70049
H_change(0.5, 0.50001)
[1] 14.69995
H_change(0.49999, 0.5)
[1] 14.70005
H_change(1, 1.0001)
[1] 9.79951
H_change(0.9999, 1)
[1] 9.80049
H_change(1, 1.00001)
[1] 9.799951
H_change(0.99999, 1)
[1] 9.800049
H_change(2, 2.0001)
[1] -0.00049
H_change(1.9999, 2)
[1] 0.00049
H_change(2, 2.00001)
[1] -4.899974e-05
H_change(1.99999, 2)
[1] 4.900009e-05
H_change(3, 3.0001)
[1] -9.80049
H_change(2.9999, 3)
[1] -9.79951
H_change(3, 3.00001)
[1] -9.800049
H_change(2.99999, 3)
[1] -9.799951

At each input, the two one-sided rates over intervals of width 0.0001 and of width 0.00001 all round to the same value to three decimals, with −0.000-0.000 counted as 0.0000.000. The stopping test is met: H′(0.5)≈14.700H'(0.5) \approx 14.700, H′(1)≈9.800H'(1) \approx 9.800, H′(2)≈0.000H'(2) \approx 0.000, and H′(3)≈−9.800H'(3) \approx -9.800. The graphs round these to one decimal.

Positive derivative

Figure

The derivative H′(1)≈9.8H'(1) \approx 9.8 is positive, and the tangent line rises. One second after release, the ball’s height is increasing at about 9.8 meters per second.

Negative derivative

Figure

The derivative H′(3)≈−9.8H'(3) \approx -9.8 is negative, and the tangent line falls. Three seconds after release, the ball’s height is decreasing at about 9.8 meters per second.

Zero derivative

Figure

The derivative H′(2)H'(2) is approximately 0, and the tangent line is horizontal. Two seconds after release, the ball’s height is neither increasing nor decreasing: the ball is at the top of its flight.

Size of the derivative

Figure

The derivative H′(0.5)≈14.7H'(0.5) \approx 14.7 is larger than H′(1)≈9.8H'(1) \approx 9.8, and the orange tangent line at t=0.5t = 0.5 is steeper than the red one at t=1t = 1. Half a second after release, the ball’s height is increasing at about 14.7 meters per second, a rate of greater size than the 9.8 meters per second at one second.

Interpretation. An interpretation of f′(a)f'(a) is one sentence that states

  1. the input value, with its units,
  2. whether the output is increasing or decreasing, and
  3. the size of the rate of change, ∣f′(a)∣|f'(a)|, in output units per input unit.

For a zero derivative at a peak or a valley of the graph, the output is neither increasing nor decreasing. A zero derivative can also occur where the output keeps increasing: f(x)=x3f(x) = x^3 has f′(0)=0f'(0) = 0 and is increasing through x=0x = 0.

Example 8

The function Weight models the average weight in grams of a male fetus, with input Week the gestational age in weeks:

Weight=781.9e0.1216(Week−25). \text{Weight} = 781.9e^{0.1216(\text{Week} - 25)}.

Estimate Weight′(26)\text{Weight}'(26) in R from average rates of change on both sides of week 26, starting with [26,26.0001][26, 26.0001] and [25.9999,26][25.9999, 26]. Give its units and dimension, and interpret it (MMAC 4.1 Exercise 76).

ShowHide solution

Estimate the derivative as in Example 4, with one-sided intervals on each side of week 26 that shrink by a factor of 10. Used R.

Weight = makeFun(781.9*exp(0.1216*(Week - 25)) ~ Week)
Weight_change = makeFun((Weight(b) - Weight(a))/(b - a) ~ a & b)
Weight_change(26, 26.0001)
[1] 107.3736
Weight_change(25.9999, 26)
[1] 107.3723
Weight_change(26, 26.00001)
[1] 107.373
Weight_change(25.99999, 26)
[1] 107.3729
Weight_change(26, 26.000001)
[1] 107.373
Weight_change(25.999999, 26)
[1] 107.373

The rates round to 107.374 and 107.372 on the first step and to 107.373 on both sides on the next two. The stopping test is met:

Weight′(26)≈107.373. \text{Weight}'(26) \approx 107.373.

The units are grams per week, and the dimension is

[Weight][Week]=MT=MT−1. \frac{[\text{Weight}]}{[\text{Week}]} = \frac{M}{T} = MT^{-1}.

In week 26, the average male fetus’s weight is increasing at about 107.373 grams per week. As a check, the average rate over [25,27][25, 27] is (Weight(27)−Weight(25))/2≈(997.176−781.9)/2≈107.638\bigl(\text{Weight}(27) - \text{Weight}(25)\bigr)/2 \approx (997.176 - 781.9)/2 \approx 107.638 grams per week, close to the estimate.

Example 9

The temperature Temp in degrees Fahrenheit on a spring day is modeled by

Temp=60−0.5(Hour−14)2, \text{Temp} = 60 - 0.5(\text{Hour} - 14)^{2},

with input Hour the hour of the day on a 24-hour clock. Use R to estimate Temp′(10)\text{Temp}'(10), Temp′(12)\text{Temp}'(12), and Temp′(14)\text{Temp}'(14), and interpret each.

ShowHide solution

Estimate each derivative as in Example 4, with one-sided intervals on each side of the hour. Used R.

Temp = makeFun(60 - 0.5*(Hour - 14)^2 ~ Hour)
Temp_change = makeFun((Temp(b) - Temp(a))/(b - a) ~ a & b)
Temp_change(10, 10.0001)
[1] 3.99995
Temp_change(9.9999, 10)
[1] 4.00005
Temp_change(10, 10.00001)
[1] 3.999995
Temp_change(9.99999, 10)
[1] 4.000005
Temp_change(12, 12.0001)
[1] 1.99995
Temp_change(11.9999, 12)
[1] 2.00005
Temp_change(12, 12.00001)
[1] 1.999995
Temp_change(11.99999, 12)
[1] 2.000005
Temp_change(14, 14.0001)
[1] -4.999997e-05
Temp_change(13.9999, 14)
[1] 4.999997e-05
Temp_change(14, 14.00001)
[1] -5.000089e-06
Temp_change(13.99999, 14)
[1] 5.000089e-06

R prints the rates at hour 14 in scientific notation: -4.999997e-05 is −0.00004999997-0.00004999997. The rates at each hour round to the same value on both sides and on both steps. At hour 14 the right-side rates round to −0.000-0.000, which counts as 0.0000.000, and the stopping test is met:

Temp′(10)≈4.000,Temp′(12)≈2.000,Temp′(14)≈0.000. \text{Temp}'(10) \approx 4.000, \qquad \text{Temp}'(12) \approx 2.000, \qquad \text{Temp}'(14) \approx 0.000.

At 1000, the temperature is increasing at about 4.000 degrees Fahrenheit per hour. At 1200, it is increasing at about 2.000 degrees Fahrenheit per hour, half the rate at 1000. At 1400, the temperature is neither increasing nor decreasing: it is at the day’s high, Temp(14)=60\text{Temp}(14) = 60 degrees Fahrenheit.

Lesson map

5. Derivative Notation

Objective. Write and understand Lagrange (“prime”) and Leibniz (“fraction”) derivative notation.

NotationSymbolPronunciation
Lagrange (“prime”)f′(a)f'(a)“ff prime of aa”
Leibniz (“fraction”)dfdx∣x=a\left.\dfrac{df}{dx}\right|_{x = a}“dfdf dxdx evaluated at x=ax = a”

The Leibniz fraction is written like an average rate of change, the change in outputs divided by the change in inputs. The derivative is the value that these average rates approach as the intervals shrink. The bar with x=ax = a at its lower right marks the input where the derivative is taken. The fraction gives the dimension of the derivative as [df/dx]=[f]/[x][df/dx] = [f]/[x].

Inverse notation. The symbols f−1(a)f^{-1}(a) and f′(a)f'(a) name different objects. The superscript −1-1 in f−1(a)f^{-1}(a) marks the inverse function evaluated at aa, and the prime in f′(a)f'(a) marks the derivative of f(x)f(x) when x=ax = a.

Example 10

The function Weight models the average weight in grams of a male fetus, with input Week the gestational age in weeks, and satisfies Weight′(26)≈107.373\text{Weight}'(26) \approx 107.373. Write this derivative in Leibniz notation and give its dimension from the fraction.

ShowHide solution

In Leibniz notation, the derivative is

d Weightd Week∣Week=26≈107.373. \left.\frac{d\,\text{Weight}}{d\,\text{Week}}\right|_{\text{Week} = 26} \approx 107.373.

The dimension is

[Weight][Week]=MT=MT−1. \frac{[\text{Weight}]}{[\text{Week}]} = \frac{M}{T} = MT^{-1}.

Example 11

The height HH in meters of a ball thrown straight up, tt seconds after release, satisfies

dHdt∣t=3=−9.8. \left.\frac{dH}{dt}\right|_{t = 3} = -9.8.

Write this derivative in Lagrange notation, say it aloud, and give its units and dimension.

ShowHide solution

In Lagrange notation, the derivative is H′(3)=−9.8H'(3) = -9.8, read “HH prime of 3.” The units are meters per second, and the Leibniz fraction gives the dimension:

[dHdt]=[H][t]=LT=LT−1. \left[\frac{dH}{dt}\right] = \frac{[H]}{[t]} = \frac{L}{T} = LT^{-1}.

Lesson map

6. Equation of the Tangent Line

Objective. Given a function and input value, give the equation of the tangent line at that input.

Definition 6 (Equation of the tangent line).

The equation of the tangent line to f(x)f(x) at (a,f(a))(a, f(a)) is given by

y=f(a)+f′(a)(x−a). y = f(a) + f'(a)(x - a).
  1. Calculate f(a)f(a).
  2. Calculate or approximate f′(a)f'(a).
  3. Substitute these values into the equation of the tangent line.

A line through the point (a,f(a))(a, f(a)) with slope mm has the equation y−f(a)=m(x−a)y - f(a) = m(x - a), its point-slope form. The equation of the tangent line is that form with m=f′(a)m = f'(a), solved for yy. Distributing mm and collecting the constants gives the slope-intercept form: the slope times xx plus the vertical intercept, as in y=2x+3y = 2x + 3.

A horizontal line y=f(a)y = f(a) passes through (a,f(a))(a, f(a)), and it is not the tangent line when f′(a)≠0f'(a) \neq 0, because its slope 0 differs from f′(a)f'(a).

Example 12

Find the equation of the tangent line to ff when x=2x = 2, with f′(2)f'(2) estimated in R:

f(x)=x3−5x. f(x) = x^3 - 5x.
ShowHide solution

The equation of the tangent line to f(x)f(x) at (a,f(a))(a, f(a)) is

y=f(a)+f′(a)(x−a), y = f(a) + f'(a)(x - a),

here with a=2a = 2. To write the equation, find the output f(2)f(2), the height of the point of tangency, and the slope f′(2)f'(2). Calculate the output by hand:

f(2)=23−5(2)=8−10=−2. f(2) = 2^3 - 5(2) = 8 - 10 = -2.

Estimate f′(2)f'(2) as in Example 4, with one-sided intervals on each side of x=2x = 2. Used R.

f = makeFun(x^3 - 5*x ~ x)
f_change = makeFun((f(b) - f(a))/(b - a) ~ a & b)
f_change(2, 2.001)
[1] 7.006001
f_change(1.999, 2)
[1] 6.994001
f_change(2, 2.0001)
[1] 7.0006
f_change(1.9999, 2)
[1] 6.9994
f_change(2, 2.00001)
[1] 7.00006
f_change(1.99999, 2)
[1] 6.99994
f_change(2, 2.000001)
[1] 7.000006
f_change(1.999999, 2)
[1] 6.999994

The rates round to 7.006 and 6.994 on the first step, to 7.001 and 6.999 on the second, and to 7.000 on both sides on the last two. The stopping test is met:

f′(2)≈7.000. f'(2) \approx 7.000.

Substitute f(2)=−2f(2) = -2 and f′(2)≈7f'(2) \approx 7 into the equation of the tangent line, then distribute and collect the constants:

y=f(2)+f′(2)(x−2)≈−2+7(x−2)=−2+7x−14=7x−16. y = f(2) + f'(2)(x - 2) \approx -2 + 7(x - 2) = -2 + 7x - 14 = 7x - 16.

As a check, the line passes through the point of tangency: 7(2)−16=−2=f(2)7(2) - 16 = -2 = f(2). On the graph, the tangent line touches ff at (a,f(a))=(2,−2)(a, f(a)) = (2, -2) and climbs with slope f′(2)≈7f'(2) \approx 7.

Figure

Example 13

The function Weight models the average weight in grams of a male fetus, with input Week the gestational age in weeks:

Weight=781.9e0.1216(Week−25). \text{Weight} = 781.9e^{0.1216(\text{Week} - 25)}.

Find the equation of the tangent line at week 26 in slope-intercept form, and plot it with the model in R.

ShowHide solution

The slope is m=Weight′(26)≈107.373m = \text{Weight}'(26) \approx 107.373, from Example 8. Distribute mm in the equation of the tangent line to reach slope-intercept form:

y=Weight(26)+m(Week−26)=m Week+(Weight(26)−26m). y = \text{Weight}(26) + m(\text{Week} - 26) = m\,\text{Week} + \bigl(\text{Weight}(26) - 26m\bigr).

Compute the vertical intercept Weight(26)−26m\text{Weight}(26) - 26m in R twice, with mm first from the right-side rate and then from the left-side rate, to confirm that the two sides give the same intercept. Keep mm at full precision, because multiplying mm by 26 multiplies its rounding error by 26. Used R.

Weight = makeFun(781.9*exp(0.1216*(Week - 25)) ~ Week)
Weight_change = makeFun((Weight(b) - Weight(a))/(b - a) ~ a & b)
m = Weight_change(26, 26.000001)
Weight(26) - 26*m
[1] -1908.696
m = Weight_change(25.999999, 26)
Weight(26) - 26*m
[1] -1908.696

Both sides give −1908.696-1908.696. By hand, with Weight(26)\text{Weight}(26) and mm rounded to three decimals, the computation is

Weight(26)=781.9e0.1216(26−25)=781.9e0.1216≈883.001,Weight(26)−26m≈883.001−26(107.373)=883.001−2791.698=−1908.697.\begin{align*} \text{Weight}(26) &= 781.9e^{0.1216(26 - 25)} = 781.9e^{0.1216} \approx 883.001,\\ \text{Weight}(26) - 26m &\approx 883.001 - 26(107.373) = 883.001 - 2791.698 = -1908.697. \end{align*}

The hand result differs from R’s in the last decimal, the rounding error that R avoids by keeping Weight(26)\text{Weight}(26) and mm at full precision. The tangent line is

y≈107.373 Week−1908.696. y \approx 107.373\,\text{Week} - 1908.696.

Plot the model and the tangent line together. Used R.

tangent = makeFun(Weight(26) + m*(Week - 26) ~ Week)
plotFun(Weight(Week) ~ Week, xlim = range(20, 35))
plotFun(tangent(Week) ~ Week, add = TRUE, col = "red")

R’s plot shows the model curve and, with col = "red", the tangent line in red, as in the figure. The red line is y≈107.373 Week−1908.696y \approx 107.373\,\text{Week} - 1908.696, and it touches the model at (26,Weight(26))≈(26,883.001)(26, \text{Weight}(26)) \approx (26, 883.001). At week 27 the tangent line’s value is Weight(26)+m(27−26)≈883.001+107.373=990.374\text{Weight}(26) + m(27 - 26) \approx 883.001 + 107.373 = 990.374 grams, below the model’s Weight(27)=781.9e0.1216(27−25)≈997.176\text{Weight}(27) = 781.9e^{0.1216(27 - 25)} \approx 997.176 grams, because the model curves upward.

Figure

Lesson map

Found a mistake, a broken tool or something unclear? Report a problem