I'm trying to find $\int 1/\sin(x)\ dx$, but I can't figure out how to do it. Also, what would be the value of$$\int\limits_0^{2\pi} \frac{1}{\sin x} dx\quad ?$$Based on symmetry, I would try to say it is zero, but I've been told to be careful when integrating functions that diverge to $\infty$ in the range of integration.
$\endgroup$ 72 Answers
$\begingroup$Let $\;t=\tan \cfrac x2\;$ for $\;x\in(-\pi,\pi)\;$ then $\;\sin x = \cfrac{2t}{1+t^2}\;$ and $\;\mathrm dx=\cfrac 2{1+t^2}\,\mathrm dt$ \begin{align}\therefore \int\frac{1}{\sin x}\,\mathrm dx &= \int\cfrac 1{\big(\frac{2t}{1+t^2}\big)}\cdot\cfrac 2{1+t^2}\,\mathrm dt \\ &=\int\cfrac 1t\,\mathrm dt \\ &=\ln |t|+c \\ &=\ln \bigg|\tan \cfrac x2\bigg|+c\end{align}
$\endgroup$ $\begingroup$By just checking the left end point only we already see the integral diverges. This is because on the interval $[0,2\pi]$,$$ |\! \sin x| \leq x \implies \left|\frac{1}{\sin x} \right| \geq \frac1x ,$$and the above leads us to$$ \int_0^{2 \pi} \left| \frac{1}{\sin x} \right| dx \geq \int_0^{2 \pi} \frac1x dx .$$The later integral diverges, so by comparison test the former also diverges.
$\endgroup$ 2