Given the function $\frac{(x^2-2)\sin(x)+2x\cos(x)}{x^3}$, I would like to find the limit as $x\to0$. The following is my approach:
$$\lim_{x \to 0} \frac{(x^2-2)\sin(x)+2x\cos(x)}{x^3}\\ \lim_{x \to 0} \frac{x^2\sin(x)}{x^3}-\frac{2\sin(x)}{x^3}+\frac{2x\cos x}{x^3}\\ \lim_{x \to 0} \frac{x^2}{x^2}\frac{\sin(x)}{x}-\frac{2}{x^2}\frac{\sin(x)}{x}+\frac{2}{x^2}\frac{\cos x}{1}$$
Hence, I theoretically obtain DNE as my answer. However, when I plotted the function, the limit is $\frac{1}{3}$. I would like to get some advice on how should I get around this problem?