Prove $\frac{x^2 - 3 \cos(x)}{1+ x^2\sin(\log|x|)} \rightarrow -3$ as $x \rightarrow 0$ I'm a student taking a real analysis course and I have been asked the very difficult question above. I only say it is difficult because I am at a loss as how to go about solving it. I am decently versed at using first principles so I have attempted it below, but it did not go well. I assume its more complicated than simply substituting $0$ for every $x$.
First fix $\epsilon > 0$ and find $\delta > 0$ such that.
$$0<|x-0|< \delta \implies \left| \frac{x^2 - 3 \cos(x)}{1+ x^2\sin(\log|x|) } +3\right|< \epsilon$$
$$0<|x|< \delta \implies \left| \frac{3x^2\sin(\log|x|) - 3\cos(x)+3}{x^2\sin(\log|x|)+1} \right|<\epsilon$$
Here's where my brain fizzles out. I'm assuming the rigorous definition of the first principles would yield the correct result, but there must be an easier way that is not directly visible to me. 
I'm new to real analysis so any tips or tricks to solving this beast would be much appreciated!
 A: Suppose $|x| <1$ Then we have that
$$\frac{|3x^2\sin(\log|x|)+3(1-\cos x)|}{|1+x^2\sin(\log|x|)|} \leq \frac{3x^2|\sin(\log|x|)| + 3|1-\cos x|}{|1+x^2\sin(\log|x|)|}$$
by triangle inequality. Optimizing the bottom we get that
$$x = e^{-\tan^{-1}\left(\frac{1}{2}\right)+k\pi}$$
for $k\in\Bbb{Z}$. The negative exponent with the smallest absolute value ($k=0$) will be the absolute min for the function for the function $1 + x^2\sin(
\log|x|)$ on $[-1,1]$ giving 
$$|1 + x^2\sin(\log|x|)| \geq 1-\frac{1}{\sqrt{3}}e^{-2\tan^{-1}\left(\frac{1}{2}\right)} > \frac{1}{2}$$ 
Then using $|\sin(\log|x|)| \leq 1$ and $1-\cos x \leq \frac{1}{2}x^2$ we get that 
$$\frac{3x^2|\sin(\log|x|)| + 3|1-\cos x|}{|1+x^2\sin(\log|x|)|}\leq 9x^2 < 9|x| < \epsilon$$
So let $\delta = \min\left (\frac{\epsilon}{9},1\right)$ and the proof follows.
A: The preferred approach is to use limit laws (as explained in other answers). However using the definition of limit is not difficult either.
Note that $$|1+x^2\sin\log|x||\geq 1-x^2|\sin\log|x||\geq 1-x^2$$ provided $x^2<1$. If $|x|<1/2$ then the above expression is not less than $3/4$.
Next we can see that $$\left|\frac{x^2-3\cos x} {1+x^2\sin \log|x|} +3\right|=\left|\frac{x^2(1+3\sin\log|x|)+3(1-\cos x)} {1+x^2\sin\log|x|}\right|$$ and if $|x|<1/2$ the above expression does not exceed $$\frac{4}{3}\left(4|x|+\frac{3x^2}{2}\right)$$ which does not exceed $$\frac{16|x|}{3}+2|x|=\frac{22|x|}{3}$$ and this is less than $\epsilon $ if $|x|<3\epsilon /22$. Thus you can choose $\delta =\min(1/2,3\epsilon /22)$.
A: We have $ |x^2 \sin ( \log |x|)| \le x^2,$ hence $x^2 \sin ( \log |x|) \to 0$ as $x \to 0.$
Thus $\frac{x^2 - 3 cos(x)}{1+ x^2 \sin (\log|x|)} \to \frac{0-3 \cdot 1}{1+0}=-3$ as $x \to 0.$
A: Note that the numerator tends to $-3$. On the other hand, the denominator $$1+x^2\sin(\log x) \to 1+ (\to 0) \times (\text{a finite number in [-1,1]}) = 1$$
