What is f(x) = int -cos^3x +tanx dx if f(pi)=-2 ?

1 Answer
Mar 20, 2016

f(x)=-sinx+sin^3x/3-lnabscosx-2

Explanation:

This can be split into two integrals:

f(x)=-intcos^3xdx+inttanxdx

The second integral inttanxdx=-lnabscosx+C, this is a common integral.

To find the first, do what follows:

-intcos^3xdx=-intcos^2xcosxdx

=-int(1-sin^2x)cosxdx

Here, use substitution: let u=sinx and du=cosxdx. This gives:

=-int1-u^2du

Which we can integrate using intu^ndu=u^(n+1)/(n+1)+C, going term by term:

=-u+u^3/3+C=-sinx+sin^3x/3+C

Thus, the whole expression equals

f(x)=-sinx+sin^3x/3-lnabscosx+C

Since f(pi)=-2, we see that

-2=-sinpi+sin^3pi/3-lnabscospi+C

-2=-0+0^3/3-lnabs(-1)+C

-2=0+0+ln1+C

-2=C

Thus, we obtain

f(x)=-sinx+sin^3x/3-lnabscosx-2