• Foundation
  • About 20 min
  • 5 practice questions

Differentiability and the chain rule

Decide whether a function is differentiable at a point using left-hand and right-hand derivatives, prove that differentiability implies continuity, and differentiate composite functions with the chain rule.

If something looks wrong, please tell us.

By the end of this lesson you can

  • Compute left-hand and right-hand derivatives and decide differentiability at a point.
  • Prove that a differentiable function is continuous, and give a continuous function that is not differentiable.
  • Differentiate composite functions such as sin(x² + 1) and (3x² − 5)⁴ with the chain rule.

Continuity says the graph has no break; differentiability says more: the graph has no sharp corner, so it has a well-defined tangent at each point. Most of this chapter is about computing derivatives, so we first make sure we know when a derivative exists, and then learn the chain rule, the single most-used rule in calculus.

Differentiable at a point

The derivative of f at c is f′(c) = lim (h→0) [f(c + h) − f(c)]/h, provided the limit exists. Taking h → 0⁻ gives the left-hand derivative (LHD) and h → 0⁺ the right-hand derivative (RHD). f is differentiable at c if both are finite and equal.

f is differentiable at c ⇔ LHD = RHD (both finite). Every differentiable function is continuous, but a continuous function need not be differentiable.

— Key facts

Differentiable implies continuous

Proof. Suppose f′(c) exists. For x ≠ c, f(x) − f(c) = {[f(x) − f(c)]/(x − c)} × (x − c). Taking limits as x → c: lim [f(x) − f(c)] = f′(c) × 0 = 0. So lim (x→c) f(x) = f(c), which is continuity at c.

The converse is false. Take f(x) = |x − 1| at c = 1. It is continuous there (both one-sided limits are 0 = f(1)). RHD = lim (h→0⁺) [|h| − 0]/h = h/h = 1. LHD = lim (h→0⁻) |h|/h = −h/h = −1. Since LHD ≠ RHD, f is not differentiable at 1: the graph has a corner there.

Continuity versus differentiability

  • Continuous
    • No break or jump in the graph
    • LHL = RHL = f(c)
    • Example: |x − 1| at x = 1
  • Differentiable
    • No break and no sharp corner
    • LHD = RHD, finite
    • Always continuous as well

Worked example 1. f(x) = x² for x ≤ 1 and f(x) = 2x − 1 for x > 1. Is f differentiable at 1? Working: f(1) = 1, and both pieces tend to 1, so f is continuous at 1. LHD = lim (h→0⁻) [(1 + h)² − 1]/h = lim (2h + h²)/h = lim (2 + h) = 2. RHD = lim (h→0⁺) [2(1 + h) − 1 − 1]/h = lim 2h/h = 2. LHD = RHD = 2, so f is differentiable at 1 and f′(1) = 2: the two pieces join smoothly.

Derivatives you already know

Standard derivatives from Class 11 (with the sum, product and quotient rules)
f(x)f′(x)
xⁿn xⁿ⁻¹
sin xcos x
cos x−sin x
tan xsec²x
sec xsec x tan x
cosec x−cosec x cot x
cot x−cosec²x

The chain rule

If y = f(t) and t = g(x), so that y = f(g(x)) is a composite, then dy/dx = (dy/dt) × (dt/dx), provided both derivatives exist. In words: differentiate the outer function (leaving the inside alone), then multiply by the derivative of the inside. For three layers, keep multiplying: dy/dx = (dy/du)(du/dv)(dv/dx).

Using the chain rule on sin(x² + 1)

  1. Name the inside t = x² + 1
  2. Differentiate the outside d/dt (sin t) = cos t = cos(x² + 1)
  3. Differentiate the inside dt/dx = 2x
  4. Multiply dy/dx = 2x cos(x² + 1)

Worked example 2. y = (3x² − 5)⁴. Working: outside u⁴ with u = 3x² − 5. dy/dx = 4(3x² − 5)³ × 6x = 24x(3x² − 5)³.

Worked example 3. y = cos(√x), x > 0. Working: dy/dx = −sin(√x) × 1/(2√x) = −sin(√x)/(2√x).

Worked example 4 (three layers). y = tan(sin 2x). Working: outer tan, middle sin, inner 2x. dy/dx = sec²(sin 2x) × cos 2x × 2 = 2 cos 2x sec²(sin 2x).

Worked example 5 (chain rule with the product rule). y = x² sin(3x). Working: product rule first, then the chain rule for sin 3x: dy/dx = 2x sin 3x + x² × 3 cos 3x = 2x sin 3x + 3x² cos 3x.

Key takeaways: differentiable at c means LHD = RHD; corners such as |x − 1| at 1 are continuous but not differentiable. Differentiability implies continuity. The chain rule differentiates from the outside in and multiplies the results.

Check your understanding

  1. 1. At x = 0, the function f(x) = |x| is:

    1. differentiable but not continuous
    2. neither continuous nor differentiable
    3. continuous and differentiable
    4. continuous but not differentiable
    Show answer

    Answer: D. Both one-sided limits are 0 = f(0), so f is continuous. RHD = 1 and LHD = −1 differ, so f is not differentiable at 0.

  2. 2. What is d/dx (2x + 3)⁵?

    1. 10(2x + 3)⁴
    2. 5(2x + 3)⁴
    3. (2x + 3)⁴
    4. 10(2x + 3)⁵
    Show answer

    Answer: A. Chain rule: 5(2x + 3)⁴ × d/dx(2x + 3) = 5(2x + 3)⁴ × 2 = 10(2x + 3)⁴.

  3. 3. What is d/dx sin(x³)?

    1. cos(x³)
    2. 3x² cos(x³)
    3. 3x² cos(3x²)
    4. −3x² cos(x³)
    Show answer

    Answer: B. Outer sin gives cos(x³); the inside x³ has derivative 3x². Multiply: 3x² cos(x³).

  4. 4. f(x) = ax + b for x < 1 and f(x) = x² for x ≥ 1 is differentiable at x = 1. What are a and b?

    1. a = 1, b = 0
    2. a = 2, b = 1
    3. a = 2, b = −1
    4. a = −2, b = 3
    Show answer

    Answer: C. Differentiable at 1 needs matching slopes: LHD = a and RHD = 2(1) = 2, so a = 2. It must also be continuous: a + b = 1, so b = −1.

  5. 5. Assertion (A): If f is differentiable at x = c, then f is continuous at x = c.
    Reason (R): The function |x| is continuous at 0 but not differentiable there.

    1. Both A and R are true, and R is the correct explanation of A
    2. Both A and R are true, but R is not the correct explanation of A
    3. A is true but R is false
    4. A is false but R is true
    Show answer

    Answer: B. A is a proved theorem and R is a true fact. But R is about the converse (continuity does not imply differentiability); it does not explain why differentiability implies continuity.

Privacy · Terms · Refunds · Delivery