Show a limit of piecewise function does not exist as x tends to 0 So I am given a function, f(x), as follows:
f(x)=sin(1/x) if $0<x\leq1$ and f(x)=4 if x=0.  
clearly this is an example of a function integrable on [0,1] but it is discontinuous at x=0.  How would you show that the limit of the unction does not exist as x tends to 0?
So I know that a limit exists if the right and left limits are the same but it does not work in the case of sin(1/x) in which x=0 leads to an undefined function.  How might I do that rigorously.  I already looked at the definition of continuous functions and tried using that but does that mean I have to do it twice for each function?
 A: If we draw a picture, everything is clear: near $0$, $\sin(1/x)$ wiggles desperately between $-1$ and $1$.
If we want to be formal, we can use the $\epsilon-\delta$ definition of limit. Suppose that the limit exists and is equal to $a$. Then for every $\epsilon\gt 0$ there is a $\delta$ such that if $0\lt |x-0|\lt \delta$ then $|\sin(1/x)-a|\lt \epsilon$.
Let $\epsilon=\frac{1}{10}$, and suppose that $\delta$ "works" for this $\epsilon$. Note that there exists $x$ such that $|x-0|\lt \delta$ and $\sin(1/x)=0$. Just pick $x=n\pi$ for large enough $n$. So $|0-a|\lt 1/10$.
Similarly, there exists $x$ such that $|x-0|\lt \delta$ and $\sin(1/x)=1$. Just pick $x=(2n+1/2)\pi$ for large enough $n$. Thus $|1-a|\lt 1/10$.
Now we have reached a contradiction. There is no $a$ such that simultaneously $|0-a|\lt 1/10$ and $|1-a|\lt 1/10$. If we want to be formal about proving this, we can use the Triangle Inequality.
A: If the limit exists then for all $x_n \rightarrow 0$ it must be that $f(x_n) \rightarrow c$
where $c$ is the limit. But for every number $r$ in $[-1,1]$ you can find a sequence $x_n$ such that $f(x_n) \rightarrow r$. Indeed if sin(y)=r. Then consider the sequence 
$x_n = \frac{1}{y+2\pi n}$ so that $x_n \rightarrow 0$ but $sin(\frac{1}{x_n})=r$
