Let $f(x) = x^2 \sin (1/x^2),\,x\ne 0,$ and $ f(0)=0.$ Prove $f$ is differentiable on $\mathbb R$

Let $f(x) = x^2 \sin (1/x^2),\,x\ne 0,$ and $ f(0)=0.$ Prove $f$ is differentiable on $\mathbb R$

So $f'(x)=2x\sin 1/x^2 -\frac{2\cos 1/x^2}{x}$ when $x\ne 0$, but what about at $0$? My prof in the assignment solutions just says "$f'(0) = 0$." (though his solutions tend to be quite abbreviated). Am I missing something obvious? Is he skipping steps or can you go right from $f(0) = 0$ to $f'(0)=0$?


Solution 1:

Hint: We need to go back to the definition of the derivative. So we want to calculate $$\lim_{h\to 0}\frac{h^2\sin(1/h^2)-0}{h}.$$ There is some cancellation, and we need $$\lim_{h\to 0}h\sin(1/h^2).$$ Now use the fact that $|\sin t|\le 1$.

Remark: Examining the derivative when $x\ne 0$ will not do the job. It turns out that the derivative is not continuous at $0$, so its values near $0$ do not give information about its value at $0$.