# How to change the trigonometric identity to sec^2(x)?

Evaluate the definite integral:

$$\int_{\frac{\pi}{8}}^\frac{\pi}{4}(\csc(2\theta)-\cot(2\theta)\ d\theta$$

Finding the derivative gives me this, which is confirmed by the steps in Wolfram Alpha. This is the answer as the last step that I also got.

$$-2\csc(2\theta)\cot(2\theta)+2\csc^2(2\theta)$$

But then at the top, Wolfram Alpha says the answer is this:

$$\sec^2\theta$$

How did they get that?

Edit: I just realized that I'm solving the question wrong; I'm supposed to find the antiderivative and not the derivate. Either way, I wanted to know how the identity was found.

• If you put a backslash before the function name, it comes out in the right font. \csc gives $\csc$ – Ross Millikan Nov 2 '15 at 7:27
• The two functions you mention are the same. This is verified by for example going to sines and cosines. Neither is equal to the (indefinite) integral, which is a constant times $\ln(1-\cos(2\theta))$. – André Nicolas Nov 2 '15 at 7:41
• I know it's not the integral, I just wanted to know how they got from $-2\csc(2\theta\cot(2\theta)+2\csc^2(2\theta)$ to $sec^2(\theta)$. – Jose Ramirez Nov 2 '15 at 7:44
• If we express $\csc(2\theta)$ and $\cot(2\theta)$ in terms of sines and cosines, we get $$\frac{2(1-\cos(2\theta))}{\sin^2(2\theta)}.$$ Now use the double-angle identities $\cos(2\theta)=1-\sin^2\theta$ and $\sin(2\theta)=2\sin\theta\cos\theta$. – André Nicolas Nov 2 '15 at 7:52

Steps are: $$-2\csc(2\theta)\cot(2\theta) + 2\csc^{2}(2\theta)$$ $$-2* \frac{1}{2\sin(\theta)cos(\theta)} * \frac{cos(2\theta)}{sin(2\theta)} + 2\csc^{2}(2\theta)$$ Simplify. $$-2 * \frac{1-2\sin^{2}(\theta)}{\sin^{2}(2\theta)} + 2\csc^{2}(2\theta)$$ Then $$\frac{-2}{\sin^{2}(2\theta)} + \frac{1}{\cos^{2}(\theta)} + 2\csc^{2}(2\theta)$$ $$\frac{-2}{\sin^{2}(2\theta)} + \frac{1}{\cos^{2}(\theta)} + \frac{2}{\sin^{2}(2\theta)}$$ Clearly, the -2 and +2 terms cancel, and you're left with $\frac{1}{\cos^{2}(\theta)}$ which is the same as $\sec^{2}(\theta)$
• Thanks! But it should be $2\csc^2(2\theta)$ – Jose Ramirez Nov 2 '15 at 7:57
Notice, $$\int_{\pi/8}^{\pi/4}(\csc(2\theta)-\cot(2\theta))\ d\theta$$ $$=\frac{1}{2}\int_{\pi/8}^{\pi/4}(\csc(2\theta)-\cot(2\theta))\ d(2\theta)$$ $$=\frac{1}{2}\left(\ln|\csc (2\theta)-\cot (2\theta)|-\ln|\sin (2\theta)|\right)_{\pi/8}^{\pi/4}$$ $$=\frac{1}{2}\left(\ln\left|\frac{\csc (2\theta)-\cot (2\theta)}{\sin (2\theta)}\right|\right)_{\pi/8}^{\pi/4}$$ $$=\frac{1}{2}\left(\ln\left|\frac{\csc \frac{\pi}{2}-\cot \frac{\pi}{2}}{\sin \frac{\pi}{2}}\right|-\ln\left|\frac{\csc \frac{\pi}{4}-\cot \frac{\pi}{4}}{\sin \frac{\pi}{4}}\right|\right)$$ $$=\frac{1}{2}\left(\ln\left|\frac{1-0}{1}\right|-\ln\left|\frac{\sqrt {2}-1}{\frac{1}{\sqrt 2}}\right|\right)$$ $$=\frac{1}{2}\left(0-\ln\left|2-\sqrt 2\right|\right)$$ $$=\color{}{-\frac{1}{2}\ln\left(2-\sqrt 2\right)}=\color{red}{\frac{1}{2}\ln\left(\frac{2+\sqrt 2}{2}\right)}$$
• I believe your third step is missing a negative, as in $-ln|\csc(2\theta)...|$; but thank you. – Jose Ramirez Nov 2 '15 at 8:02
• OP just wanted to know how WA got $sec^2 \theta$ and not solve the whole integral – Shailesh Nov 2 '15 at 8:04