PlanetMath (more info)
 Math for the people, by the people.
Encyclopedia | Requests | Forums | Docs | Wiki | Random | RSS  
Login
create new user
name:
pass:
forget your password?
Main Menu
Owner confidence rating: Very high Entry average rating: No information on entry rating
[parent] integration of rational function of sine and cosine (Topic)

The integration task

$\displaystyle \int\!R(\sin{x},\,\cos{x})\,dx,$ (1)

where the integrand is a rational function of $ \sin{x}$ and $ \cos{x}$, changes via the Weierstrass substitution
$\displaystyle \tan\frac{x}{2} = t$ (2)

to a form having an integrand that is a rational function of $ t$. Namely, since $ x = 2\arctan{t}$, we have
$\displaystyle dx = 2\cdot\frac{1}{1+t^2}\,dt,$ (3)

and we can substitute
$\displaystyle \sin{x} = \frac{2t}{1+t^2}, \;\; \cos{x} = \frac{1-t^2}{1+t^2},$ (4)

getting
$\displaystyle \int\!R(\sin{x},\,\cos{x})\,dx\; =\; 2\int\!R\!\left(\frac{2t}{1\!+\!t^2},\,\frac{1\!-\!t^2}{1\!+\!t^2}\right)\frac{dt}{1\!+\!t^2}.$

Proof of the formulae (4): Using the double angle formulas of sine and cosine and then dividing the numerators and the denominators by $ \cos^2\frac{x}{2}$ we obtain

$\displaystyle \sin{x} = \frac{2\sin\frac{x}{2}\cos\frac{x}{2}}{\sin^2\frac{x}{2... ...\frac{x}{2}} = \frac{2\tan\frac{x}{2}}{1+\tan^2\frac{x}{2}} = \frac{2t}{1+t^2},$
$\displaystyle \cos{x} = \frac{\cos^2\frac{x}{2}-\sin^2\frac{x}{2}}{\sin^2\frac{... ...x}{2}} = \frac{1-\tan^2\frac{x}{2}}{1+\tan^2\frac{x}{2}} = \frac{1-t^2}{1+t^2}.$

Example. The above formulae give from $ \displaystyle \int\frac{dx}{\sin{x}}$ the result

$\displaystyle \int\frac{dx}{\sin{x}} = \int\frac{1\!+\!t^2}{2t}\cdot2\cdot\frac... ...nt\frac{dt}{t} = \ln\vert t\vert+C = \ln\left\vert\tan\frac{x}{2}\right\vert+C.$

Note. The substitution (2) is sometimes called the “universal trigonometric substitution”. In practice, it often gives rational functions that are too complicated. In many cases, it is more profitable to use other substitutions:

  • In the case $ \int\!R(\sin{x})\cos{x}\,dx$ the substitution $ \sin{x} = t$ is simpler.
  • Similarly, in the case $ \int\!R(\cos{x})\sin{x}\,dx$ the substitution $ \cos{x} = t$ is simpler.
  • If the integrand depends only on $ \tan{x}$, the substitution $ \tan{x} = t$ is simpler.
  • If the integrand is of the form $ R(\sin^2{x},\, \cos^2{x})$, one can use the substitution $ \tan{x} = t$; then
    $ \displaystyle \cos^2{x} = \frac{1}{1+\tan^2{x}} = \frac{1}{1+t^2}$, $ \displaystyle \sin^2{x} = 1-\cos^2{x} = \frac{t^2}{1+t^2}$, $ \displaystyle dx = \frac{dt}{1+t^2}.$

Example. The integration of $ \displaystyle \int\!\frac{dx}{\cos^4{x}}\,dx$ is of the last case:

$\displaystyle \int\!\frac{dx}{\cos^4{x}}\,dx = \int\!\frac{1}{(\cos^2{x})^2}\,d... ...+t^2} = \int\!(1+t^2)\,dt = \frac{t^3}{3}+t+C = \frac{1}{3}\tan^3{x}+\tan{x}+C.$

Example. The integral $ \displaystyle I = \int\!\frac{dx}{\cos^3{x}}\,dx = \int\! \sec^3{x}\,dx $ is a peculiar case in which one does not have to use the substitutions mentioned above, as integration by parts is a simpler method for evaluating this integral. Thus,

$\displaystyle u = \sec{x}\; \Rightarrow\; du = \sec{x}\;\tan{x}\,dx; \qquad dv = \sec^2{x}\,dx \; \Rightarrow \; v = \tan{x}.$
Therefore,
\begin{displaymath}\begin{array}{rl} I & \displaystyle = \int\! \sec^3{x}\,dx \\... ...ystyle = \sec{x}\;\tan{x} - I + \int\! \sec{x}\,dx. \end{array}\end{displaymath}

Hence,

$\displaystyle \int\!\frac{dx}{\cos^3{x}}\,dx = \frac{1}{2} \big( \sec{x}\;\tan{x}\; + \ln\;\vert\sec{x}\; + \; \tan{x}\vert \big)+C.$



Anyone with an account can edit this entry. Please help improve it!

"integration of rational function of sine and cosine" is owned by pahio. [ full author list (3) ]
(view preamble | get metadata)

View style:

See Also: goniometric formulas, substitution for integration, Weierstrass substitution formulas, Euler's substitutions for integration

Other names:  universal trigonometric substitution

This object's parent.
Log in to rate this entry.
(view current ratings)

Cross-references: integration by parts, integral, denominators, numerators, cosine, sine, double angle formulas, proof, Weierstrass substitution, rational function
There are 3 references to this entry.

This is version 18 of integration of rational function of sine and cosine, born on 2007-05-14, modified 2007-05-23.
Object id is 9380, canonical name is IntegrationOfRationalFunctionOfSineAndCosine.
Accessed 3271 times total.

Classification:
AMS MSC26A36 (Real functions :: Functions of one variable :: Antidifferentiation)

Pending Errata and Addenda
None.
[ View all 1 ]
Discussion
Style: Expand: Order:
forum policy
Open question in the entry 9380 by pahio on 2007-05-14 09:21:08
Stevecheng's correction question (if I understood it):
R(sin{x}, cos{x})
is supposed continuous in odd multiples of pi. If we integrate through such a point using t = tan(x/2), can we obtain right results?
If anybody knows the thing, please supplement the entry.
Jussi


[ reply | up ]

Interact
post | correct | update request | add example | add (any)