Skip to content
Family Table Math

Higher-Order Derivatives

The derivative f′(x)f'(x) is a function too, so you can differentiate it again. The result, f′′(x)f''(x), is the second derivative: it tells you how fast the slope itself is changing. Second derivatives describe acceleration, and they tell you which way a graph bends, which you’ll use a lot in the next units. Any trig on this page is in radians.

Each new derivative is the derivative of the one before it.

DerivativePrime notationLeibniz notation
Firstf′(x)f'(x) or y′y'dydx\dfrac{dy}{dx}
Secondf′′(x)f''(x) or y′′y''d2ydx2\dfrac{d^2y}{dx^2}
Thirdf′′′(x)f'''(x) or y′′′y'''d3ydx3\dfrac{d^3y}{dx^3}
Fourthf(4)(x)f^{(4)}(x) or y(4)y^{(4)}d4ydx4\dfrac{d^4y}{dx^4}
nnthf(n)(x)f^{(n)}(x) or y(n)y^{(n)}dnydxn\dfrac{d^ny}{dx^n}

After three primes, switch to a number in brackets: f(4)f^{(4)}, not f′′′′f''''. The brackets matter, because f4f^4 would look like a power.

In Leibniz notation, d2ydx2\dfrac{d^2y}{dx^2} means ddx(dydx)\dfrac{d}{dx}\left(\dfrac{dy}{dx}\right). The 22 goes on the dd on top and on the xx on the bottom.

  • f(x)f(x) gives the value.
  • f′(x)f'(x) gives the slope, the rate of change of ff.
  • f′′(x)f''(x) gives the rate of change of the slope.

If f′′(x)>0f''(x) \gt 0, the slope is increasing, and the graph bends upward (concave up). If f′′(x)<0f''(x) \lt 0, the slope is decreasing, and the graph bends downward (concave down). You’ll study this in concavity and the second derivative test.

For motion along a line, if s(t)s(t) is position, then s′(t)s'(t) is velocity and s′′(t)s''(t) is acceleration. See straight-line motion.

Three stacked graphs. Top: f(x) = x cubed minus 3x, with a peak at (-1, 2) and a valley at (1, -2). Middle: f prime(x) = 3x squared minus 3, which is zero at x = -1 and x = 1. Bottom: f double prime(x) = 6x, a line through the origin that is zero at x = 0. −2 −1 1 2 −2 2 f(x) = x³ - 3x −2 −1 1 2 −2 2 f′(x) = 3x² - 3 −2 −1 1 2 −2 2 f″(x) = 6x
Each graph shows the slope of the one above it: f′f' is zero where ff levels off, and f′′f'' is zero where f′f' levels off.
  • A polynomial of degree nn becomes a constant after nn derivatives, and 00 after that.
  • Sine and cosine cycle every four derivatives: sin⁡x→cos⁡x→−sin⁡x→−cos⁡x→sin⁡x\sin x \to \cos x \to -\sin x \to -\cos x \to \sin x.
  • Each derivative of ekxe^{kx} brings out another factor of kk, so dndxnekx=knekx\dfrac{d^n}{dx^n}e^{kx} = k^n e^{kx}.

For a curve defined implicitly:

  1. Find dydx\dfrac{dy}{dx} as usual.
  2. Differentiate dydx\dfrac{dy}{dx} again with respect to xx. Remember that yy is still a function of xx, so every yy produces a dydx\dfrac{dy}{dx}.
  3. Substitute your expression for dydx\dfrac{dy}{dx} from step 1.
  4. Simplify, often using the original equation.

This kind of question shows up often on the no-calculator part of the AP exam.

Find all the nonzero derivatives of f(x)=2x4−5x3+x−7f(x) = 2x^4 - 5x^3 + x - 7.

Solution. Differentiate one step at a time:

f′(x)=8x3−15x2+1f′′(x)=24x2−30xf′′′(x)=48x−30f(4)(x)=48\begin{aligned} f'(x) &= 8x^3 - 15x^2 + 1 \\ f''(x) &= 24x^2 - 30x \\ f'''(x) &= 48x - 30 \\ f^{(4)}(x) &= 48 \end{aligned}

Every derivative after f(4)f^{(4)} is 00.

Let y=sin⁡(3x)y = \sin(3x). Find d2ydx2\dfrac{d^2y}{dx^2}, and show that y′′+9y=0y'' + 9y = 0.

Solution. Use the chain rule each time:

dydx=3cos⁡(3x),d2ydx2=3⋅(−sin⁡(3x))⋅3=−9sin⁡(3x)\frac{dy}{dx} = 3\cos(3x), \qquad \frac{d^2y}{dx^2} = 3 \cdot \big(-\sin(3x)\big) \cdot 3 = -9\sin(3x)

Then y′′+9y=−9sin⁡(3x)+9sin⁡(3x)=0y'' + 9y = -9\sin(3x) + 9\sin(3x) = 0.

Let f(x)=xe2xf(x) = xe^{2x}. Find f′′(x)f''(x) and f′′(0)f''(0).

Solution. Product rule, with the chain rule on e2xe^{2x}:

f′(x)=1⋅e2x+x⋅2e2x=e2x(1+2x)f'(x) = 1 \cdot e^{2x} + x \cdot 2e^{2x} = e^{2x}(1 + 2x)

Differentiate f′(x)=e2x(1+2x)f'(x) = e^{2x}(1 + 2x) with the product rule again:

f′′(x)=2e2x(1+2x)+e2x⋅2=e2x(4+4x)=4e2x(1+x)f''(x) = 2e^{2x}(1 + 2x) + e^{2x} \cdot 2 = e^{2x}(4 + 4x) = 4e^{2x}(1 + x)

So f′′(0)=4e0(1)=4f''(0) = 4e^0(1) = 4.

Simplifying f′(x)f'(x) before differentiating again made the second step easier.

For x2+y2=25x^2 + y^2 = 25, find d2ydx2\dfrac{d^2y}{dx^2} in terms of yy, and evaluate it at (3,4)(3, 4).

Solution. From implicit differentiation, dydx=−xy\dfrac{dy}{dx} = -\dfrac{x}{y}.

Differentiate again with the quotient rule. The derivative of the top, xx, is 11; the derivative of the bottom, yy, is dydx\dfrac{dy}{dx}:

d2ydx2=−y⋅1−x⋅dydxy2\frac{d^2y}{dx^2} = -\frac{y \cdot 1 - x \cdot \dfrac{dy}{dx}}{y^2}

Substitute dydx=−xy\dfrac{dy}{dx} = -\dfrac{x}{y}:

d2ydx2=−y+x2yy2=−y2+x2y3\frac{d^2y}{dx^2} = -\frac{y + \dfrac{x^2}{y}}{y^2} = -\frac{y^2 + x^2}{y^3}

From the original equation, x2+y2=25x^2 + y^2 = 25, so

d2ydx2=−25y3\frac{d^2y}{dx^2} = -\frac{25}{y^3}

At (3,4)(3, 4): d2ydx2=−2564\dfrac{d^2y}{dx^2} = -\dfrac{25}{64}. It’s negative, which makes sense: the top half of a circle bends downward.

Squaring the first derivative. f′′(x)f''(x) means “differentiate twice”, not (f′(x))2\big(f'(x)\big)^2. Likewise d2ydx2\dfrac{d^2y}{dx^2} is not (dydx)2\left(\dfrac{dy}{dx}\right)^2.

Plugging in too early. To find f′′(2)f''(2), find the formula for f′′(x)f''(x) first, then substitute. If you substitute x=2x = 2 into f′(x)f'(x) first, you get a number, and the derivative of a number is 00.

Losing chain-rule factors. d2dx2sin⁡(3x)=−9sin⁡(3x)\dfrac{d^2}{dx^2}\sin(3x) = -9\sin(3x), not −3sin⁡(3x)-3\sin(3x) or −sin⁡(3x)-\sin(3x). Each differentiation brings out another factor of 33.

Treating y as a constant in implicit second derivatives. When you differentiate −xy-\dfrac{x}{y}, the derivative of yy is dydx\dfrac{dy}{dx}, not 00.

Not substituting dy/dx. An implicit second derivative should be written in terms of xx and yy only. Replace every dydx\dfrac{dy}{dx} with its expression, then simplify.

Writing f⁽⁴⁾ without brackets. f4(x)f^4(x) looks like f(x)f(x) to the fourth power. Use f(4)(x)f^{(4)}(x) for the fourth derivative.

1. (Warm-up) Let f(x)=x5−4x2f(x) = x^5 - 4x^2. Find f′′(x)f''(x) and f′′(1)f''(1).

Solution

f′(x)=5x4−8xf'(x) = 5x^4 - 8x, so f′′(x)=20x3−8f''(x) = 20x^3 - 8, and f′′(1)=20−8=12f''(1) = 20 - 8 = 12.

2. (Warm-up) Let y=cos⁡xy = \cos x. Find y′′y'' and y(4)y^{(4)}.

Solution

y′=−sin⁡xy' = -\sin x, y′′=−cos⁡xy'' = -\cos x, y′′′=sin⁡xy''' = \sin x, y(4)=cos⁡xy^{(4)} = \cos x.

So y′′=−cos⁡xy'' = -\cos x and y(4)=cos⁡xy^{(4)} = \cos x (back where we started).

3. (Warm-up) Let f(x)=xf(x) = \sqrt{x}. Find f′′(4)f''(4).

Solution

Write f(x)=x1/2f(x) = x^{1/2}:

f′(x)=12x−1/2,f′′(x)=−14x−3/2f'(x) = \frac{1}{2}x^{-1/2}, \qquad f''(x) = -\frac{1}{4}x^{-3/2}f′′(4)=−14⋅143/2=−14⋅18=−132f''(4) = -\frac{1}{4} \cdot \frac{1}{4^{3/2}} = -\frac{1}{4} \cdot \frac{1}{8} = -\frac{1}{32}

4. (Core) Let y=e−3xy = e^{-3x}. Find d3ydx3\dfrac{d^3y}{dx^3}, and give a formula for dnydxn\dfrac{d^ny}{dx^n}.

Solution

Each derivative multiplies by −3-3:

dydx=−3e−3x,d2ydx2=9e−3x,d3ydx3=−27e−3x\frac{dy}{dx} = -3e^{-3x}, \quad \frac{d^2y}{dx^2} = 9e^{-3x}, \quad \frac{d^3y}{dx^3} = -27e^{-3x}

In general, dnydxn=(−3)ne−3x\dfrac{d^ny}{dx^n} = (-3)^n e^{-3x}.

5. (Core) Let f(x)=ln⁡(x2+1)f(x) = \ln(x^2 + 1). Find f′′(x)f''(x), f′′(0)f''(0), and the values of xx where f′′(x)=0f''(x) = 0.

Solution

By the chain rule, f′(x)=2xx2+1f'(x) = \dfrac{2x}{x^2 + 1}. By the quotient rule:

f′′(x)=2(x2+1)−2x(2x)(x2+1)2=2−2x2(x2+1)2f''(x) = \frac{2(x^2 + 1) - 2x(2x)}{(x^2 + 1)^2} = \frac{2 - 2x^2}{(x^2 + 1)^2}

f′′(0)=21=2f''(0) = \dfrac{2}{1} = 2.

f′′(x)=0f''(x) = 0 when 2−2x2=02 - 2x^2 = 0, so x=1x = 1 or x=−1x = -1.

6. (Core) A particle moves along a line so that its position is s(t)=t3−6t2+9ts(t) = t^3 - 6t^2 + 9t metres after tt seconds. Find its velocity and acceleration at t=1t = 1.

Solutionv(t)=s′(t)=3t2−12t+9,a(t)=s′′(t)=6t−12v(t) = s'(t) = 3t^2 - 12t + 9, \qquad a(t) = s''(t) = 6t - 12

v(1)=3−12+9=0v(1) = 3 - 12 + 9 = 0 m/s and a(1)=6−12=−6a(1) = 6 - 12 = -6 m/s².

At t=1t = 1 the particle is momentarily stopped, and its velocity is decreasing.

7. (Core) Let f(x)=xsin⁡xf(x) = x\sin x. Find f′′(x)f''(x) and f′′(π)f''(\pi).

Solutionf′(x)=sin⁡x+xcos⁡xf'(x) = \sin x + x\cos xf′′(x)=cos⁡x+(cos⁡x−xsin⁡x)=2cos⁡x−xsin⁡xf''(x) = \cos x + \big(\cos x - x\sin x\big) = 2\cos x - x\sin x

f′′(π)=2cos⁡π−πsin⁡π=2(−1)−0=−2f''(\pi) = 2\cos\pi - \pi\sin\pi = 2(-1) - 0 = -2.

8. (Challenge) For the hyperbola x2−y2=9x^2 - y^2 = 9, find d2ydx2\dfrac{d^2y}{dx^2} in terms of yy, and evaluate it at (5,4)(5, 4).

Solution

First derivative:

2x−2ydydx=0⇒dydx=xy2x - 2y\frac{dy}{dx} = 0 \quad\Rightarrow\quad \frac{dy}{dx} = \frac{x}{y}

Second derivative, by the quotient rule:

d2ydx2=y⋅1−xdydxy2=y−x2yy2=y2−x2y3\frac{d^2y}{dx^2} = \frac{y \cdot 1 - x\dfrac{dy}{dx}}{y^2} = \frac{y - \dfrac{x^2}{y}}{y^2} = \frac{y^2 - x^2}{y^3}

From the original equation, y2−x2=−9y^2 - x^2 = -9, so

d2ydx2=−9y3\frac{d^2y}{dx^2} = -\frac{9}{y^3}

Check (5,4)(5, 4): 25−16=925 - 16 = 9. Then d2ydx2=−964\dfrac{d^2y}{dx^2} = -\dfrac{9}{64}.

9. (Challenge) Let f(x)=sin⁡(2x)f(x) = \sin(2x). Find f(50)(x)f^{(50)}(x).

Solution

Look for the pattern:

f′(x)=2cos⁡(2x),f′′(x)=−4sin⁡(2x),f′′′(x)=−8cos⁡(2x),f(4)(x)=16sin⁡(2x)f'(x) = 2\cos(2x), \quad f''(x) = -4\sin(2x), \quad f'''(x) = -8\cos(2x), \quad f^{(4)}(x) = 16\sin(2x)

Each derivative brings out a factor of 22, and the trig part cycles every 44 derivatives. Since 50=4⋅12+250 = 4 \cdot 12 + 2, the 5050th derivative has the same trig part as f′′f'', which is −sin⁡(2x)-\sin(2x):

f(50)(x)=−250sin⁡(2x)f^{(50)}(x) = -2^{50}\sin(2x)