Example
Is \(x\sin\left(\frac{1}{x}\right)\) is continuous at \(x=0\)?
Proof
We first observe that the function \(x\sin\left(\frac{1}{x}\right)\) is not defined at \(x=0\). Define
$$
\begin{align}
f(x) =
\begin{cases}
x \sin\left(\dfrac{1}{x}\right), & \text{if } x \neq 0, \\
0, & \text{if } x = 0.
\end{cases}
\end{align}
$$
We will show that \(f\) is continuous at \(x = 0\). Let \(\epsilon > 0\) be given and choose \(\delta = \epsilon\). Now suppose that
$$
\begin{align}
\left| x - 0 \right| = |x| < \delta
\end{align}
$$
Since \(\left|\sin\left(\frac{1}{x}\right)\right| \leq 1\) for all \(x \neq 0\), then
$$
\begin{align*}
\left| f(x) - f(0) \right| &= \left| x\sin\left(\frac{1}{x}\right) - 0 \right| \\
&= |x| \left|\sin\left(\frac{1}{x}\right)\right| \\
&\leq |x| \\
&< \epsilon.
\end{align*}
$$
References
- Introduction to Analysis, An, 4th edition by William Wade
- Lecture Notes by Professor Chun Kit Lai