What are the derivatives of x + sin x and x sin x and 1/sin x and x/sin x and sinn x? Those are made up from the familiar pieces x and sin x, but we need new rules. Fortunately they are rules that apply to every function, so they can be established once and for all. If we know the separate derivatives of two functions u and v, then the derivatives of u + v and uv and 1/v and u/v and un are immediately available.
This is a straightforward section, with those five rules to learn. It is also an important section, containing most of the working tools of differential calculus. But I am afraid that five rules and thirteen examples (which we need—the eyes glaze over with formulas alone) make a long list. At least the easiest rule comes first. When we add functions, we add their derivatives.
The derivative of the sum u(x) + v(x) is d/dx(u + v) = du/dx + dv/dx. (1)
EXAMPLE 1 The derivative of x + sin x is 1 + cos x. That is tremendously simple, but it is fundamental. The interpretation for distances may be more confusing (and more interesting) than the rule itself:
Suppose a train moves with velocity 1. The distance at time t is t. On the train a professor paces back and forth (in simple harmonic motion). His distance from his seat is sin t. Then the total distance from his starting point is t + sin t, and his velocity (train speed plus walking speed) is 1 + cos t.
If you add distances, you add velocities. Actually that example is ridiculous, because the professor's maximum speed equals the train speed (= 1). He is running like mad, not pacing. Occasionally he is standing still with respect to the ground.
The sum rule is a special case of a bigger rule called "linearity." It applies when we add or subtract functions and multiply them by constants—as in 3x − 4 sin x. By linearity the derivative is 3 − 4 cos x. The rule works for all functions u(x) and v(x). A linear combination is y(x) = au(x) + bv(x), where a and b are any real numbers. Then Δy/Δx is
{au(x + Δx) + bv(x + Δx) − au(x) − bv(x)} ⁄ Δx = a {u(x + Δx − u(x))} ⁄ Δx + b {v(x + Δx − v(x))} ⁄ Δx.
The limit on the left is dyldx. The limit on the right is a duJdx + b dvldx. We are allowed to take limits separately and add. The result is what we hope for:
The derivative of au(x) + bv(x) is (d/dx)(au + bv) = a(du/dx) + b(dv/dx). (2)
The prorluct rule comes next. It can't be so simple-products are not linear. The sum rule is what you would have done anyway, but products give something new. The derivative of u times v is not du/dx times dv/dx. Example: The derivative of x⁵ is 5x⁴. Don't multiply the derivatives of x³ and x². (3x² times 2x is not 5x⁴.) For a product of two functions, the derivative has two terms.
The derivative of u(x)v(x) is d/dx(uv) = u(dv/dx) + v(du/dx). (3)
EXAMPLE 2 u = x³ times v = x² is uv = x⁵. The product rule leads to 5x⁴:
x³(dv/dx) + x²(du/dx) = x³(2x) + x²(3x²) = 2x⁴ + 3x⁴ = 5x⁴.
EXAMPLE 3 In the slope of x sin x, I don't write dxldx = 1 but it's there:
d/dx(x sin x) = x cos x + sin x.
EXAMPLE 4 If u = sin x and v = sin x then uv = sin² x. We get two equal terms:
(sin x)d/dx(sin x) + (sin x)d/dx(sin x)= 2 sin x cos x.
This confirms the "square rule" 2u du/dx, when u is the same as v. Similarly the slope of cos² x is -2 cos x sin x (minus sign from the slope of the cosine).
Question Those answers for sin² x and cos² x have opposite signs, so the derivative of sin² x + cos² x is zero (sum rule). How do you see that more quickly?
EXAMPLE 5 The derivative of uvw is uvw' + uv'w + u'vw —one derivative at a time. The derivative of xxx is xx + xx + xx.
[Fig. 2.13]
After those examples we prove the product rule. Figure 2.13 explains it best. The area of the big rectangle is uv. The important changes in area are the two strips u Av and v Au. The corner area Au Av is much smaller. When we divide by Δx, the strips give u Δv/Δx and v Δu/Δx. The corner gives Δu Δv/Δx, which approaches zero.
Notice how the sum rule is in one dimension and the product rule is in two dimensions. The rule for uvw would be in three dimensions.
The extra area comes from the whole top strip plus the side strip. By algebra,
u(x+h)v(x+h) − u(x)v(x) = u(x+h)[v(x+h) − v(x)] + v(x)[u(x+h) − u(x)]. (4)
This increase is u(x + h)Δv + v(x)Δu —top plus side. Now divide by h (or Δx) and let h → 0. The left side of equation (4) becomes the derivative of u(x)v(x). The right side becomes u(x) times dv/dx—we can multiply the two limits—plus v(x) times du/dx. That proves the product rule—definitely useful.
We could go immediately to the quotient rule for u(x)/v(x). But start with u = 1. The derivative of 1/x is -1/x² (known). What is the derivative of 1/v(x)?
The derivative of 1/v(x) is -dv/dx ⁄ v². (5)
The proof starts with (v)(1/v) = 1. The derivative of 1 is 0. Apply the product rule:
v(d/dx)(1/v) + (1/v)(dv/dx) = 0 so that d/dx(1/v) = -dv/dx ⁄ v². (6)
It is worth checking the units—in the reciprocal rule and others. A test of dimensions is automatic in science and engineering, and a good idea in mathematics. The test ignores constants and plus or minus signs, but it prevents bad errors. If v is in dollars and x is in hours, dv/dx is in dollars per hour. Then dimensions agree:
d/dx(1/v) ≈ (1/dollars) ⁄ hour and also -dv/dx ⁄ v² ≈ (dollars/hour) ⁄ (dollars)².
From this test, the derivative of l/v cannot be l/(dv/dx). A similar test shows that Einstein's formula e = mc2 is dimensionally possible. The theory of relativity might be correct! Both sides have the dimension of (mass)(distance)² ⁄ (timew)², when mass is converted to energy.**
EXAMPLE 6 The derivatives of x-1, x-2, x-n are -1x-2, -2x-3, -nx-n-1. Those come from the reciprocal rule with v = x and x² and any xn:
d/dx(x-n) = d/dx(1/xn) = -nxn-1 ⁄ (xn)² = -nx-n-1.
The beautiful thing is that this answer -nx-n-1 fits into the same pattern as xn. Multiply by the exponent and reduce it by one.
For negative and positive exponents the derivative of xn is nxn-1. (7)
[Fig. 2.14]
EXAMPLE 7 The derivatives of 1/cos x and 1/sin x are +sin x/cos² x and -cos x/sin² x.
Those come directly from the reciprocal rule. In trigonometry, 1/cos x is the secant of the angle x, and 1/sin x is the cosecant of x. Now we have their derivatives:
d/dx(sec x) = sinx ⁄ cos² x = (1 ⁄ cos x)(sin x ⁄ cos x) = sec x tan x. (8)
d/dx(csc x) = -cos x ⁄ sin² x = -(1 ⁄ sin x)(cos x ⁄ sin x) = -csc x cot x. (9)
Those formulas are often seen in calculus. If you have a good memory they are worth storing. Like most mathematicians, I have to check them every time before using them (maybe once a year). It is really the rules that are basic, not the formulas.
The next rule applies to the quotient u(x)/v(x). That is u times 1/v. Combining the product rule and reciprocal rule gives something new and important:
The derivative of u(x)/v(x) is (1/v)(du/dx) − u(dv/dx) ⁄ v² = {v(du/dx) − u(dv/dx)} ⁄ v².
You must memorize that last formula. The v² is familiar. The rest is new, but not very new. If v = 1 the result is duldx (of course). For u = 1 we have the reciprocal rule. Figure 2.14b shows the difference (u + Δu) ⁄ (v + Δv) − (u/v). The denominator V(V+ Av) is responsible for v².
EXAMPLE 8 (only practice) If u/v = x⁵/x³ (which is x²) the quotient rule gives 2x:
d/dx(x⁵/x³) = {x³(5x⁴) − x⁵(3x²)} ⁄ x⁶ = (5x⁷ − 3x⁷) ⁄ x⁶ = 2x.
EXAMPLE 9 (important) For u = sin x and v = cos x, the quotient is sin x ⁄ cos x =
tan x. The derivative of tan x is sec² x. Use the quotient rule and cos² x + sin² x = 1:
d/dx(sinx ⁄ cos x) = {cos x(cos x) − sin x(-sin x)} ⁄ cos² x = 1 ⁄ cos² x = sec² x. (11)
Again to memorize: (tan x)' = sec² x. At x =0, this slope is 1. The graphs of sin x and x and tan x all start with this slope (then they separate). At x = π/2 the sine curve is flat (cos x = 0) and the tangent curve is vertical (sec² x = ∞).
The slope generally blows up faster than the function. We divide by cos x, once for the tangent and twice for its slope. The slope of 1/x is -1/x². The slope is more sensitive than the function, because of the square in the denominator.
EXAMPLE 10 d/dx(sin x ⁄ x) = (x cos x − sin x) ⁄ x².
That one I hesitate to touch at x = 0. Formally it becomes 0/0. In reality it is more like 0³/0², and the true derivative is zero. Figure 2.10 showed graphically that (sin x)/x is flat at the center point. The function is even (symmetric across the y axis) so its derivative can only be zero.
This section is full of rules, and I hope you will allow one more. It goes beyond xn to (u(x)n. A power of x changes to a power of u(x)—as in (sin x)⁶ or (tan x)⁷ or (x² + 1)⁸. The derivative contains nun-1 (copying nxn-1), but there is an extra factor du/dx. Watch that factor in 6(sin x)⁵ cos x and 7(tan x)⁶ sec2 x and 8(x² + 1)⁷(2x):
The derivative of [u(x)]n is n[u(x)]n-1du/dx
For n = 1 this reduces to du/dx = du/dx. For n = 2 we get the square rule 2u du/dx. Next comes u³. The best approach is to use mathematical induction, which goes from each n to the next power n + 1 by the product rule:
d/dx(un+1) = d/dx(unu) = undu/dx + u(nun-1du/dx) = (n+1)undu/dx.
That is exactly equation (12) for the power n + 1. We get all positive powers this way, going up from n = 1 —then the negative powers come from the reciprocal rule.
Figure 2.15 shows the power rule for n = 1,2,3. The cube makes the point best. The three thin slabs are u by u by Δu. The change in volume is essentially 3u²Δu. From multiplying out (u+Δu)³, the exact change in volume is 3u² Δu + 3u(Δu)² + (Δu)³ —which also accounts for three narrow boxes and a midget cube in the corner. This is the binomial formula in a picture.
[Fig. 2.15]
EXAMPLE 11 d/dx(sin x)n = n(sin x)n-1 cos x. The extra factor cos x is du/dx.
Our last step finally escapes from a very undesirable restriction—that n must be a whole number. We want to allow fractional powers n = p/q, and keep the same formula. The derivative of xn is still nxn-1.
To deal with square roots I can write (√)² = x. Its derivative is 2√(√)' = 1. Therefore (√)' is 1/2√x, which fits the formula when n = ½. Now try n = p/q:
Fractional powers Write u = xp/q as uq = xp. Take derivatives, assuming they exist:
qun-1du/dx = pxp-1 (power rule on both sides)
du/dx = px-1 ⁄ qu-1 (cancel xp with uq)
du/dx = nxn-1 (replace p/q by n and u by xn)
EXAMPLE 12 The slope of x1/3 is (1/3)x-2/3. The slope is infinite at x = 0 and zero at x = ∞. But the curve in Figure 2.16 keeps climbing. It doesn't stay below an "asymptote."
[Fig. 2.16]
EXAMPLE 13 The slope of x4/3 is (4/3)x1/3. The slope is zero at x = 0 and infinite at x = ∞. The graph climbs faster than a line and slower than a parabola (4 is between 1 and 2). Its slope follows the cube root curve (times j).
WE STOP NOW! I am sorry there were so many rules. A computer can memorize them all, but it doesn't know what they mean and you do. Together with the chain rule that dominates Chapter 4, they achieve virtually all the derivatives ever computed by mankind. We list them in one place for convenience.
Rule of Linearity | (au + bv)' = au' + bv' |
Product Rule | (uv)' = uv' + vu' |
Reciprocal Rule | (1/v)' = -v'/v² |
Quotient Rule | (u/v)' =(vu' − uv') ⁄ v² |
Power Rule | (un)' = nun-1u' |
The power rule applies when n is negative, or a fraction, or any real number. The derivative of xπ is πxπ-1, according to Chapter 6. The derivative of (sin x)" is . And the derivatives of all six trigonometric functions are now established:
(sin x)' = cos x (tan x)' = sec² x (sec x)' = sec x tan x
(cos x)' = -sin x (cot x)' = -csc² x (csc x)' = -csc x cot x.