# Evaluate $\int \theta\sec\theta \tan\theta \ d\theta$

integral of $\int \theta\sec\theta \tan\theta \ d\theta$

my work

$\frac{d}{d\theta}\sec(θ) = \sec(\theta)\tan(\theta)$

So if we let $u = \theta$ and $v' = \sec(\theta)\tan(\theta)$, then we get:

$u = \theta, du = d\theta$ and $v = \sec(\theta), dv = \sec(\theta)\tan(\theta)d\theta$

Hence

$$\int \theta \sec(\theta)\tan(\theta) d\theta = \theta\sec(\theta) - \int\sec(\theta) d\theta$$

Now, the integral of $\sec(\theta)$ is a particularly tricky integral, but it comes to:

$$\int \sec(\theta) d \theta = \ln|\sec(\theta) + \tan(\theta)| + C$$

integral comes to:

$$\int \theta \sec(\theta)\tan(\theta) d\theta = \theta \sec(\theta) - \ln|\sec(\theta) + \tan(\theta)| + C$$

but my answer is not like this picture

• Your work is fine. – user84413 Aug 26 '15 at 20:26
• I need to be like the answer in the picture – Adel Hassan Aug 26 '15 at 20:27
• @zorbha No, you don't need to: your answer is correct, the one in the book is not (because of missing absolute values). – egreg Aug 26 '15 at 20:47

Let $c = \cos \frac {\theta}2; s= \sin \frac {\theta}2$

Note that $$\sec \theta +\tan \theta = \frac {1+\sin \theta}{\cos \theta}=\frac {c^2+s^2+2cs}{c^2-s^2}=\frac {(c+s)^2}{(c+s)(c-s)}=\frac {c+s}{c-s}$$ and that should help you to reconcile the two answers.

• @user84413 There were several typos! Thanks for pointing that out - I hope they are now sorted – Mark Bennet Aug 26 '15 at 20:31

$$\log|\cos(\theta/2)-\sin(\theta/2)|-\log|\cos(\theta/2)+\sin(\theta/2)|=\log |\frac{\cos(\theta/2)-\sin(\theta/2)}{\cos(\theta/2)+\sin(\theta/2)}|\\ =\log |\frac{\cos^2(\theta/2)-2\sin(\theta/2)\cos(\theta/2)+\sin^2(\theta/2)}{\cos^2(\theta/2)-\sin^2(\theta/2)}|\\=\log |\frac{1-\sin(\theta)}{\cos(\theta)}|=\log|\sec(\theta)-\tan(\theta)|= \log \frac{|\sec^2(\theta)-\tan^2(\theta)| }{|\sec(\theta)+\tan(\theta)|} \\=-\log| \sec(\theta)+\tan(\theta)|$$
An antiderivative of $$\sec\theta\tan\theta=\frac{\sin\theta}{\cos^2\theta}= -\frac{-\sin\theta}{\cos^2\theta}$$ is $1/\cos\theta$. Therefore, integrating by parts, $$\int\theta\frac{\sin\theta}{\cos^2\theta}\,d\theta= \frac{\theta}{\cos\theta}-\int\frac{1}{\cos\theta}\,d\theta$$ The remaining integral can be computed with the substitution $$\theta=\frac{\pi}{2}-2u$$ so \begin{align} -\int\frac{1}{\cos\theta}\,d\theta= \int\frac{1}{\sin2u}\,2du &= \int\frac{\cos^2u+\sin^2u}{\sin u\cos u}\,du\\[6px] &= \int\left(\frac{\cos u}{\sin u}+\frac{\sin u}{\cos u}\right)du \\[6px] &= \log|\sin u|-\log|\cos u|+C\\[6px] &=\log\left|\tan u\right|+C\\[6px] &=\log\left|\tan\left(\frac{\pi}{4}-\frac{\theta}{2}\right)\right| \end{align} Now $$\tan\left(\frac{\pi}{4}-\frac{\theta}{2}\right)= \frac{1-\tan(\theta/2)}{1+\tan(\theta/2)}= \frac{\cos(\theta/2)-\sin(\theta/2)}{\cos(\theta/2)+\sin(\theta/2)}$$ Thus the book is almost right: they're forgetting the absolute value.
You are stating that $$\log|\sec\theta+\tan\theta|$$ is an antiderivative of $\sec\theta$; let's try: $$\log|\sec\theta+\tan\theta|= \log\left|\frac{1+\sin\theta}{\cos\theta}\right|= \log|1+\sin\theta|-\log|\cos\theta|$$ The derivative is $$\frac{\cos\theta}{1+\sin\theta}-\frac{-\sin\theta}{\cos\theta}= \frac{\cos^2\theta+\sin\theta+\sin^2\theta}{\cos\theta(1+\sin\theta)}= \frac{1+\sin\theta}{\cos\theta(1+\sin\theta)}=\frac{1}{\cos\theta}$$ So you're right as well. Even “more right” than the book.