Showing $x^2\sin \frac {1}{x}$ is surjective

continuityfunctionsreal-analysis

Show that the function $f:\mathbb R\rightarrow \mathbb R$ defined by $f(x)=x^2\sin \frac {1}{x}$ if $x\neq 0$ and $f(0)=0$ is surjective.

What I thought that if I could show that for every $n\in \mathbb N$ there is a $x \in \mathbb R$ such that $f(x)=n$ and there is a $y \in \mathbb R$ such that $f(y)=-n$ then since $f$ is continuous by IVT $f$ is surjective. But I couldn't find such $x$ and $y$.

Best Answer

You have that $\lim_{x\to +\infty} f(x) =\lim_{x\to +\infty} x\cdot x\sin (\frac 1x) =+\infty$ and in the same way $\lim_{x\to - \infty} f(x) =-\infty $, so by IVT you have thesis.