Evaluating $\int \sqrt{\frac{x^2+1}{x^2(1-x^2)}}dx$

208 Views Asked by At

Today I came across the following integral $$\int \sqrt{\frac{x^2+1}{x^2(1-x^2)}}dx$$


Here's my work: $$\begin{align}\int \sqrt{\frac{x^2+1}{x^2(1-x^2)}}dx& = \int\frac{1}{x} \sqrt{\frac{1+x^2}{1-x^2}}\ dx \\ & = -\int \sqrt{\frac{1+\cos(2\theta)}{1 - \cos(2\theta)}} \tan(2\theta) \ d\theta\tag{$*$}\\& = -\int \sqrt{\frac{2\cos^2(\theta)}{2\sin^2(\theta)}}\cdot \frac{\sin(2\theta)}{\cos(2\theta)} \ d\theta\\& = - \int\frac{\cos(\theta)}{\sin(\theta)}\cdot \frac{2\sin(\theta)\cos(\theta)}{\cos^2\theta - \sin^2\theta}\ d\theta\\& = - \int \frac{(\cos^2\theta + \sin^2\theta) + (\cos^2\theta - \sin^2\theta)}{\cos^2\theta - \sin^2\theta}\ d\theta\\& = - \int \sec(2\theta) + 1 \ d\theta\tag{1}\\& =-\frac{1}2 \ln|\sec(2\theta) + \tan(2\theta)| + \theta + C\tag{2}\\& = - \frac{1}{2} \ln\left|\sec(\cos^{-1}(x^2)) + \tan(\cos^{-1}(x^2))\right| + \frac12 \cos^{-1}(x^2) + C\\& = - \frac12\ln\left|\frac1{x^2} + \frac{\sqrt{1 - x^4}}{x^2}\right| + \frac12 \cos^{-1}(x^2) + C\\& = - \frac12\ln\left|\frac{1 + \sqrt{1 - x^4}}{x^2}\right| + \frac12 \cos^{-1}(x^2) + C\end{align}$$


$(*)$ Here I've made a substitution $x^2 = \cos(2\theta)$ so that $\dfrac{dx}{x} = - \tan(2\theta)\ d\theta$.


But this answer seems to be wrong! I differentiated my answer but didn't get the original integrand. Wolframalpha results this expression and I'm not sure about it.

I'm just unable to figure out what's actually wrong with my method.

Edit:

With Bob Dobbs's comment, I got that I did wrong moving from step $(1)$ to step $(2)$.

3

There are 3 best solutions below

0
On BEST ANSWER

The back trigonometric substitution could be problematic. To avoid it, integrate instead as follows

$$\int \sqrt{\frac{x^2+1}{x^2(1-x^2)}}dx= \int \frac x{\sqrt{1-x^4}}dx+\int \frac1{\sqrt{x^2(1-x^4})}dx $$ where \begin{align} &\int \frac x{\sqrt{1-x^4}}dx=\frac12\int \frac {d(x^2)}{\sqrt{1-x^4}}=\frac12\sin^{-1}x^2\\ &\int \frac 1{\sqrt{x^2(1-x^4})}dx=\frac12\int \frac {d(\sqrt{1-x^4})}{(1-x^4)-1}=-\frac12\tanh^{-1} \sqrt{1-x^4} \end{align}

0
On

If you make $$x=\sqrt{\frac {t^2-1}{t^2+1 }}$$ the integral becomes $$-2\int \frac{t^2}{t^4-1}\,dt $$ Factoring and partial fraction decomposition $$\frac{t^2}{t^4-1}=\frac{t^2}{(t^2-1)(t^2+1)}=\frac{1}{2 \left(t^2+1\right)}+\frac{1}{2 \left(t^2-1\right)}$$ which are simple

0
On

Assume $x>0$ We need to find $$\int\frac{\sqrt{x^2+1}}{x\sqrt{1-x^2}}dx$$ Substitute $u=\sqrt{1-x^2}$ and rewrite the integral as $$\int\frac{\sqrt{2-u^2}}{u^2-1}du$$ Substitute $v=\sqrt2\sin v$ and rewrite the integral as $$\int\frac{\sqrt2\cos v\sqrt{2-2\sin^2v}}{2\sin^2v-1}dv$$ $$=2\int\frac{\cos^2v}{2\sin^2v-1}dv$$ Recall that $\sin v=\frac{\tan v}{\sec v}$ and $\cos v=\frac{1}{\sec v}$ and $\tan^2v=\sec^2v-1$

Now our integral becomes (Just solving the integral, we can multiply by $2$ later) $$\int\frac{\sec^2v}{(\tan^2v-1)(\tan^2v+1)}dv$$ Substitute $w=\tan v$ and rewrite as $$\int\frac{1}{(w^2-1)(w^2+1)}dw$$ Using parial fraction we can rewrite it as $$\int\left[\frac{1}{4(w-1)}-\frac{1}{4(w+1)}-\frac{1}{2(w^2+1)}\right]dw$$ I hope OP can continue from here.

Note: After you evaluate the final answer, don't forget it to multiply by $\frac{x}{|x|}$