girgit.org

Continuity and Differentiability

Second order derivatives: the rate of the rate

The big ideaDifferentiate \( \frac{dy}{dx} \) once more and you get the second order derivative \( \frac{d^2y}{dx^2} \): how fast the slope itself is changing.

In simple words

Speed tells you how fast your position changes. But speed can change too: you press the pedal and the speed goes up. How fast the speed changes is the second step. In maths, the first derivative is the slope, and the second derivative is how quickly that slope is turning.

Differentiating twice

Let \( y = f(x) \), so \( \frac{dy}{dx} = f'(x) \). If \( f'(x) \) is itself differentiable, differentiate again:

\[ \frac{d}{dx}\left( \frac{dy}{dx} \right) = \frac{d^2y}{dx^2} \]

This is the second order derivative of y with respect to x. It is also written \( f''(x) \) ("f double dash x"), \( D^2y \), \( y'' \), or \( y_2 \). In the same style, \( y_1 \) means \( \frac{dy}{dx} \). Higher order derivatives (third, fourth, ...) are defined the same way.

What it means. For a car, if y is position and x is time, \( \frac{dy}{dx} \) is velocity and \( \frac{d^2y}{dx^2} \) is acceleration. On a graph, a positive second derivative means the slope is increasing (the curve bends upward like a cup); a negative one means it bends downward like a cap.

Try it: drag along the curve and watch the slope graph underneath.

Worked example 1

\( y = x^4 + \sin x \). Then \( \frac{dy}{dx} = 4x^3 + \cos x \) and \( \frac{d^2y}{dx^2} = 12x^2 - \sin x \).

Worked example 2: product and chain together

\( y = e^x\sin x \).

  1. \( y_1 = e^x\sin x + e^x\cos x = e^x(\sin x + \cos x) \).
  2. \( y_2 = e^x(\sin x + \cos x) + e^x(\cos x - \sin x) = 2e^x\cos x \).

Worked example 3: a log

\( y = x\log x \), \( x \gt 0 \). \( y_1 = \log x + 1 \), and \( y_2 = \frac{1}{x} \).

Proving relations between y, y₁ and y₂

A common exam question: show that some y satisfies an equation involving its derivatives. Find \( y_1 \) and \( y_2 \), then substitute.

Worked example 4

If \( y = Ae^{2x} + Be^{-3x} \) (A, B constants), show \( y_2 + y_1 - 6y = 0 \).

  1. \( y_1 = 2Ae^{2x} - 3Be^{-3x} \), \( y_2 = 4Ae^{2x} + 9Be^{-3x} \).
  2. \( y_2 + y_1 - 6y = (4 + 2 - 6)Ae^{2x} + (9 - 3 - 6)Be^{-3x} = 0 \).

Worked example 5: clear the fraction first

If \( y = \tan^{-1} x \), show \( (1 + x^2)y_2 + 2xy_1 = 0 \).

  1. \( y_1 = \frac{1}{1 + x^2} \), so \( (1 + x^2)y_1 = 1 \).
  2. Differentiate this (product rule): \( 2x\,y_1 + (1 + x^2)y_2 = 0 \). Done.

Multiplying out the fraction before differentiating again keeps the algebra short.

Worked example 6: a cosine wave

If \( y = 4\cos 3x \), then \( y_1 = -12\sin 3x \), \( y_2 = -36\cos 3x = -9y \). So \( y_2 + 9y = 0 \): the shape of every vibration, from a guitar string to a spring.

Guess first: second derivative in parametric form

For \( x = t^2 \), \( y = t^3 \) we found \( \frac{dy}{dx} = \frac{3t}{2} \). Guess: is \( \frac{d^2y}{dx^2} = \frac{d^2y/dt^2}{d^2x/dt^2} = \frac{6t}{2} = 3t \)?

See what happens
No. \( \frac{d^2y}{dx^2} \) means "differentiate \( \frac{dy}{dx} \) with respect to x". But \( \frac{dy}{dx} = \frac{3t}{2} \) is in terms of t, so use the chain rule once more: \( \frac{d^2y}{dx^2} = \frac{d}{dt}\left( \frac{3t}{2} \right) \div \frac{dx}{dt} = \frac{3}{2} \div 2t = \frac{3}{4t} \). Check: here \( y = x^{3/2} \) (for \( t \gt 0 \)), and \( \frac{d^2}{dx^2}x^{3/2} = \frac{3}{4}x^{-1/2} = \frac{3}{4t} \). Dividing the two second derivatives is a classic JEE trap.

Don't mix these up

  • \( \frac{d^2y}{dx^2} \) (differentiate twice) is not \( \left( \frac{dy}{dx} \right)^2 \) (square the first derivative).
  • \( y_2 \) means the second derivative, not y squared or "y at 2".

Rolle's theorem and the mean value theorem

Not in the current textbook, but JEE asks it: older editions ended this chapter with two theorems that use both continuity and differentiability. Let f be continuous on \( [a, b] \) and differentiable on \( (a, b) \).

  • Rolle's theorem: if also \( f(a) = f(b) \), there is at least one c in \( (a, b) \) with \( f'(c) = 0 \). A road that starts and ends at the same height must be flat somewhere in between.
  • Mean value theorem (Lagrange): there is at least one c in \( (a, b) \) with \( f'(c) = \dfrac{f(b) - f(a)}{b - a} \). Somewhere, the tangent is parallel to the chord joining the ends. If you drive 120 km in 2 hours, at some instant your speedometer read exactly 60 km/h.

Example: for \( f(x) = x^2 \) on \( [1, 3] \), the chord slope is \( \frac{9 - 1}{2} = 4 \), and \( f'(c) = 2c = 4 \) at \( c = 2 \), which is inside. Both conditions matter: \( |x| \) on \( [-1, 1] \) has \( f(-1) = f(1) \), but no point with slope 0, because it is not differentiable at 0.

Try it: find the parallel tangent yourself, then move the ends of the interval.

Try it. Find \( \frac{d^2y}{dx^2} \): (a) \( y = x^{10} \), (b) \( y = \log(\cos x) \), (c) \( y = |x|^3 \) (hint: \( y_1 = 3x|x| \)).

Answer
(a) \( 90x^8 \). (b) \( y_1 = -\tan x \), \( y_2 = -\sec^2 x \). (c) \( y_1 = 3x|x| \) is \( 3x^2 \) for \( x \ge 0 \) and \( -3x^2 \) for \( x \lt 0 \); differentiating gives \( y_2 = 6|x| \), which exists for every real x (at 0 both sides give 0).

Words to know

Second order derivative
\( \frac{d^2y}{dx^2} \): the derivative of the derivative.
\( f''(x), y'', y_2, D^2y \)
Other ways of writing the second derivative.
\( y_1 \)
The first derivative \( \frac{dy}{dx} \).
Higher order derivatives
Third, fourth and later derivatives, found by differentiating again and again.
Rolle's theorem
Continuous on [a, b], differentiable on (a, b), \( f(a) = f(b) \): somewhere \( f'(c) = 0 \).
Mean value theorem
Same conditions without \( f(a) = f(b) \): somewhere the slope equals the average slope.

If \( y = \sin 2x \), what is \( y_2 \)?

  1. \( -\sin 2x \)
  2. \( -4\sin 2x \)
  3. \( 2\cos 2x \)

If \( y = e^{5x} \), which relation holds?

  1. \( y_2 = 25y \)
  2. \( y_2 = 5y \)
  3. \( y_2 = 0 \)

Why does Rolle's theorem fail for \( f(x) = |x| \) on \( [-1, 1] \), even though \( f(-1) = f(1) \)?

  1. It is not continuous on \( [-1, 1] \)
  2. It is not differentiable at 0
  3. \( f(-1) \ne f(1) \)