# Convergence of $\int _0^{\pi }\frac{1}{\sqrt{\left|\tan x\right|}}dx$

Convergence of $$\int _0^{\pi }\frac{1}{\sqrt{\left|\tan x\right|}}dx$$

I have a trouble when doing this question. I tried to separate the integral into two integrals like this: $$\int _0^{\frac{\pi }{2}\:}\frac{1}{\sqrt{\tan x}}dx+\int _{\frac{\pi }{2}}^{\pi\:}\frac{1}{\sqrt{-\tan x}}dx$$ As for the first integral, I can prove it converges, but for the second integral I can not find a way to prove it converges. I don't know if my separation is the right approach to solve this problem. Can anyone suggest me a way to do this or another approach to solve this problem? Thank you so much.

• Shouldn't your second integral be from $\pi/2$ to $\pi$ ? Apr 22, 2020 at 7:53
• Oh yes, wrong typing sorry Apr 22, 2020 at 7:54

$$\int_0^\pi\frac{dx}{\sqrt{|\tan x|}}=2\int_0^{\pi/2}\frac{dx}{\sqrt{\tan x}}.$$
$$\int_0^{\pi/2}\frac{dx}{\sqrt{\tan x}} = \int_0^{\pi/2}\left(\frac1{\sqrt{\tan x}}-\frac1{\sqrt x}\right)dx+\int_0^{\pi/2}\frac{dx}{\sqrt x} \\= \int_0^{\pi/2}\left(\frac1{\sqrt{\tan x}}-\frac1{\sqrt x}\right)dx+2\sqrt x\bigg|_0^{\pi/2}$$ where the new integrand is bounded. (We used that for small $$x$$, $$\tan x\sim x$$.)