How do you find the integral of #f(x)=x^(n-1)e^x# using integration by parts?

1 Answer
Jul 11, 2016

#int x^n e^x dx = e^x sum_{k=0}^n (-1)^k((n!)/(k!))x^k#

Explanation:

#d/(dx)(x^n e^x)=n x^{n-1}e^x+x^n e^x#

then

#int x^n e^x dx + n int x^{n-1}e^x dx = x^n e^x#

now calling #I_n=e^{-x}int x^n e^x dx# we have a recurrence equation

#I_n +nI_{n-1} = x^n# with condition

#I_0 = e^{-x}int e^xdx = 1#

Solving this recurrence equation is straightforward as can be seen in
https://en.wikipedia.org/wiki/Recurrence_relation in

Solving first-order non-homogeneous recurrence relations with variable coefficients

giving as result

#I_n = sum_{k=0}^n (-1)^k((n!)/(k!))x^k#

but #I_n=e^{-x}int x^n e^x dx#

so

#int x^n e^x dx = e^x sum_{k=0}^n (-1)^k((n!)/(k!))x^k#