How do you differentiate f(x)=(e^x+x)(x^2-x)f(x)=(ex+x)(x2x) using the product rule?

1 Answer
May 31, 2016

f^'(x)=x(3x-2)+e^x(x^2+x-1)

Explanation:

The product rule for two functions is

(g(x)h(x))^'=g^'(x)h(x)+g(x)h^'(x)

In this case, let g(x)=e^x+x and h(x)=x^2-x. Taking derivatives gives g^'(x)=e^x+1 and h^'(x)=2x-1. Now plugging these expressions into the formula gives

f^'(x)=(e^x+1)(x^2-x)+(e^x+x)(2x-1)

Now distribute and simplify

f^'(x)=x^2e^x-xe^x+x^2-x+2xe^x-e^x+2x^2-x

f^'(x)=3x^2-2x+x^2e^x+xe^x-e^x

f^'(x)=x(3x-2)+e^x(x^2+x-1)