<s>[INST] Evaluating $\lim_{x\to0}\left(\frac{1+x2^x}{1+x3^x}\right)^\frac1{x^2}$ Find the following limit
$$
\lim_{x\to0}\left(\frac{1+x2^x}{1+x3^x}\right)^\frac1{x^2}
$$
I have used natural logarithm to get
$$
\exp\lim_{x\to0}\frac1{x^2}\ln\left(\frac{1+x2^x}{1+x3^x}\right)
$$
After this, I have tried l'opital's rule but I was unable to get it to a simplified form.
How should I proceed from here? Any here is much appreciated!
 [/INST] Note that $\lim\limits_{x\to0} xn^x=0$.
Next, use the L'Hospital's rule twice to get
$$\lim_{x\to0}\frac{\ln \left({1+xn^x}\right)}{x^2}=
\lim_{x\to0}\frac{\frac{x n^x \ln ^2n+2 n^x \ln n}{x n^x+1}-\frac{\left(n^x+x n^x \ln n\right)^2}{\left(x n^x+1\right)^2}}{2}
=\frac{2  \ln n-1}{2}
$$
Now
$$\lim_{x\to0}\frac{\ln\left(\frac{1+x2^x}{1+x3^x}\right)}{x^2}=
\lim_{x\to0}\frac{\ln\left({1+x2^x}\right)-\ln\left({1+x3^x}\right)}{x^2}
=\frac{2  \ln 2-1}{2} - \frac{2  \ln 3-1}{2}
=  \ln \frac{2}{3}$$
Finally, take exponent to get
$$\lim_{x\to0}\left(\frac{1+x2^x}{1+x3^x}\right)^\frac1{x^2}=\frac{2}{3}$$
Note
$$\frac{d}{dx} n^x = n^x \ln n$$
$$\frac{d}{dx}\ln \left({1+xn^x}\right)=\frac{n^x+x n^x\ln n }{1+xn^x}$$
$$\frac{d^2}{dx}\ln \left({1+xn^x}\right)=\frac{d^2}{dx}\frac{n^x+x n^x\ln n }{1+xn^x}=
\frac{(2n^x\ln n +x n^x(\ln n)^2)(1+xn^x)-(n^x+x n^x\ln n)^2 }{(1+xn^x)^2}=
\frac{x n^x \ln ^2n+2 n^x \ln n}{x n^x+1}-\frac{\left(n^x+x n^x \ln n\right)^2}{\left(x n^x+1\right)^2}$$
</s>