<s>[INST] How's my proof, are there any mistakes I have made? Compute $\int \sin(x) \left( \frac{1}{\cos(x) + \sin(x)} + \frac{1}{\cos(x) - \sin(x)} \right)\,dx. $
First, simplify the two fractions into one using a common denominator
\begin{align*}
\int\sin(x)& \left(\frac1{\cos(x)+\sin(x)}+\frac1{\cos(x)-\sin(x)}\right)dx\\
   &= \int\sin(x)\left(\frac{\cos(x)-\sin(x)}{\cos^2(x)-\sin^2(x)}
                     +\frac{\cos(x)+\sin(x)}{\cos^2(x)-\sin^2(x)}\right)dx \\
&= \int\frac{2\sin(x)\cos(x)}{\cos(2x)}dx \\
&= \int\frac{\sin(2x)}{\cos(2x)}dx \\
\end{align*}
Let $u = 2x$. Taking the derivative, $\frac{du}{dx} = 2,$ or $dx = \frac{du}{2}.$
Plugging in $u$ for $2x,$ and $\frac{du}{2}$ for $dx,$ we get $\frac{1}{2}\int \frac{\sin(u)}{\cos(u)}\,du.$
Taking the integral of $\tan(u)$, as solved in problem 10(assume this is true), we get $-\log|\cos(u)|+C.$
Therefore, $\frac{1}{2}\int \frac{\sin(u)}{\cos(u)}\,du = -\frac{1}{2}\log|\cos(u)|+C.$
Finally, subbing $2x$ for $u$, we get $\boxed{-\frac{1}{2}\log|\cos(2x)|+C}$ where $C$ is a constant
 [/INST] Your solution is correct.
Alternatively you could've used the substitution $u=\cos(2x)$.
</s>