# Is odd continuous function differentiable at $x=0$?

Suppose that $f(x)$ is continuous and odd: $f(-x) = - f(x)$. Does it have a derivative at $x=0$?

Here is what I got so far: First we calculate $f(0)$ using $f(-0) = -f(0)$, from which $f(0) = 0$. Then we calculate $f'(0)$ as follows: $$f'(0) = \lim_{x\to0}\frac{f(x)-f(0)}{x-0} = \lim_{x\to0}\frac{f(x)}{x}\,.$$ But the limit from the left is equal to the limit from the right: $$\lim_{x\to0^-}\frac{f(x)}{x} =\lim_{x\to0^+}\frac{f(-x)}{-x} =\lim_{x\to0^+}\frac{-f(x)}{-x} =\lim_{x\to0^+}\frac{f(x)}{x}\,,$$ which means that as long as the limit from the right exists, the function is differentiable at $x=0$. The limit is of the type $\frac{0}{0}$, since both $x$ and $f(x)$ goes zero at $x=0$. However, since $f(x)$ is continuous and $f(0)=0$, then in the vicinity of $x=0$, it must have a well defined value and the limit should exist. However, I didn't figure out how to finish the proof.

I've been trying to construct counter examples. A simple example is $f(x) = x^2 \sin \frac{1}{x}$, which is continuous (we define $f(0)=0$) and odd, with the derivative $f(x) = 2x\sin \frac{1}{x} - \cos \frac{1}{x}$, which oscillates between -1 and 1 around $x=0$. But at $x=0$, the derivative should be equal to zero, because $\frac{f(x)}{x} = x \sin \frac{1}{x}$ which goes to zero. So the derivative does exist at $x=0$ here.

-
$f(x) = x \sin \frac{1}{x^2}$ –  N. S. Jan 16 '13 at 6:44
N.S., you are right! $\frac{f(x)}{x} = \sin\frac{1}{x^2}$ which oscillates between -1 and 1 and so the limit does not exist. So this function is not differentiable at $x=0$. Thanks! –  Ondřej Čertík Jan 16 '13 at 6:47
@N.S.: You should have converted your comment to an actual answer. It certainly deserves upvotes. –  Haskell Curry Jan 16 '13 at 8:13
@N.S. Please do, I didn't want to put your solution into answers myself. –  Ondřej Čertík Jan 16 '13 at 16:28
@OndřejČertík Done :) –  N. S. Jan 16 '13 at 18:06

## 3 Answers

You can consider the function $f(x)=x^{1/3}$.

-

What you can say about
$f(x)= \begin{cases} \sqrt{x}, & x>0, \\ 0,& x=0, \\ -\sqrt{-x}, & x<0. \end{cases}$

-

You were almost there:

$$f(x)=x \sin(\frac{1}{x^2})$$

-