This page covers integration of functions involving sines and/or cosines in more advanced form that require techniques other than just integration by substitution. [If you are first learning sine and cosine in integration, check out the basics of trig integration page.]
Most of the techniques you need are discussed on this page except for the sine and cosine reduction formulas. We derive them and give you practice problems on two separate pages, the sine reduction formula page and the cosine reduction formula page.
Trig integration, covered on this page, is the evaluation of integrals that already have trig functions in the integrand.
Trig substitution is a technique that takes an integrand that most likely does NOT contain any trig functions, and uses some trig identities to introduce trig functions into the integrand. Once the integral is completely transformed, then trig integration is used to evaluate the integral. Once the evaluation is complete, another set of substitutions, based on the original ones, is done to convert the result back to the original variable.
Trig Integration  Complete Case List Summary (One Angle)  

\(\int{\sin^mx \cos^nx~dx}\)  
\(n=0\)  \(\int{\sin^mx~dx}\)  use reduction formula 
\(m=0\)  \(\int{\cos^mx~dx}\)  use reduction formula 
odd m  \(\int{\sin^{2k+1}x\cos^nx~dx}\)  factor out \(\sin x\), use \(\sin^2x=1\cos^2x\) and let \(u=\cos x\) 
odd n  \(\int{\sin^mx\cos^{2k+1}x~dx}\)  factor out \(\cos x\), use \(\cos^2x=1\sin^2x\) and let \(u=\sin x\) 
even m and n  \(\int{\sin^{2k}x\cos^{2p}x~dx}\)  use halfangle formulas 
\(\int{\sec^mx \tan^nx~dx}\)  
\(n=0\)  \(\int{\sec^mx~dx}\)  use reduction formula 
\(m=0\)  \(\int{\tan^nx~dx}\)  use reduction formula or use \(\sec^2x=1+\tan^2x\), expand out 
even m  \(\int{\sec^{2k}x\tan^nx~dx}\)  factor out \(\sec^2x\), use \(\sec^2x=1+\tan^2x\) and let \(u=\tan x\) 
odd n  \(\int{\sec^mx\tan^{2k+1}x~dx}\)  factor out \(\sec x\tan x\), use \(\sec^2x=1+\tan^2x\) and let \(u=\sec x\) 
none of the above 4 cases hold  convert trig functions to sine and cosine and 
In order to choose the technique you need to use, you need to determine the form of the integrand and how many angles are involved.
One Angle 

When all the sine and cosine terms in the integrand involve the same angle, here is what you do.
Case 1  one sine term only: \( \int{ \sin^n(\theta) ~d\theta} \) 
Use the reduction formula found on the sine reduction formula page. 
Case 2  one cosine term only: \( \int{ \cos^n(\theta) ~d\theta} \) 
Use the reduction formula discussed on the cosine reduction formula page. 
Case 3  odd term: \( \int{ \sin^m(\theta)~\cos^n(\theta) ~d\theta} \) with odd m or n 
Factor out the odd term (if they are both odd, you can choose) and use \(\sin^2\theta + \cos^2\theta = 1\) on the remaining term, then use substitution. 
Case 4  even term: \( \int{ \sin^m(\theta)~\cos^n(\theta) ~d\theta} \) with even m and n 
Use the halfangle formulas to remove the powers. 
Okay, let's work some practice problems before we go on.
Instructions   Unless otherwise instructed, evaluate the following integrals using the techniques on this page. Give all answers in exact, simplified form.
Basic Problems 

Problem Statement 

\(\displaystyle{ \int{ \sin^4(2x)\cos(2x)~dx } }\)
Final Answer 

Problem Statement 

\(\displaystyle{ \int{ \sin^4(2x)\cos(2x)~dx } }\)
Solution 

Our first inclination might be to use the halfangle formulas for \(\sin(2x)\) and \(\cos(2x)\). However, on closer inspection, we can see that both of the angles are the same, i.e. both are \(2x\). So this falls under case 3 above. The first part is done, i.e. the odd cosine is already factored out, so we are ready to use substitution. So we let \(u=\sin(2x)\).
This gives us \(du = 2\cos(2x)dx \to du/2 = \cos(2x)dx\)
\(\displaystyle{ \int{ \sin^4(2x)\cos(2x) ~dx } = \int{u^4 (du/2)} }\) 
\(\displaystyle{\frac{1}{2}\frac{u^5}{5} + C }\) 
\(\displaystyle{ \frac{u^5}{10} + C }\) 
\(\displaystyle{ \frac{\sin^5(2x)}{10} + C }\) 
Final Answer 

\(\displaystyle{ \int{ \sin^4(2x)\cos(2x)~dx } = \frac{\sin^5(2x)}{10}+C }\) 
close solution

Problem Statement 

\(\displaystyle{ \int{ \cos^5x\sin^5x~dx } }\)
Solution 

For this problem, he doesn't go into a lot of detail in the integration. I would probably leave the integral as
\(\displaystyle{ \int{ (\sin^5x  2\sin^7x + \sin^9x) } }\) \(\cos x ~dx\) and use the substitution \(u = \sin x\) to get
\(\displaystyle{ \int{ u^5  2u^7 + u^9 ~du } = \frac{u^6}{6}  \frac{u^8}{4} + \frac{u^{10}}{10} + C }\)
The final answer follows more directly from this.
video by Dr Chris Tisdell 

close solution

Problem Statement 

\(\displaystyle{ \int{ \cos^4x\sin^3x~dx } }\)
Solution 

video by Dr Chris Tisdell 

close solution

Problem Statement 

\(\displaystyle{ \int{ \sin^2x~\cos^2x~dx } }\)
Solution 

video by PatrickJMT 

close solution

Problem Statement 

\(\displaystyle{ \int_{0}^{ \pi/2}{\sin^2x~\cos^2x~dx } }\)
Solution 

video by Krista King Math 

close solution

Problem Statement 

\(\displaystyle{ \int{ \sin^3x~\sec^2x~dx } }\)
Solution 

video by MIT OCW 

close solution

Problem Statement 

\(\displaystyle{\int{\sin^3x~\cos^2x~dx}}\)
Solution 

video by PatrickJMT 

close solution

Problem Statement 

\(\displaystyle{\int{\sin^3x~\cos^3x~dx}}\)
Solution 

video by PatrickJMT 

close solution

Problem Statement 

\(\displaystyle{ \int_{ \pi/2}^{\pi}{ \sin^3 \theta ~ \cos^2 \theta ~ d\theta } }\)
Solution 

video by Dr Chris Tisdell 

close solution

Problem Statement 

\(\int{\cos^5(\theta)~d\theta}\)
Final Answer 

Problem Statement 

\(\int{\cos^5(\theta)~d\theta}\)
Solution 

At about the 4min 30sec mark in this video he jumps from \(\int{ 2\sin^2\theta\cos\theta ~d\theta }\) to the answer \((2/3)\sin^3\theta\). Later on in the video he explains how to use an identity often found in an integral table to get this.
However, we would just use integration by substitution by letting \(u=\sin\theta\) to get this result.
video by Dr Chris Tisdell 

Final Answer 

\(\sin\theta(2/3)\sin^3\theta +(1/5)\sin^5\theta+K\) 
close solution

Intermediate Problems 

Problem Statement 

\(\displaystyle{ \int{ \cos^4x~\sin^2x~dx } }\)
Final Answer 

Problem Statement 

\(\displaystyle{ \int{ \cos^4x~\sin^2x~dx } }\)
Solution 

\(\int{\cos^4 x \sin^2 x~dx}\) 

use the halfangle formulas \(\cos^2 t = [1+\cos(2t)]/2\) and \(\sin^2 t = [1\cos(2t)]/2\) 
\(\displaystyle{\int{\left[ \frac{1+\cos(2x)}{x}\right]^2 \left[ \frac{1\cos(2x)}{2}\right]~dx}}\) 
\(\displaystyle{\frac{1}{8}\int{[1+2\cos(2x)+\cos^2(2x)][1\cos(2x)]~dx}}\) 
\(\displaystyle{\frac{1}{8}\int{1+\cos(2x)\cos^2{2x}\cos^3(2x)~dx}}\) 
on the third term, use the halfangle formula again; 
\(\displaystyle{\frac{1}{8}\left[ x + \frac{\sin(2x)}{2}  \int{\frac{1+\cos(4x)}{2}~dx}  \int{[1\sin^2(2x)]\cos(2x)~dx}\right]}\) 
on the last term, we will use integration by substitution as follows 
\(u=\sin(2x) \to du=2\cos(2x)~dx\) 
\(\int{[1\sin^2(2x)]\cos(2x)~dx} = \) \(\int{(1u^2)~du/2} = \) \((1/2)(uu^3/3)\) 
placing this last result in the full integral, we have 
\(\displaystyle{\frac{1}{8}\left[ x+\frac{\sin(2x)}{2}  \frac{x}{2}  \frac{\sin(4x)}{8}  \frac{\sin(2x)}{2} + \frac{\sin^3(2x)}{6}\right] + C}\) 
simplify to get the final answer 
Final Answer 

\(\displaystyle{\frac{1}{192}\left[ 12x + 4\sin^3(2x)3\sin(4x)\right] + C}\) 
close solution

Problem Statement 

\(\displaystyle{\int_{0}^{\pi/2}{\sin^7\theta~\cos^5\theta~d\theta}}\)
Solution 

video by Krista King Math 

close solution

Problem Statement 

\(\displaystyle{ \int{ \cos^4x~dx } }\)
Solution 

video by PatrickJMT 

close solution

Problem Statement 

\(\displaystyle{ \int{ \sin^2(\pi x)~\cos^5(\pi x)~dx } }\)
Solution 

video by Krista King Math 

close solution

Sines/Cosines in Denominator 

Up until now, we have looked at only the case when all sine and cosine terms are in the numerator. So, what do you do when they are in the denominator? We will look at the case when they are mixed, i.e. terms are in both the numerator and denominator and, secondly, when all terms are in the denominator.
First, there is no definite formula to use for every case. So, to know when to use a technique, you need lots of practice and experience. Then you get a feel for what works and what doesn't.
1. When you have sine/cosine terms in both the numerator and denominator, usually substitution will work along with the techniques already listed above. You may also need to use trig identities like \(\sin^2\theta + \cos^2\theta = 1\) to replace terms.
2. When all the terms are in the denominator, one technique to try is replacing the one in the numerator with \(\sin^2\theta + \cos^2\theta\) and separate the integral into two terms.
Try these ideas on these practice problems.
Problem Statement 

\(\displaystyle{ \int{ \frac{\cos(x) \sin(\csc~x)}{\sin^2(x)} ~dx } }\)
Solution 

video by PatrickJMT 

close solution

Problem Statement 

\(\displaystyle{ \int{ \frac{\sin^2 x}{\cos^2 x}~dx } }\)
Solution 

video by Michel vanBiezen 

close solution

Problem Statement 

\(\displaystyle{ \int{ \frac{1}{\sin x \cos^3 x}~dx } }\)
Solution 

video by Michel vanBiezen 

close solution

Problem Statement 

\(\displaystyle{ \int{ \frac{\sin^3 x}{\cos x}~dx } }\)
Hint 

1. Write the numerator as \(\sin^2 x \sin x\).
2. Replace \(\sin^2 x\) with \(1\cos^2 x\).
3. Separate into two integrals, evaluating using integration by substitution.
Problem Statement 

\(\displaystyle{ \int{ \frac{\sin^3 x}{\cos x}~dx } }\)
Final Answer 

Problem Statement 

\(\displaystyle{ \int{ \frac{\sin^3 x}{\cos x}~dx } }\)
Hint 

1. Write the numerator as \(\sin^2 x \sin x\).
2. Replace \(\sin^2 x\) with \(1\cos^2 x\).
3. Separate into two integrals, evaluating using integration by substitution.
Solution 

video by Michel vanBiezen 

Final Answer 

\(\ln\abs{\cos x}  (1/2)\sin^2 x + C\) 
close solution

Problem Statement 

\(\displaystyle{ \int{ \frac{\sin^3x}{\cos^3x} ~dx } }\)
Final Answer 

Problem Statement 

\(\displaystyle{ \int{ \frac{\sin^3x}{\cos^3x} ~dx } }\)
Solution 

This integral is solved two different ways, shown in the first two videos. In the two videos, he gets what looks like two different answers. In the third video he shows that they differ only by a constant. He does it in a unique way though, by taking the derivative of the two answers and noticing they are equal. In the fourth video, he compares actual values to notice that the two answers differ by 0.5.
After all that work, I believe it is very easy to show that the answers differ only by a constant. Here is how.
Notice that the terms that don't match are \(0.5\tan^2x\) and \(0.5/\cos^2x\). Well, we know that \(1/\cos x = \sec x\). So \(1/\cos^2x = \sec^2x\). But we have the identity \(\sec^2x = 1+\tan^2x\). So \(0.5/\cos^2x = 0.5\sec^2x = 0.5(1+\tan^2x) = 0.5+0.5\tan^2x.\) So we know that the two answers differ by the constant 0.5. This 0.5 is absorbed in the general constant in each answer. So technically, he should have used two different symbols for the constants.
video by Michel vanBiezen 

video by Michel vanBiezen 

video by Michel vanBiezen 

video by Michel vanBiezen 

Final Answer 

\((1/2)\tan^2x + \ln\cos x+C_1\) or \((1/2)/\cos^2x + \ln\cos x+C_2\) 
close solution

Problem Statement 

\(\displaystyle{ \int{ \frac{1}{\cos^3x } ~dx } }\)
Solution 

video by Michel vanBiezen 

close solution

Two Angles 

When you have different angles use the following formulas to simplify the integrand.
both sine terms 
\(\displaystyle{ \sin(\alpha)\sin(\theta) = \frac{1}{2}\left[ \cos(\alpha  \theta)  \cos(\alpha + \theta) \right] }\) 
both cosine terms 
\(\displaystyle{ \cos(\alpha)\cos(\theta) = \frac{1}{2}\left[ \cos(\alpha  \theta) + \cos(\alpha + \theta) \right] }\) 
one sine term, one cosine term 
\(\displaystyle{ \sin(\alpha)\cos(\theta) = \frac{1}{2}\left[ \sin(\alpha + \theta) + \sin(\alpha  \theta) \right] }\) 
Try these ideas on these practice problems.
Problem Statement 

\(\displaystyle{ \int{ \sin(4x)\cos(2x)~dx } }\)
Solution 

video by Dr Chris Tisdell 

close solution

Problem Statement 

\(\displaystyle{ \int{ \sin(2x)~\cos(3x)~dx } }\)
Solution 

video by PatrickJMT 

close solution

Problem Statement 

\(\displaystyle{ \int{ \sin(2x)~\sin(3x)~dx } }\)
Solution 

video by PatrickJMT 

close solution

Problem Statement 

\(\displaystyle{ \int{ \sin(8x)~\cos(5x)~dx } }\)
Solution 

video by Krista King Math 

close solution

Problem Statement 

\(\displaystyle{ \int{ \sin(3x)\sin(6x)~dx } }\)
Solution 

video by Krista King Math 

close solution

Problem Statement 

\(\displaystyle{ \int{ \sin x~\cos(2x)~dx } }\)
Solution 

video by MIT OCW 

close solution

Problem Statement 

\(\displaystyle{ \int{ \cos(4\pi x)\cos(\pi x)~dx } }\)
Solution 

video by Krista King Math 

close solution

You CAN Ace Calculus
basic trig identities 

\(\sin^2\theta+\cos^2\theta=1\)  \(1+\tan^2\theta=\sec^2\theta\) 
\(\displaystyle{\tan\theta=\frac{\sin\theta}{\cos\theta}}\)  \(\displaystyle{\cot\theta=\frac{\cos\theta}{\sin\theta}}\) 
\(\displaystyle{\sec\theta=\frac{1}{\cos\theta}}\)  \(\displaystyle{\csc\theta=\frac{1}{\sin\theta}}\) 
power reduction (halfangle) formulae 
\(\displaystyle{\sin^2\theta=\frac{1\cos(2\theta)}{2}}\)  \(\displaystyle{\cos^2\theta=\frac{1+\cos(2\theta)}{2}}\) 
double angle formulae 
\(\sin(2\theta)=2\sin\theta\cos\theta\)  \(\cos(2\theta)=\cos^2\theta\sin^2\theta\) 
links 
basic trig derivatives  

\(\displaystyle{ \frac{d[\sin(t)]}{dt} = \cos(t) }\) 
\(\displaystyle{ \frac{d[\cos(t)]}{dt} = \sin(t) }\)  
\(\displaystyle{ \frac{d[\tan(t)]}{dt} = \sec^2(t) }\) 
\(\displaystyle{ \frac{d[\cot(t)]}{dt} = \csc^2(t) }\)  
\(\displaystyle{ \frac{d[\sec(t)]}{dt} = }\) \(\sec(t)\tan(t) \) 
\(\displaystyle{ \frac{d[\csc(t)]}{dt} = }\) \( \csc(t)\cot(t) \)  
basic trig integrals  
\(\int{\sin(x)~dx} = \cos(x)+C\)  
\(\int{\cos(x)~dx} = \sin(x)+C\)  
\(\int{\tan(x)~dx} = \ln\abs{\cos(x)}+C\)  
\(\int{\cot(x)~dx} = \ln\abs{\sin(x)}+C\)  
\(\int{\sec(x)~dx} = \ln\abs{\sec(x)+\tan(x)}+C\)  
\(\int{\csc(x)~dx} = \ln\abs{\csc(x)+\cot(x)}+C\)  
reduction formulae  
Reduction Formulas (n is a positive integer)  
\(\displaystyle{\int{\sin^n x~dx} = \frac{\sin^{n1}x\cos x}{n} + }\) \(\displaystyle{ \frac{n1}{n}\int{\sin^{n2}x~dx} }\)  
\(\displaystyle{\int{\cos^n x~dx} = \frac{\cos^{n1}x\sin x}{n} + }\) \(\displaystyle{ \frac{n1}{n}\int{\cos^{n2}x~dx}}\)  
Reduction Formulas (n is an integer and \(n>1\))  
\(\displaystyle{\int{\tan^n x~dx}= \frac{\tan^{n1}x}{n1}  \int{\tan^{n2}x~dx}}\)  
\(\displaystyle{\int{\sec^n x~dx} = \frac{\sec^{n2}x\tan x}{n1} + }\) \(\displaystyle{ \frac{n2}{n1}\int{\sec^{n2}x~dx}}\)  
links  
related topics on other pages 

external links you may find helpful 
To bookmark this page and practice problems, log in to your account or set up a free account.
Single Variable Calculus 

MultiVariable Calculus 

Do you have a practice problem number but do not know on which page it is found? If so, enter the number below and click 'page' to go to the page on which it is found or click 'practice' to be taken to the practice problem.
 
Help Keep 17Calculus Free 

The 17Calculus and 17Precalculus iOS and Android apps are no longer available for download. If you are still using a previously downloaded app, your app will be available until the end of 2020, after which the information may no longer be available. However, do not despair. All the information (and more) is now available on 17calculus.com for free. 