The derivative

In the previous lesson, we estimated the sensitivity of a function at one particular input by examining smaller and smaller changes. That process gave us a slope at one point, but it was rather tedious. So what if there were a more precise and more efficient way to find the slope by computing it at every point all at once?
In this lesson, we'll look for patterns that turn those individual slopes into a whole new function. This derivativederivativeA function that gives the instantaneous rate of change of another function at each input. function will let us find instantaneous rates directly, opening the door to many applied problems.
By the end of this lesson, you should be able to:
- Interpret the derivative as a new function that gives an instantaneous rate of change at each input.
- Use the Power Rule, Sum and Difference Rules, and Constant Multiple Rule to differentiate polynomial-like functions.
In order to be able to use calculus, we'll need to be able to compute \( \displaystyle \dv{y}{x} \) more efficiently than repeatedly calculating \( \displaystyle \frac{\Delta y}{\Delta x} \) over smaller and smaller intervals. What we'd really like is a way to be able to take a function \( y=f(x) \), perhaps with an algebraic formula, and be able to figure out \( \displaystyle \dv{y}{x} \) immediately just by looking at it.
For a simple example, let's consider the quadratic function \( x^2 \), whose graph is a parabola. If we can find the slope of this curve at any point, then any time an \( x^2 \) shows up in something we're studying, we'll know what to do with it without having to do any extra work.
To make it easier to see what's happening, we'll visualize \( x^2 \) by imagining it as the area of a whose side length is \( x \).
To start off with something concrete, suppose we have an \( 3\times 3 \) square, whose area is . What happens to the area if we increase the side lengths by a small amount, say, \( 0.1 \)?
Doing so adds three new pieces to the original square: two thin rectangles with an area of each, and one small square with an area of . Adding the four areas together, we find that the area of the new \( 3.1\times 3.1 \) square is . Subtracting the original area of \( 9 \), we get that the change in area is \( \Delta A= \). Finally, to see how the change in area is related to the change in side length, we find the average rate of change \[\frac{\Delta A}{\Delta x}\text,\] which comes out to .
What we'd really like to know now is how sensitive the area is to changes in side length, which means we need to find \( \displaystyle \dv{A}{x} \). In our previous lesson we would have done this by redoing the above problem for smaller and smaller values of \( \Delta x \), but let's see if we can find a slicker way to do it.
Instead of starting with a particular size for our square, let's just use \( x \) for the length of the original square, and let \( \Delta x \) be how much that length changes.
The original square has an area of . When we change the side length by \( \Delta x \), we get three new pieces: two thin rectangles with an area of each, and one small square with an area of . Adding the four areas together, we find that the area of the new square is
\[\begin{aligned}A\tsub{new}&=(x+\Delta x)^2\\ &=\mathhlred{x^2}+\mathhlblue{2x\,\Delta x}+\mathhlviolet{(\Delta x)^2}\text{.}\end{aligned}\]
To find how much the area changed, we subtract the old area from the new area:
\[\begin{aligned}\Delta A &= A\tsub{new}-A\tsub{old}\\ &= \qty(x^2+2x\,\Delta x+(\Delta x)^2) - x^2\\ &= 2x\,\Delta x+(\Delta x)^2\text.\end{aligned}\] Finally, to see how the change in area is related to the change in side length, we find the average rate of change:
\[\begin{aligned}\frac{\Delta A}{\Delta x} &= \frac{2x\,\Delta x+(\Delta x)^2}{\Delta x}\end{aligned}\]
Simplifying this expression, we find that \( \displaystyle \frac{\Delta A}{\Delta x}= \).
Now, if we imagine that \( \Delta x \) becomes infinitely small, then the term will be much larger than the term. Hence if we treat that tiny change as negligible, we end up with\[\dv{A}{x}=2x\text.\]
This is big.
What we've done is taken a function we wanted to know about, and derived a brand-new function that instantly tells us the slope of the original function at any point.
For example, when \( x=3 \), we have \(\displaystyle \eval{\dv{A}{x}}_{x=3}=\)\(\displaystyle \text.\) And if you zoom in close enough to the graph of \( y=x^2 \) around \( x=3 \) to the point where the graph looks linear, it does indeed seem to have a slope of about \( 6 \).
This new function \( 2x \) is called the derivativederivativeA function that gives the instantaneous rate of change of another function at each input. of \( x^2 \), because we derived it from \( x^2 \) by reasoning about infinitesimal quantities. The derivative will be our main object of study for the next two chapters.
From individual slopes to a slope function
In the previous lesson, we learned how to find an instantaneous rate of change \( \displaystyle \dv{y}{x} \) at one particular input by repeatedly computing the average rate of change \( \displaystyle \frac{\Delta y}{\Delta x} \) over smaller and smaller intervals. However, we can make this process much more efficient by finding general patterns in those rates of change.
The function \( f' \) is derived from \( f \), which is why we call it the "derivative." The process of finding the derivative is called differentiationdifferentiationThe process of finding the derivative of a function., since the slope we find can be thought of as ratio of differentials.
Notations for derivatives and differentials
We now have seen two types of notation for the derivative:
We can use differential notation, writing \( \displaystyle \dv{f}{x} \) or \( \displaystyle \dv{y}{x} \).
We can use prime notation, writing \( f'(x) \) or \( y' \).
While these notations are largely interchangeable, you'll sometimes find that one is easier to use than the other depending on the situation. We can also relate them together: if \( y=f(x) \), then we can say \[\dv{y}{x}=f'(x)\text.\] You can think of this as saying that the slope of \( f \) (the ratio between infinitesimal changes \( \dd{y} \) and \( \dd{x} \)) is given by this new derivative function \( f' \).
One more shorthand that often comes in handy is the notation \( \displaystyle \dv{}{x} \), which you can read as "the derivative with respect to \( x \)." (The phrase "with respect to \( x \)" just means that we're specifying our independent variable is \( x \).) For example, we can write:
\[\dv{x}\qty(x^2)=2x\text.\]
This can be read out loud as "the derivative of \( x^2 \) (with respect to \( x \)) is \( 2x \)."
We call \( \displaystyle \dv{x} \) an operatoroperatorA mathematical instruction that acts on an expression to produce another expression.: it does something to the expression to its right, namely, it takes the derivative. If this notation seems a bit weird, don't worry — we'll see exactly where it comes from when we talk a bit more about differentials later in the section.
Finding derivatives of well-known functions
Let's look at the derivatives of some often-used functions, starting with linear functions.
A constant functionconstant functionA function that has the same output for every input. is a function of the form \( f(x)=c \) (for some number \( c \)) that outputs the same value (\( c \)) no matter what the input is. This can be thought of as a linear function with a slope of \( 0 \).
Next let's consider powers of \( x \). We already saw the derivative of the quadratic function\( x^2 \) in the Explore activity:
We can apply this same logic to find the derivative of the cubic function \( x^3 \).
Now step back and take a look at what we've found for the derivatives of \( x \), \( x^2 \), and \( x^3 \):
| Function | Derivative |
|---|---|
| \( x^1 \) | \( 1x^0 \) |
| \( x^2 \) | \( 2x^1 \) |
| \( x^3 \) | \( 3x^2 \) |
Notice that in each case, the exponent 'moves' to the front as a coefficient, and the new exponent is one less than the original. This pattern seems to suggest the following rule:
Note that we've actually only justified this rule geometrically for \( n=1,2,3 \), but it turns out that the same pattern works for larger powers, negative powers, fractional powers, and even arbitrary real number powers. We'll go ahead and start using the Power Rule for all of these cases, but later sections will give us new ways to explain why this pattern continues to work.
Sums, differences, and constant multiples
Derivatives preserve several of the familiar properties of ordinary changes. These results allow us to break a complicated function into simpler pieces and differentiate those pieces separately.
Together with the Power Rule, these properties now allow us to differentiate a polynomial one term at a time.
Derivatives and differentials
Starting with the equation \( \displaystyle f'(x)=\dv{y}{x} \), we can multiply by \( \dd{x} \) to solve for the corresponding differential in the output:
\[\dd{y}=f'(x)\dd{x}\text{.}\]
This form emphasizes what the derivative does: near the input \( x \), it converts a small nudge \( \dd{x} \) into the corresponding small nudge \( \dd{y} \).
For \( y=x^2 \), we have \( \dd{y}=2x\dd{x} \). At \( x=1 \), this becomes \( \dd{y}=2\dd{x} \): along the matching line, the infinitesimal vertical nudge is twice the infinitesimal horizontal nudge.
We can write any of our derivative rules in differential form by multiplying both sides by the differential of the independent variable. For example, the derivative rule
\[\dv{x}(x^2)=2x\]
can be rewritten as
\[\dd(x^2)=2x\dd{x}\text{.}\]
These equations express the same relationship in two different ways. The derivative form gives the ratio between the changes; the differential form solves for the change in the output produced by an infinitesimal change \( \dd{x} \).
This also explains the operator notation \( \displaystyle \dv{}{x} \): first we take the differential of an expression, then we divide by \( \dd{x} \). For instance,
\[\begin{aligned}\dv{x}(x^2)&=\frac{\dd(x^2)}{\dd{x}}\\ &=\frac{2x\dd{x}}{\dd{x}}\\ &=2x\text{.}\end{aligned}\]
Thus \( \displaystyle \dv{}{x} \) can be read not only as “the derivative with respect to \( x \),” but also as an instruction: take the differential, then divide by \( \dd{x} \).
With the Power Rule and various other properties in hand, we can now find derivatives for a wide variety of functions that appear across many fields of study. In the exercises, we'll practice carrying out these calculations and interpreting what the resulting derivatives mean in context.
Rewrite each expression in the form \( ax^n \), which we'll sometimes call "Calculus-Friendly Form." Do not differentiate yet.
\( \displaystyle \frac{${c}}{x^{${n}}}={} \)
Solution
\( ${c}x^{-${n}} \)
\( \displaystyle ${c}\sqrt[${root_index}]{x}={} \)
Solution
\( ${c}x^{1/${n}} \)
\( \displaystyle \frac{${c}}{\sqrt[${root_index}]{x}}={} \)
Solution
\( ${c}x^{-1/${n}} \)
\( \displaystyle ${c}\sqrt[${n}]{x^{${p}}}={} \)
Solution
\( ${c}x^{${p}/${n}} \)
Use the Power Rule along with the Sum, Difference, and Constant Multiple Rules to find each derivative.
If \( f(x)=x^{${n}} \), then \( f'(x)= \).
Solution
\( f'(x)=${answer} \).
If \( \displaystyle f(x)=${c}x^{${n}} \), then \( f'(x)= \).
Solution
\( \displaystyle f'(x)=${answer} \).
If \( \displaystyle g(x)=\frac{1}{x^{${n}}} \), then \( g'(x)= \).
Solution
First we rewrite the function in Calculus-Friendly Form:
\[g(x)=x^{-${n}}\text{.}\]
Now we apply the Power Rule:
\[g'(x)=-${n}x^{-${n + 1}}\text{.}\]
If we choose to rewrite the answer without negative exponents, then
\[g'(x)=-\frac{${n}}{x^{${n + 1}}}\text{.}\]
If \( h(x)=${c}\sqrt[${root_index}]{x} \), then \( h'(x)= \).
Solution
First we rewrite the function in Calculus-Friendly Form:
\[h(x)=${c}x^{1/${n}}\text{.}\]
Then the Power Rule and Constant Multiple Rule give
\[h'(x)=${k}x^{-${n - 1}/${n}}\text{.}\]
If we choose to rewrite the answer without negative exponents, then
\[h'(x)=\frac{${k}}{\sqrt[${root_index}]{x^{${n - 1}}}}\text{.}\]
If \( p(x)=${c}x^{${fixed(n,1)}} \), then \( p'(x)= \).
Solution
\( p'(x)=${derivative_coefficient}x^{${derivative_power}} \).
If \( q(t)=${function} \), then \( q'(t)= \).
Solution
\( q'(t)=${answer} \).
If \( \displaystyle r(z)=\frac{${a}}{z^{${k}}}-${b}\sqrt[${root_index}]{z^{${p}}}+${c} \), then \( r'(z)= \).
Solution
First we rewrite the function in Calculus-Friendly Form:
\[r(z)=${a}z^{-${k}}-${b}z^{${p}/${d}}+${c}\text{.}\]
Then we differentiate one term at a time:
\[r'(z)=-${a*k}z^{-${k + 1}}-${fractional_coefficient}z^{-${d - p}/${d}}\text{.}\]
If we choose to rewrite the answer without negative exponents, then
\[r'(z)=-\frac{${a*k}}{z^{${k + 1}}}-\frac{${fractional_coefficient}}{\sqrt[${root_index}]{z^{${d - p}}}}\text{.}\]
If \( s(x)=\pi^{${n}} \), then \( s'(x)= \).
Solution
The expression \( \pi^{${n}} \) is a constant; it does not depend on \( x \). Therefore,
\[s'(x)=0\text.\]
If \( \displaystyle u(x)=(${a}x+${b})(${c}x^2+${d}) \), then \( u'(x)= \).
Solution
Do not differentiate the two factors separately; that doesn't give the derivative of their product. Instead, multiply them first:
\[u(x)=${a*c}x^3+${b*c}x^2+${a*d}x+${b*d}\text.\]
Now we can differentiate one term at a time:
\[u'(x)=${3*a*c}x^2+${2*b*c}x+${a*d}\text.\]
If \( \displaystyle v(x)=(${a}x^2+${b}x+${c})^2 \), then \( v'(x)= \).
Solution
Remember that squaring means to multiply the polynomial by itself:
\[\begin{aligned}v(x)&=(${a}x^2+${b}x+${c})(${a}x^2+${b}x+${c})\\ &=${a^2}x^4+${2*a*b}x^3+${b^2 + 2*a*c}x^2+${2*b*c}x+${c^2}\text.\end{aligned}\]
Then differentiate one term at a time:
\[v'(x)=${4*a^2}x^3+${6*a*b}x^2+${linear_coefficient}x+${2*b*c}\text.\]
If \( \displaystyle w(x)=\frac{${a}x^{${high_power}}+${middle_term}+${c}}{x^{${k}}} \), then \( w'(x)= \).
Solution
Do not differentiate the numerator and denominator separately; that doesn't give the derivative of their quotient. Instead, distribute the denominator and simplify first:
\[\begin{aligned}w(x)&=\frac{${a}x^{${high_power}}}{x^{${k}}}+\frac{${middle_term}}{x^{${k}}}+\frac{${c}}{x^{${k}}}\\ &=${a}x^{${high_power-k}}+${b}x^{-${k-middle_power}}+${c}x^{-${k}}\text.\end{aligned}\]
Now differentiate one term at a time:
\[w'(x)=${derivative_cff}\text.\]
Find each differential. Make sure to include the differential of the independent variable at the end of each answer.
If \( f(x)=${c}x^{${n}} \), find \( \dd{f} \).
\( \dd{f}= \)
Solution
\[\dd{f}=${c*n}x^{${n - 1}}\dd{x}\text.\]
If \( \displaystyle g(t)=\frac{${c}}{t^{${n}}} \), find \( \dd{g} \).
\( \dd{g}= \)
Solution
First rewrite the function as \( g(t)=${c}t^{-${n}} \). Then
\[\dd{g}=-${c*n}t^{-${n + 1}}\dd{t}\text.\]
If \( h(z)=${d*k}\sqrt[${root_index}]{z^{${p}}} \), find \( \dd{h} \).
\( \dd{h}= \)
Solution
First rewrite the function as \( h(z)=${d*k}z^{${p}/${d}} \). Then
\[\dd{h}=${k*p}z^{-${d - p}/${d}}\dd{z}\text.\]
If \( p(u)=${a}u^{${n}}+${b}u^{${m}}+${c}u \), find \( \dd{p} \).
\( \dd{p}= \)
Solution
\[\dd{p}=\qty(${a*n}u^{${n - 1}}+${b*m}u^{${m - 1}}+${c})\dd{u}\text.\]
A small manufacturer sells each unit of a product for \( \$${unit_price} \). If \( x \) units are produced and sold, then the revenue \( R \) and cost \( C \), both in dollars, are modeled by
\[R(x)=${unit_price}x\text{,}\]
\[C(x)=${fixed_cost}+${variable_cost}x+${quadratic_cost}x^2\text{.}\]
ProfitprofitThe revenue remaining after all costs have been subtracted. is the revenue left after subtracting all costs, so \( P(x)=R(x)-C(x) \).
Find the profit function \( P(x) \) and write it as a single polynomial.
\( P(x)= \)
Solution
\[\begin{aligned}P(x)&=R(x)-C(x)\\ &=${unit_price}x-\qty(${fixed_cost}+${variable_cost}x+${quadratic_cost}x^2)\\ &=-${quadratic_cost}x^2+${profit_linear}x-${fixed_cost}\text{.}\end{aligned}\]
The derivative of revenue with respect to quantity produced and sold is called marginal revenuemarginal revenueThe derivative of revenue with respect to quantity, which estimates the change in revenue from producing and selling one additional unit., written \( MR(x)=R'(x) \). Near a particular value of \( x \), it estimates the change in revenue from producing and selling one additional unit. Find \( MR(x) \), then evaluate it at \( x=${quantity} \).
\( MR(x)= \), and \( MR(${quantity})= \).
Solution
\[MR(x)=R'(x)=${marginal_revenue}\text{,}\]
so \( MR(${quantity})=${marginal_revenue} \) dollars per additional unit.
The derivative of cost is called marginal costmarginal costThe derivative of cost with respect to quantity, which estimates the change in cost from producing one additional unit., written \( MC(x)=C'(x) \). Near a particular value of \( x \), it estimates the change in cost from producing one additional unit. Find \( MC(x) \), then evaluate it at \( x=${quantity} \).
\( MC(x)= \), and \( MC(${quantity})= \).
Solution
\[MC(x)=C'(x)=${variable_cost}+${2*quadratic_cost}x\text{,}\]
so \( MC(${quantity})=${marginal_cost_value} \) dollars per additional unit.
The derivative of profit is called marginal profitmarginal profitThe derivative of profit with respect to quantity, which estimates the change in profit from producing and selling one additional unit., written \( MP(x)=P'(x) \). Near a particular value of \( x \), it estimates the change in profit from producing and selling one additional unit. Differentiate the profit function you found, then evaluate the result at \( x=${quantity} \).
\( MP(x)= \), and \( MP(${quantity})= \).
Solution
\[MP(x)=P'(x)=${profit_linear}-${2*quadratic_cost}x\text{,}\]
so \( MP(${quantity})=${marginal_profit_value} \) dollars per additional unit.
Compare your three marginal values:
\(\displaystyle MR(${quantity})-MC(${quantity})=\)\(\displaystyle -\)\(\displaystyle =\)\(\displaystyle \text{.}\)
Which equation describes the same relationship for any value of \( x \)?
Solution
Because profit is revenue minus cost, differentiating the profit function subtracts the corresponding marginal functions:
\[MP(x)=MR(x)-MC(x)\text{.}\]
Which is the best interpretation of \( MP(${quantity})=${marginal_profit_value} \)?
Solution
Marginal profit is measured in dollars per additional unit. It estimates how profit changes when production and sales increase from the current level by one unit.
The following problems showcase a number of other real-world phenomena that can be modeled with power and polynomial functions.
Biology
Kleiber's Law models resting metabolic rate \( B \), in kilocalories per day, from mass \( M \), in kilograms: \[B(M)=70M^{0.75}\]
Find \( B'(M) \).
\( B'(M)= \)
Solution
\[B'(M)=52.5M^{-0.25}\text.\]
Evaluate \( B'(${mass}) \).
Solution
\( B'(${mass})=${rate_decimal} \).
The units of \( B'(M) \) are .
Solution
The derivative compares a change in metabolic rate with a change in mass, so its units are kilocalories per day per kilogram.
Which is the best interpretation of \( B'(${mass})=${rate_decimal} \)?
Solution
The derivative gives the change in predicted metabolic rate per additional kilogram.
Astronomy
An object's orbital period \( T \), in years, is modeled from its average orbital radius \( a \), in astronomical units, by the function \[T(a)=a^{3/2}\text.\]
Find \( T'(a) \).
\( T'(a)= \)
Solution
\[T'(a)=\frac32a^{1/2}\text.\]
Evaluate \( T'(${radius}) \).
Solution
\( T'(${radius})=${rate} \).
The units of \( T'(a) \) are .
Solution
The derivative compares a change in orbital period with a change in orbital radius, so its units are years per astronomical unit.
Which is the best interpretation of \( T'(${radius})=${rate} \)?
Solution
The derivative gives the change in orbital period per additional astronomical unit of radius.
Ecology
An island's number of plant species is modeled from its area \( A \), in square kilometers, by \[S(A)=${c}A^{0.3}\text.\]
Find \( S'(A) \).
\( S'(A)= \)
Solution
\[S'(A)=${derivative_coefficient}A^{-0.7}\text.\]
Evaluate \( S'(${area}) \). Round to three decimal places.
Solution
\( S'(${area})\approx${fixed(rate,3)} \).
The units of \( S'(A) \) are .
Solution
The derivative compares a change in species count with a change in area, so its units are species per square kilometer.
Which is the best interpretation of \( S'(${area})\approx${fixed(rate,3)} \)?
Solution
The derivative gives the change in predicted species count per additional square kilometer.
Engineering
A pipe's volume flow rate \( Q \), in cubic centimeters per second, depends on radius \( r \), in centimeters, according to \[Q(r)=${flow_coefficient}r^4\text.\]
Find \( Q'(r) \).
\( Q'(r)= \)
Solution
\[Q'(r)=${derivative_coefficient}r^3\text.\]
Evaluate \( Q'(${radius}) \).
Solution
\( Q'(${radius})=${rate} \).
The units of \( Q'(r) \) are .
Solution
The derivative compares a change in flow rate with a change in radius, so its units are cubic centimeters per second per centimeter.
Which is the best interpretation of \( Q'(${radius})=${rate} \)?
Solution
The derivative gives the change in predicted flow rate per additional centimeter of radius.
Public health
The concentration \( C \) of an airborne contaminant, in micrograms per cubic meter, is modeled from distance \( d \), in kilometers, by \[C(d)=${c}d^{-2}\text.\]
Find \( C'(d) \).
\( C'(d)= \)
Solution
\[C'(d)=-${2*c}d^{-3}\text.\]
Evaluate \( C'(${distance}) \). Round to three decimal places.
Solution
\( C'(${distance})\approx${fixed(rate,3)} \).
The units of \( C'(d) \) are .
Solution
The derivative compares a change in concentration with a change in distance, so its units are micrograms per cubic meter per kilometer.
Which is the best interpretation of \( C'(${distance})\approx${fixed(rate,3)} \)?
Solution
The negative derivative means that predicted concentration decreases as distance increases.
Economics
A factory's weekly cost \( C \), in dollars, for producing \( q \) hundreds of items is \[C(q)=${fixed_cost}+${linear_cost}q+${quadratic_cost}q^2\text.\]
Find \( C'(q) \).
\( C'(q)= \)
Solution
\[C'(q)=${linear_cost}+${derivative_coefficient}q\text.\]
Evaluate \( C'(${quantity}) \).
Solution
\( C'(${quantity})=${rate} \).
The units of \( C'(q) \) are .
Solution
The derivative compares a change in weekly cost with a change in hundreds of items, so its units are dollars per hundred items.
Which is the best interpretation of \( C'(${quantity})=${rate} \)?
Solution
The input is measured in hundreds of items, so the derivative gives the additional weekly cost for another hundred items.
Information science
Processing time \( T \), in milliseconds, for \( n \) thousand records is modeled by \[T(n)=${cubic_decimal}n^3+${linear_decimal}n\text.\]
Find \( T'(n) \).
\( T'(n)= \)
Solution
\[T'(n)=${derivative_decimal}n^2+${linear_decimal}\text.\]
Evaluate \( T'(${records}) \). Round to two decimal places.
Solution
\( T'(${records})=${fixed(rate,2)} \).
The units of \( T'(n) \) are .
Solution
The derivative compares a change in processing time with a change in thousands of records, so its units are milliseconds per thousand records.
Which is the best interpretation of \( T'(${records})=${fixed(rate,2)} \)?
Solution
The input is measured in thousands of records, so the derivative gives the additional processing time for another thousand records.