<s>[INST] How can I calculate $\lim_{x \to 0} \log(\cos(x))/\log(\cos(3x))$ without l'Hopital? How can I calculate the following limit without using, as Wolfram Alpha does, without using l'Hôpital?
$$
\lim_{x\to 0}\frac{\log\cos x}{\log\cos 3x}
$$
 [/INST] Another way is via the approximations $\cos(x) = 1-\frac{x^2}{2}+O(x^4)$ and $\log(1+x) = x+O(x^2)$:
$$\begin{align}\frac{\log(\cos(x))}{\log(\cos(3x))} &= \frac{\log(1-\frac{x^2}{2}+O(x^4))}{\log(1-\frac{(3x)^2}{2}+O(x^4))} \\
&= \frac{-\frac{x^2}{2}+O(x^4)}{-\frac{(3x)^2}{2}+O(x^4)} \\
&= \frac{-\frac{x^2}{2}}{-\frac{x^2}{2}}\frac{1+O(x^2)}{9+O(x^2)} \\
&= \frac{1}{9}+O(x^2)\end{align}$$
And now the limit as $x\rightarrow0$ is trivial.
</s>