What is #f(x) = int x^2-2xe^(x)dx# if #f(0)=-2 #?

1 Answer
Apr 13, 2017

#f(x) = 1/3x^3 - 2e^x(x - 1) - 4#

Explanation:

Separate the integral.

#f(x) = int x^2dx - int 2xe^xdx#

The first integral is #1/3x^3#.

#f(x) = 1/3x^3 - int 2xe^xdx#

We will use integration by parts for the last integral. We let #u = 2x# and #dv = e^x#. Then #du = 2dx# and #v= e^x#.

#int 2xe^xdx = 2x(e^x) - int 2e^x#

#int2xe^xdx = 2xe^x - 2inte^x#

#int2xe^x = 2xe^x - 2e^x#

#int2xe^x = 2e^x(x - 1)#

We put the integral back together to find

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

We must now find the value of #C#. We know that when #x = 0#, #y= -2#, therefore:

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

#-2 = 0 + 2 + C#

#C = -4#

This means that #f(x) = 1/3x^3 - 2e^x(x - 1) - 4#.

Hopefully this helps!