Let $f(x)=\left\{\begin{matrix}\frac{|x|}{x},&x≠0\\1,&x=0\end{matrix}\right.$ and $g(x)=\left\{\begin{matrix}x\sin(\frac{1}{x}),&x≠0\\1,&x = 0\end{matrix}\right.$
Then at the origin, which one of the following is true?
Answer & explanation
Correct answer: option 4
The correct answer is Option (2) → g(x) is continuous, but f(x) is not continuous
Given
$f(x)=\frac{|x|}{x},\; x\ne0 \;\; \text{and} \;\; f(0)=1$
$g(x)=x\sin\left(\frac{1}{x}\right),\; x\ne0 \;\; \text{and} \;\; g(0)=1$
Check continuity of $f(x)$ at $x=0$:
$\lim_{x\to0^{+}} f(x)=\lim_{x\to0^{+}} \frac{|x|}{x}=1$
$\lim_{x\to0^{-}} f(x)=\lim_{x\to0^{-}} \frac{|x|}{x}=-1$
Left and right limits are not equal, so limit does not exist.
Thus $f(x)$ is not continuous at $0$.
Check continuity of $g(x)$ at $0$:
$\lim_{x\to0} x\sin\left(\frac{1}{x}\right)=0$
But $g(0)=1$
So $\lim_{x\to0} g(x)\ne g(0)$
Thus $g(x)$ is also not continuous at $0$.
Correct option: Neither $f(x)$ nor $g(x)$ is continuous.