If $f(x)$ is a differentiable function which is not $0$ everywhere and has the property that around any interval around $0$, $f$ is neither fully positive or negative. Then it can be proven that $f(0)=0$.
An example of such a function is
$$\begin{cases}x^2\sin({1\over x}) & \text{ for }x\neq 0,\\ 0 &\text{ for }x=0.\end{cases}$$
All such functions I have seen so far satisfy this.
Q: Is it true that the derivative of such a function cannot be continuous or is there a counter-example?
I feel that such a function exists and have tried a few examples but have been unable to find one.
Best Answer
$f(x)=x^3 \sin\left(\frac{1}{x}\right)$ has a continuous derivative and respect your criteria.