# Does the following limit exist??

Write $$h(x) = \begin{cases} 0, x \neq 0 \\ 1, x = 0 \end{cases}$$

$$g(x) = \begin{cases} x \sin \left( \frac{1}{x} \right), x \neq 0 \\ 0 , x = 0 \end{cases}$$

Claim is $\lim_{x \to 0} h \circ g$ does not exist.

However, I believe the limit is zero since: Notice if $x \neq 0$, $h(x) = 0$ is zero no matter what $f$ is. Also, if $x = 0$, then $g=0$ and so $h(g(0)) = h(0) = 1$ and so $\lim_{x \to 0} h(g(x)) = 0$. Am I missing something here?

• You might think again. Can you find a sequence $x_k$ that satisfies $x_k\rightarrow 0$ but $\lim_{k\rightarrow\infty}h(x_k)=1$? Can you find another sequence that satisfies $x_k\rightarrow 0$ but $\lim_{k\rightarrow\infty}h(x_k)=0$? If so, the limit $\lim_{x\rightarrow 0} h(g(x))$ does not exist. – Michael Nov 8 '16 at 15:47
• I thought under the formal definition of the limit, we are interested in increasing small values of epsilon close to the limit, and for these g is always non zero, therefore h is always zero for any non-zero epsilon - so I think the limit is zero – Cato Nov 8 '16 at 15:48
• Why do you say "for these $g$ is always nonzero"? @AndrewDeighton – Michael Nov 8 '16 at 15:49
• Notice that if $g(x) = 0$, then $h(g(x)) = 0$. – Omnomnomnom Nov 8 '16 at 15:50
• I did think again - for increasing small $\epsilon$ there has to exist a smaller value with $1 / \epsilon = n\pi$ - making g zero and at that point $h \circ g = 1$ So there is no limit, it flips between 0 and 1 with increasing frequency – Cato Nov 8 '16 at 15:59

HINT:

The composite function is given by

$$h(g(x))=\begin{cases}1&,g(x)=0\\\\0&,g(x)\ne 0\end{cases}$$

So, $h$ can equal only $1$ or $0$.

Note that when $\displaystyle x_n=\frac1{n\pi}$, we have $g(x_n)=0$ and $h(g(x_n))=1$.

Then, take $\epsilon=1$ and show that for all $\delta>0$, there exists an $0<|x_n|<\delta$ such that

$$|h(g(x_n))-0|\ge \epsilon=1$$

and another number $x\ne x_n$ with $0<|x|<\delta$ such that

$$|h(g(x))-1|\ge \epsilon=1$$

• Would the cowardly down voter care to comment? – Mark Viola Nov 9 '16 at 15:29
• I'm guessing the downvoter is Joss, as his/her answer reaches an unusual conclusion that is different from yours (and the number of up/downvotes on his/her answer has not been changed while yours was). There was another answerer who also said the limit was 0, but that person realized the mistake and deleted after my comments. – Michael Nov 10 '16 at 1:01