[Math] Why is this proof of the chain rule incorrect

calculuschain rulederivativesproof-verification

enter image description here

I saw this proof of the chain rule but it says this is a flawed proof. Why? I guessed the reason it is wrong because you can't substitute $g(x+h)$ and $g(x)$ into in limit.

Best Answer

To expand on my comment, the fundamental issue is that $g(x+h) - g(x)$ may vanish in any neighbourhood around $h=0$. The issue of $g'(x)$ being $0$ (though certainly a mistake in the proof) is not that important, since this "proof" can be trivially modified so that the $g'(x)$ term stays on the right hand side. For example,

$$\frac{f(g(x+h))-f(g(x))}{h} = \frac{f(g(x+h))-f(g(x))}{g(x+h) - g(x)} \cdot \frac{g(x+h) - g(x)}{h} \ \ \ \ \ \ \ \ \ (1)$$

and let $h \to 0$ in the equation. The problem, again, is that we may have $g(x+h) = g(x)$ in every neighbourhood of $x$ for certain badly behaved functions (ex. $g(t) = t^2\sin \frac 1t$, $x=0$ ).

The trick (credit to Michael Spivak) is as follows. Define $$\sigma(h) = \begin{cases} f'(g(x)) & g(x+h) = g(x) \\ \ \frac{f(g(x+h))-f(g(x))}{g(x+h) - g(x)} & \text{otherwise} \end{cases}$$

and note that as $h \to 0$, this tends to $f'(g(x))$ without any division by zero problems. Now, substitute $\sigma(h)$ for the first fraction on the RHS in $(1)$ and let $h \to 0$. The substitution is justified because the equality in the modified version of $(1)$ will always hold (can you see why?).

Related Question