I want to find the limit of $$\frac{e^x + \frac1{e^x} - 2\cos x}{x\tan x}$$ as $x$ tends to $0$.
My attempt: The limit of $\frac{e^x + 1/e^x - 2cosx}{xtanx}$ should be the same as the limit of $\frac{2 - 2\cos x}{x\tan x}$, which can evaluated using the standard limits of $x/\sin x$ and $((1-\cos x)/x^2)$. But this gives me the answer as $1$, while the correct answer is $2$. I suspect the error is in writing it as $\frac{2 - 2cosx}{xtanx}$, but am unable to see why. Please help.
To give context - I can use only the basic limit laws for algebraic combinations of limits and some standard limits.