Primitive of Reciprocal of Square of 1 plus Sine of a x

Theorem

 * $\ds \int \frac {\d x} {\paren {1 + \sin a x}^2} = \frac {-1} {2 a} \map \tan {\frac \pi 4 - \frac {a x} 2} - \frac 1 {6 a} \map {\tan^3} {\frac \pi 4 - \frac {a x} 2} + C$

Proof
Let:

Thus:

Also see

 * Primitive of $\dfrac 1 {\paren {1 + \cos a x}^2}$