Inverse Function Theroem in $R^1$ I have a question about the inverse function theorem in R1.
The version of the theorem that I know says:
Let $y = f(x)$ be a continuously differentiable function defined on an open interval $I$
 in $R$. If $f'(x_0) \neq 0$ at some point $x_0$ in $I$, then there exists a function $f^{-1}(x) $ defined on some neighbourhood $N$ of $f(x_0)$ such that $f(f^{-1}(y)) = y$ for each $y \in N$. 
I want to relax the hypotheses of the theorem a little bit, so the following questions came to my mind.
Instead of $f(x)$ being continuously differentiable on the whole interval $I$, if I only know that $f(x)$ is differentiable at the point $x_0$ and $f'(x_0) \neq 0$, would I still be able to find an inverse function $f^{-1}(x)$? In other words, can I guarantee the existence of an (local) inverse function just from the differentiability of the function at the single point and its derivative there not equal to zero?
 A: Edit: Note that it is the same function given by Antonio Vargas in a previous comment
Consider the function $$f(x)=\left\{\begin{array}{lcl} x+2x^2\sin \frac{1}{x} & \text{if} & x\neq 0 \\ 0 & \text{if} & x= 0 \end{array} \right.$$ This function is differentiable at any point of $\mathbb{R}$ (but not continuously differentiable at $x=0$) and $f'(0)=1.$ The derivative of $f$ is given by 
$$f(x)=\left\{\begin{array}{lcl} 1+4x\sin \frac{1}{x} -2\cos \frac{1}{x} & \text{if} & x\neq 0 \\ 0 & \text{if} & x= 0 \end{array} \right.$$
Since, in any neigbourhood of $x=0,$ $f'$ takes positive and negative values, we have that, in any neigbourhood of $x=0,$ $f$ is increasing and decreasing somewhere. So $f$ is not bijective in any neighbourhood of $x=0$ and thus it cannot have a local inverse.
A: Let me point out one place in the proof of the inverse function theorem where you use the fact that $f$ has a continuous first derivative on an interval containing $x_0$ rather than just at $x_o$. The proof, in Rudin's Principles of Mathematical Analysis defines a function $\psi(x)=x+A^{-1}(y-f(x))$ so that $f$'s injectivity will be implied by this function having a fixed point. He relies on the contraction principle which states that a function, defined as a self map of a complete metric space, has a fixed point if, for $c<1$, $\psi$ satisfies 
$$d(\psi(x),\psi(y))\le c\cdot d(x,y). $$ An interval, call it I, containing $x_0$ will be a metric space relative to the ambient $\mathbb{R}^n$. I think we would not want to allow the trivial one point metric space here. Rudin does not mention this in the contraction principle theorem because a one point metric space will trivially satisfy the principle for any function on it (the theorem is about fixed points). 
