How do you integrate #int xe^xsinx# by integration by parts method?

1 Answer
Sep 14, 2016

#= x/2 e^x (sin x - cos x ) + 1/2 e^x cos x + C#

Explanation:

#int xe^xsinx dx#

#= mathcal{I}{ int xe^xe^(ix) dx }#

#= mathcal{I}{color(red)( int xe^((1+i)x)dx) }#

working the bit in red by IBP

#int xe^((1+i)x)dx#

#= int xd/dx (1/(1+i) e^((1+i)x)) dx#

#= x/(1+i) e^((1+i)x) - int d/dx (x) 1/(1+i) e^((1+i)x) dx + C#

#= x/(1+i) e^((1+i)x) - int 1/(1+i) e^((1+i)x) dx + C#

#= x/(1+i) e^((1+i)x) - 1/(1+i)^2 e^((1+i)x) + C#

#= (1-i)/(1-i) x/(1+i) e^((1+i)x) - ((1-i)/(1-i))^2 1/(1+i)^2 e^((1+i)x) + C#

#= (1-i) x/2 e^((1+i)x) - (1-i)^2 1/4 e^((1+i)x) + C#

#= (1-i) x/2e^x (cos x + i sin x) + i/2 e^x (cos x + i sin x) + C#

And so we want

#= mathcal{I}{ (1-i) x/2e^x (cos x + i sin x) + i/2 e^x (cos x + i sin x) + C}#

#= x/2 e^x (sin x - cos x ) + 1/2 e^x cos x + C#