Differentiability
Recall prompts
Section titled “Recall prompts”Attempt these from memory before reading.
- Define the derivative as a limit. What kind of limit is it?
- State the mean value theorem. What are its hypotheses, and which one is load-bearing?
- Is every continuous function differentiable? Is every differentiable function continuous?
- Can a derivative be discontinuous?
- State Taylor’s theorem with the Lagrange form of the remainder.
Check your answers against the text. Prompt 4 is the one most people answer wrongly, and Darboux’s theorem is the reason the right answer is surprising.
Motivation: the derivative is a linear map, not a slope
Section titled “Motivation: the derivative is a linear map, not a slope”“Slope of the tangent line” is how differentiation is introduced, and it is a useful lie. The honest definition is:
is differentiable at if there is a number with .
That is: is differentiable at exactly when it can be approximated near by an affine function, with error smaller than linear. The number is the slope of that affine approximation.
Reading it this way does three things the slope picture cannot:
- It generalises to , where the derivative is a linear map (the Jacobian) and there is no single slope.
- It makes the mean value theorem obvious: if the function is affine on average, some point must have the affine slope.
- It explains why differentiability is stronger than continuity. Continuity says ; differentiability says the difference is linear in . Linear is much stronger.
The counterexamples on this page are the reason the distinction has to be made carefully rather than assumed.
5.1 The Derivative
Section titled “5.1 The Derivative”Definition. is differentiable at if the limit
Exists (as a finite real number).
Proposition 5.1. If is differentiable at Then is continuous at .
Proof. .
The converse is false: is continuous at but not differentiable at .
5.2 Differentiation Rules
Section titled “5.2 Differentiation Rules”Theorem 5.1. If and are differentiable at Then:
- (if )
- (Chain Rule)
5.3 Mean Value Theorem
Section titled “5.3 Mean Value Theorem”Theorem 5.2 (Rolle’s Theorem). If is continuous on Differentiable On And Then there exists such that .
Proof. By the Extreme Value Theorem, attains its maximum and minimum on . If Then is constant and for all . Otherwise, at least one Of or is attained at some (since ). By Fermat’s theorem, .
Theorem 5.3 (Mean Value Theorem). If is continuous on and Differentiable on Then there exists such that
Proof. Define . Then and satisfies the Hypotheses of Rolle’s theorem. So for some Which gives the result.
Corollary 5.4. If for all Then is constant on .
Corollary 5.5. If for all Then is strictly increasing on .
Theorem 5.3a (Cauchy’s Mean Value Theorem). If are continuous on and differentiable on Then there exists such that
Proof. Define . Then So by Rolle’s Theorem, for some Which gives the result.
Remark. When Cauchy’s MVT reduces to the standard MVT. Cauchy’s MVT is the key Ingredient in the …/1-number-and-algebra/3_proof-and-logic of L’Hôpital’s rule.
Corollary 5.6. If is differentiable on and for all Then is Lipschitz continuous with constant : for all .
Proof. Apply the MVT to on the interval between and .
5.4 Taylor’s Theorem
Section titled “5.4 Taylor’s Theorem”Theorem 5.6 (Taylor’s Theorem with Lagrange Remainder). If is -times differentiable on An open interval containing Then for each in that interval:
Where the remainder is
For some between and .
Proof. Fix and define
Then and . By the generalized Rolle’s theorem (or direct computation Using the Cauchy mean value theorem), there exists between and with . Computing:
Setting yields the result after comparing with the integral form. A Cleaner approach uses the standard MVT applied to on .
5.5 L’Hôpital’s Rule
Section titled “5.5 L’Hôpital’s Rule”Theorem 5.7 (L’Hôpital’s Rule, case). Suppose and are differentiable on An open interval containing (except possibly at itself), near And . If exists (as a finite Number or ), then .
Proof. Extend and continuously to by setting . For By Cauchy’s Mean Value Theorem, there exists strictly between and such that
I.e., . As We have (since is trapped between and ). Therefore .
Theorem 5.7b (L’Hôpital’s Rule, case). Suppose and are Differentiable on (except possibly at ), near And . If exists, Then .
Proof (sketch). Fix . For near with By Cauchy’s MVT:
For some between and . Since for near We have:
Since By fixing and letting The fractions and tend to So the second factor tends to . The first factor tends to by Cauchy’s MVT. Hence .
Worked Example: Compute $\lim_{x \to 0} \frac{e^x - 1 - x}{x^2}$
Solution. Both numerator and denominator approach as . Applying L’Hôpital’s rule:
This is still So apply L’Hôpital again:
5.6 Darboux’s Theorem
Section titled “5.6 Darboux’s Theorem”Theorem 5.8 (Darboux’s Theorem). If is differentiable on Then has the Intermediate value property: for any between and There exists With .
Remark. This means derivatives satisfy the intermediate value property even though they need not be continuous. For example, (with ) is differentiable everywhere, But is not continuous at .
Proof. Assume without loss of generality that . Define . Then is differentiable on with
Since There exists with (otherwise For near Contradicting ). Similarly, since There exists with .
Therefore attains its minimum at some . By Fermat’s theorem on interior extrema, So .
Worked Example: Apply Darboux's theorem to $f(x) = x^2 \sin(1/x)$ ($f(0) = 0$)
Solution. For : . At : .
So . For any The term oscillates between and on So takes all values in infinitely often on .
But Darboux’s theorem says has the intermediate value property. Indeed, is not continuous at (it oscillates wildly), yet it still satisfies the IVP. This shows that derivatives can be Highly discontinuous while retaining the intermediate value property.
5.7 Worked Examples
Section titled “5.7 Worked Examples”Worked Example. Compute the third-order Taylor polynomial of about .
, , , . So
The remainder is for some between and .
Worked Example: Approximate $\sin(0.1)$ with error less than $10^{-10}$
Solution. For about : and the Taylor Polynomial of degree has the form (odd terms only).
The Lagrange remainder is (since for all ).
We need . Testing: for . For : .
So .
The error is at most .
Worked Example: Find the Maclaurin series for $\ln(1 + x)$ and its radius of convergence
Solution. For : , , for . So .
By the ratio test: . The series converges for and diverges for . At we get the alternating Harmonic series (converges to ). At we get the negative harmonic series (diverges).
The radius of convergence is and the interval of convergence is .
Worked Example: Compute the Taylor expansion of $\cos x$ about $a = \pi/3$ with remainder bound
Solution. Compute derivatives: , , , . Evaluated at :
, , , .
The third-degree Taylor polynomial is:
The remainder satisfies (since ).
For example, at : .
Intuition
Section titled “Intuition”The derivative is most deeply understood not as a “slope” but as the best linear approximation to a function at a point. Near x=a, a differentiable function f(x) is well approximated by the tangent line f(a) + f’(a)(x-a). The error in this approximation vanishes faster than |x-a| as x approaches a. This is why differentiation is local: the derivative captures the linear part of how f behaves near a, discarding higher-order curvature.
This perspective explains why the chain rule works as it does. If f is locally linear near g(x) and g is locally linear near a, then their composition is locally linear near a, and the slopes multiply. It also explains why not every continuous function is differentiable: f(x)=|x| is continuous at 0 but has no single linear approximation there — the left and right slopes disagree. The Mean Value Theorem says that the instantaneous linear approximation (the derivative) must at some point match the average rate of change over an interval. Taylor’s theorem extends this: the derivative is the first-order term in a polynomial approximation, and the remainder controls how well that approximation works.
Counterexamples worth knowing by name
Section titled “Counterexamples worth knowing by name”| Function | Continuous? | Differentiable? | What it shows |
|---|---|---|---|
| at | yes | no | a corner: left and right derivatives differ |
| , | yes | yes at 0, | the derivative exists but is unbounded near 0 |
| Weierstrass | yes everywhere | nowhere | continuity does not imply differentiability, on an uncountable set |
| at | yes | no | a vertical tangent is not a derivative |
| continuous only at 0 | differentiable at 0 with | differentiability can hold at an isolated point of continuity |
Darboux’s theorem says that even though derivatives need not be continuous, they satisfy the intermediate value property: if then for some between and . So a derivative cannot jump. It can, however, be discontinuous — is the standard example — which is why derivatives form a strictly smaller class than continuous functions, and why “the derivative of a differentiable function is continuous” is false.
Why Weierstrass matters beyond the puzzle. It shows that continuity alone gives no control over oscillation at the infinitesimal scale. Any argument that assumes a continuous function has a derivative “somewhere” on an interval needs more hypotheses — and the mean value theorem supplies exactly that.
Interleaving problems
Section titled “Interleaving problems”Mix these with material from Sequences and Limits, Continuity and Riemann Integration.
- (Limits.) Show is not differentiable at , by computing the left and right limits of the difference quotient.
- (Continuity.) Show that if is differentiable on with , there is a point where — this is Rolle’s theorem, and the MVT is its generalisation.
- (Integration.) Use the MVT to show that if on then is increasing, and deduce that a function with everywhere is constant.
- (Taylor.) Show that and use it to compute .
- (Darboux.) Show that for , has the intermediate value property but is discontinuous at .
5.8a Geometric Meaning of the MVT
Section titled “5.8a Geometric Meaning of the MVT”The Mean Value Theorem says: for a smooth curve connecting two points, there is a point on the curve where the tangent line is parallel to the chord (secant line) connecting the endpoints.
More precisely, if is continuous on and differentiable on , then there exists with
Physical interpretation: If you drive 100 miles in 2 hours, your average speed is 50 mph. The MVT says that at some instant, your speedometer must have read exactly 50 mph.
Why this fails without differentiability: For on , , so the average rate of change is 0. But is never 0: it equals for and for . The MVT fails because is not differentiable at , where the chord from to is horizontal, but no tangent line is horizontal.
5.8b Worked Example: MVT Inequality
Section titled “5.8b Worked Example: MVT Inequality”Problem. Prove that for all .
Solution
Apply the MVT to on the interval between and . There exists between and such that
Taking absolute values:
since for all .
This inequality implies that is Lipschitz continuous with constant 1, hence uniformly continuous on . The same argument works for .
5.9 Common Pitfalls
Section titled “5.9 Common Pitfalls”- L’Hopital’s rule only applies to indeterminate forms or . Applying it to forms like or will give incorrect results. Always verify the indeterminate form before applying the rule.
- L’Hopital’s rule requires that the limit of exists. If oscillates (e.g., , , then which oscillates), the original limit may still exist. In such cases, use algebraic manipulation instead.
- The MVT requires continuity on and differentiability on . If is not differentiable at some points, the MVT conclusion may fail.
- Taylor’s theorem gives the remainder for a specific between and . To bound the error, use where .
Cross-References
Section titled “Cross-References”- Continuity: Differentiability implies continuity, and the mean value theorem connects local derivative behaviour to global function properties.
- Riemann Integration: The fundamental theorem of calculus links differentiation and integration, with the Riemann integral defined via limits of Riemann sums.
- Lebesgue Integration: Lebesgue integration generalises the Riemann integral and handles a broader class of functions with discontinuities.
- Classical Mechanics
- Electromagnetism