# Integral of sqrt(tan x)

1. Dec 10, 2009

### murshid_islam

$$\int\sqrt{\tan (x)}dx$$

After using the substitution, u2 = tan(x), I got,

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

Next, I tried the partial fraction expansion. But it turned pretty ugly. Is there any easier way of doing it?

2. Dec 10, 2009

### nicksauce

If it is a definite integral, I think contour integration would be the way to go... otherwise I can't think of a way to make it nice.

3. Dec 10, 2009

### dextercioby

I don't think there's a neater way to compute it other than the method you already have.

4. Dec 11, 2009

### Gib Z

There is;

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

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

$$= \int \frac{ d(u-\frac{1}{u})}{ (u-\frac{1}{u})^2 +2} du + \int \frac{ d(u+\frac{1}{u})}{ (u+\frac{1}{u})^2 -2} du$$

5. Dec 12, 2009

### murshid_islam

I'm sorry, but I don't see exactly how that helps.

6. Dec 12, 2009

### Gib Z

The remaining integrals are of forms which are generally considered standard integrals;

$$\int \frac{dx}{x^2+a^2} = \frac{1}{a} \tan^{-1} \frac{x}{a} + C$$

$$\int \frac{dx}{x^2-a^2} = \frac{1}{2a} \log_e \left( \frac{x-a}{x+a}\right) + C$$

7. Dec 13, 2009

### murshid_islam

But how do I deal with the $d\left(u-\frac{1}{u}\right)$ and $d\left(u+\frac{1}{u}\right)$ in the numerators of the integrals?

8. Dec 13, 2009

### Count Iblis

Substitution: put z = u-1/u in the first integral and z = u+1/u in the second integral

9. Dec 13, 2009

### TheoMcCloskey

murshid_islam - Just to be clear, the trailing $du$ in Gib Z's brillant integrals should be deleted. The form of the integrals are really

$$\int \frac{2u^2}{u^4+1} du = \int \frac{ d(u-\frac{1}{u})}{ (u-\frac{1}{u})^2 +2} + \int \frac{ d(u+\frac{1}{u})}{ (u+\frac{1}{u})^2 -2}$$

Do you now understand how the substitution gets to the integral forms in his second post?

10. Dec 13, 2009

### murshid_islam

Thanks a lot. Now everything is clear to me.

Oh yes, now I understand.

11. Dec 13, 2009

### Gib Z

Argh! All that latex code makes me forget what I'm actually typing and it's just instict to jab a du in there after an integral! Sorry murshid_islam!