Use the derivative (below) to find the integral of #cos^nx dx#?

The question asks to find #d/dx(sinx*cos^(n-1)x)# which is just #cos^nx +(1-n)*sin^2x*cos^(n-2)x#
and then to use that to show that #n int cos^nx dx = sinx*cos^(n-1)x + (n-1) int cos^(n-2)x dx# but I get a #sin^2x# in with the second integral there. What is the problem going on here? Thank you!

1 Answer
May 8, 2018

Using the product rule in fact:

#d/dx (sinx cos^(n-1)x) = cos^nx - (n-1)sin^2x cos^(n-2)x#

Integrating both sides of the equality and using the linearity of the integral:

#sinx cos^(n-1)x = int cos^nx dx - (n-1)int sin^2x cos^(n-2)x dx#

use now the trigonometric identity:

#sin^2x = 1-cos^2x#

to get:

#sinx cos^(n-1)x = int cos^nx dx - (n-1)int (1-cos^2x) cos^(n-2)x dx#

#sinx cos^(n-1)x = int cos^nx dx - (n-1)int cos^(n-2)x dx +int (n-1)cos^nx dx#

#sinx cos^(n-1)x = n int cos^nx dx - (n-1)int cos^(n-2)x dx #

and finally:

#n int cos^nx dx = sinx cos^(n-1)x + (n-1)int cos^(n-2)x dx #