How do you integrate #int x^2e^x# from 0 to 1 by integration by parts method?

2 Answers
Nov 4, 2016

# int_0^1x^2e^xdx = e - 2 #

Explanation:

If you are studying maths, then you should learn the formula for Integration By Parts (IBP), and practice how to use it:

# intu(dv)/dxdx = uv - intv(du)/dxdx #, or less formally # intudv=uv-intvdu #

I was taught to remember the less formal rule in word; "The integral of udv equals uv minus the integral of vdu". If you struggle to remember the rule, then it may help to see that it comes a s a direct consequence of integrating the Product Rule for differentiation.

Essentially we would like to identify one function that simplifies when differentiated, and identify one that simplifies when integrated (or is at least is integrable).

So for the integrand #x^2e^x#, hopefully you can see that #x^2# simplifies when differentiated and e^x remains unchanged under differentiation or integration.

Let # { (u=x^2, => , (du)/dx=2x), ((dv)/dx=e^x, =>, v=e^x ) :}#

Then plugging into the IBP formula gives us:
# int_0^1(x^2)(e^x)dx = [(x^2)(e^x)]_0^1 - int_0^1(e^x)(2x)dx #
# :. int_0^1x^2e^xdx = [x^2e^x]_0^1 - 2int_0^1xe^xdx #
# :. int_0^1x^2e^xdx = (1e^1-0) - 2int_0^1xe^xdx #
# :. int_0^1x^2e^xdx = e - 2int_0^1xe^xdx # .... [1]

We will now need to apply IBP a second time to integrate #intxe^xdx#, and similarly #x# will simplify if differentiated

Let # { (u=x, => , (du)/dx=1), ((dv)/dx=e^x, =>, v=e^x ) :}#
# int_0^1(x)(e^x)dx = [(x)(e^x)]_0^1 - int_0^1(e^x)(1)dx #
# :. int_0^1xe^xdx = (1e^1-0) - int_0^1e^xdx #
# :. int_0^1xe^xdx = e - [e^x]_0^1#
# :. int_0^1xe^xdx = e - (e^1-e^0) #
# :. int_0^1xe^xdx = 1 #

Substituting this reulti nto [1] gives ud
# int_0^1x^2e^xdx = e - 2(1) #
Hence,
# int_0^1x^2e^xdx = e - 2 #

Nov 4, 2016

Use integration by parts twice, taking the x term as that which you derive, and the #e^x# term as that which you "anti-derive" both times.

Explanation:

The method of integration by parts can take a little practice before the answers start to jump out at you. Usually, the most challenging part of this method is figuring out what to derive and what to "anti-derive." You may use different variables, but I will be using this form in my explanation:

#uv-int v du#

I will show how to find the anti-derivative first, then evaluate.

First, we need to recognize that the derivative of #e^(x)# is just #e^x#. Because of this, we know that if we were to choose to derive the #e^x# term and take the antiderivative of the #x^2# term, we wouldn't get anywhere; we would just end up continually increasing the power of our x term. So, we can take #x^2# as our term to derive and #e^x# as our term to "anti-derive."

Thus, we can set #u = x^2#, and #du=2xdx#, and #dv=e^xdx# where #v=e^x#.

That gives us:

#x^2e^x-2int(xe^x)dx#

We still have that #xe^x# situation, so we can then follow the above process again quite similarly. Note that I have chosen to take the constant, 2, outside of the integral.

#u=x#, #du=dx#, #dv=e^xdx#, #v=e^x#

That gives us:

#x^2e^x-2[xe^x-int(e^x)dx#]

(Don't forget the terms you found in the first usage of integration by parts, or the 2!)

We can find the integral of #e^x#, so we are through with integration by parts. Thus, we have:

#x^2e^x-2xe^x+2e^x#

or #e^x(x^2-2x+2)#

To evaluate this with limits of integration from 0 to 1, we have:

#(1)^2e^(1)-2(1)e^(1)+2e^(1)#-#[(0)^2e^(0)-2(0)e^(0)+2e^(0)]#

Because #e^0 = 1#, we have:

#e-2e+2e-0+0-2#

And so, our final answer is:

#e-2#