Question about limit of inverse function

94 Views Asked by At

So I was looking for a good way to invert the function $f(x) =\frac{\pi K(\sqrt{1-x^2})}{K(x)}$ where $K(x)=\int_{0}^{1}\frac{1}{\sqrt{(1-t^2)(1-x^2t^2)}}dt$ and knowing that $\lim_{x\to0} f(x)=2\ln(\frac{4}{x})$ so inverting the latter function to get $g(x)=\frac{4}{e^{\frac{x}{2}}}$. Therefore shouldn't $\lim_{x\to0}f(g(x))=x$ but when I graph this on desmos I get the opposite instead where it seems $\lim_{x\to\infty}f(g(x))=x$ but when I swap the functions $\lim_{x\to0}g(f(x))=x$ is true. Why is this happening?