1

How do I go about integrating this function:

$$\int{\sqrt{\tan{x}}} \,dx$$

mrk
  • 3,195

2 Answers2

2

Subbing $x=\arctan{u^2}$, $dx = (2 u)/(1+u^4) du$ produces

$$2 \int du \frac{u^2}{1+u^4}$$

It turns out that

$$1+u^4=(1+\sqrt{2} u+u^2)(1-\sqrt{2} u+u^2)$$

so that we may invoke partial fractions. The result is that the integral becomes

$$\frac1{\sqrt{2}} \int du \left (\frac{u}{1-\sqrt{2} u+u^2} - \frac{u}{1+\sqrt{2} u+u^2} \right )$$

which is equal to

$$\frac1{\sqrt{2}} \int du \left (\frac{u-\frac1{\sqrt{2}}}{\frac12 + \left (u-\frac1{\sqrt{2}}\right )^2} - \frac{u+\frac1{\sqrt{2}}}{\frac12 + \left (u+\frac1{\sqrt{2}}\right )^2} \right )\\+ \frac12 \int du \left (\frac1{\frac12 + \left (u-\frac1{\sqrt{2}}\right )^2}-\frac1{\frac12 + \left (u+\frac1{\sqrt{2}}\right )^2} \right )$$

which evaluates to

$$\frac{1}{2 \sqrt{2}} \log{\left (\frac{1-\sqrt{2} u+u^2}{1+\sqrt{2} u+u^2} \right )} -\frac1{\sqrt{2}} \arctan{\left (\frac1{u^2} \right )}+C$$

Back substitute $u=\sqrt{\tan{x}}$ and you are done. Note that there is some simplification that may be made by observing that

$$\frac1{\tan{x}}=\tan{\left (\frac{\pi}{2}-x \right )}$$

Ron Gordon
  • 141,538
  • +1 Note that this defines an antiderivative over $(0,\frac{\pi}{2})$, and if careful with limiting behavior, over $[0,\frac{\pi}{2}]$. To define a fully general antiderivative over $\ldots\cup [-\pi,-\frac{\pi}{2}]\cup [0,\frac{\pi}{2}]\cup[\pi,\frac{3\pi}{2}]\cup \ldots$ shift this horizontally by multiples of $\pi$ and choose $C$ values independently for each interval. – 2'5 9'2 Dec 19 '13 at 21:59
1

Letting $y=\sqrt {\tan x}$ transforms the integrand into a rational function. $$ \begin{aligned} \int \sqrt{\tan x} d x = & \int y \cdot \frac{2 y d y}{1+y^4} \\ = & \int \frac{2}{y^2+\frac{1}{y^2}} d y \\ = & \int \frac{\left(1+\frac{1}{y^2}\right)+\left(1-\frac{1}{y^2}\right)}{y^2+\frac{1}{y^2}} d y \\ = & \int \frac{d\left(y-\frac{1}{y}\right)}{\left(y-\frac{1}{y}\right)^2+2}+\int \frac{d\left(y+\frac{1}{y}\right)}{\left(y+\frac{1}{y}\right)^2-2} \\ = & \frac{1}{\sqrt{2}}\left[\tan ^{-1}\left(\frac{y-\frac{1}{y}}{\sqrt{2}}\right)-\tanh^{-1} \left(\frac{y+\frac{1}{y}}{\sqrt{2}}\right)\right]+C \\ = & \frac{1}{\sqrt{2}}\left[\tan ^{-1}\left(\frac{\sqrt{\tan x}-\sqrt{\cot x}}{\sqrt{2}}\right)-\tanh ^{-1}\left(\frac{\sqrt{\tan x}+\sqrt{\cot x}}{\sqrt{2}}\right)\right]+C \end{aligned} $$

Lai
  • 31,615