Is a bounded and continuous function uniformly continuous?

$f\colon(-1,1)\rightarrow \mathbb{R}$ is bounded and continuous does it mean that $f$ is uniformly continuous?

Well, $f(x)=x\sin(1/x)$ does the job for counterexample? Please help!

-
– Martin Sleziak Feb 9 at 16:24

You're close: $$\sin\frac{1}{x+1}$$ is a counterexample to the statement.

-

For continuity to lead to uniform continuity, domain has to be compact, and as you can see the domain is not compact here. Also, rightly $f(x)=\sin(\frac{1}{x+1})$ serves as a counterexample or even $\sin(e^x)$ for that matter.

-
$\sin(e^x)$ is uniformly continuous on $(-1,1)$. – commenter Oct 25 '12 at 11:17
Yes it is. Thanks. Don't know what I was thinking. – Vishesh Oct 25 '12 at 11:18

$\sin(x^2)$ is also a nice example and it's happening because it's not periodic.

-
This function is continuous on $[-1,1]$, so it is uniformly continuous there. A fortiori on $(-1,1)$. – 1015 Apr 25 '13 at 16:37
Over the real line, this is, not on any bounded interval. – Pedro Tamaroff Apr 25 '13 at 16:39