# Improper integral $\int_{0}^{\pi}{\frac{x}{\sin{x}}}\,dx$

The problem is asking to check the convergence of the improper integral $$\int_{0}^{\pi}{\frac{x}{\sin{x}}}\,dx.$$

Besides some substitution and partial integration I've tried browsing through stackexchange and haven't found any useful tips really. The only test we've seen at uni is the comparison test or just doing it like any other integral except for watching that it's not a definite integral, but it's getting closer to $0$ and $\pi$. I'm really not sure what I'm supposed to do here, any tips would help!

• looks nice near $x=0$ and nasty near $x=\pi$. – Lord Shark the Unknown Jun 25 '17 at 10:25

Hint. As $x\to \pi^-$, we have that $$0<\frac{x}{\sin(x)}\sim\frac{\pi}{\pi-x}$$ (recall that $f\sim g$ as $x\to x_0$ iff $\lim_{x\to x_0}\frac{f(x)}{g(x)}=1$.)

Can you take it from here?

• So it diverges? I also don't understand why it is written as a definite integral. Does this just mean that $x\rightarrow \pi^{-}$ or also $x\rightarrow 0^{+}$.. – Collapse Jun 25 '17 at 11:19
• It diverges because $\int_{\pi-\epsilon}^{\pi}\frac{\pi}{\pi-x}dx=+\infty$. – Robert Z Jun 25 '17 at 11:31
• I see, thanks a lot! – Collapse Jun 25 '17 at 11:32