# Need help with integration...

I need some help with this problem:

$$\int\frac 1 {1+\sin x} \, dx$$

I know it seems quite basic, but I cannot really find the right substitution to use.

• If all else fails, the tangent half-angle substitution will handle this. Google it. Mar 7, 2018 at 19:11
• I actually already did so, but I still don't seem to be able to finish the problem, even with that substitution. I Mar 7, 2018 at 19:13
• Often multiplying something "conjugatey" will help when you're stuck. What about multiplying numerator and denominator by $1-\sin x$ Mar 7, 2018 at 19:13
• @sharding4 That could work, I'm gonna try. Thanks! Mar 7, 2018 at 19:14
• \begin{align} & u = \tan \frac x 2 \\ \\ & 2\arctan u = x \\ \\ & \frac{2\,du}{1+u^2} = dx \\ \\ & \sin x = \sin(2\arctan u) \\ \\ = {} & 2\sin(\arctan u) \cos(\arctan u) \\ \\ = {} & 2\cdot \frac u {\sqrt{1+u^2}} \cdot \frac 1 {\sqrt{1+u^2}} = \frac{2u}{1+u^2} \end{align} Mar 7, 2018 at 19:14

Hint: $$\int\frac 1 {1+\sin x} \, dx=\int\frac {1-\sin x} {\cos^2x} \, dx$$

$$\int\frac 1 {1+\sin x} \, dx=\int\frac {\sec^2\left(\frac x2\right)} {\left(\tan\left(\frac x2\right)+1\right)^2} \, dx$$

Here, you can use $u$-substitution where $u=\tan\left(\dfrac x2\right)+1$ and $dx=\dfrac2{\sec^2\left(\frac x2\right)du}$

$$2\int \dfrac 1{u^2}=-\dfrac{2}u$$ Plugging in $u=\tan\left(\dfrac x2\right)+1$, you get $-\dfrac{2}{\tan\left(\frac x2\right)+1}$. $$\int\frac 1 {1+\sin x}=-\dfrac2{\tan\left(\frac x2\right)+1}+C$$

• They offered this solution in my math book, but I couldnt quite grasp it. Mar 7, 2018 at 19:29
• @LukaDuranovic Most Welcome, I offered it if you still did not understand.
– user535339
Mar 7, 2018 at 19:30

$$\int\frac 1 {1+\sin x} \, dx =\int\frac {1-\sin x} {(1+\sin x)(1-\sin x)} \, dx=$$

$$\int\frac {1-\sin x} {\cos^2 x} dx=$$

$$\int\frac {1} {\cos^2 x} dx -\int\frac {\sin x} {\cos^2 x}=$$

$$\int \sec^2 x dx -\int\frac {\sin x} {\cos^2 x} dx$$

You can easily find both of these integrals.