# From differentiating xe^x, how do you deduce int_0^2xe^x from that?

Feb 21, 2018

${e}^{2} + 1$ or $8.389$

#### Explanation:

You can't find the integral of a function with its derivative.

We can do this by, differentiating $x {e}^{x}$. Say the derivative is $f \left(x\right)$. We can only find the integral of $x {e}^{x}$, using $f \left(x\right)$, by saying:

$\int \left(\int f \left(x\right) \mathrm{dx}\right) \mathrm{dx}$

But that just reduces to:

$\int x {e}^{x} \mathrm{dx}$.

Let's solve for that, then.

Applying integration by parts, that is:

$\int u v \mathrm{dx}$, where $u$ and $v$ are functions, is:

$u \int v \mathrm{dx} - \int u ' \left(\int v \mathrm{dx}\right) \mathrm{dx}$

Here, $u = x$ and $v = {e}^{x}$. Inputting:

$x \int {e}^{x} \mathrm{dx} - \int x ' \left(\int {e}^{x} \mathrm{dx}\right) \mathrm{dx}$

$x \cdot {e}^{x} - \int {e}^{x} \mathrm{dx}$

${e}^{x} x - {e}^{x} + C$

Now we solve the definite integral.

Since we have ${\int}_{0}^{2} x {e}^{x} \mathrm{dx}$, we input:

$\left({e}^{2} \cdot 2 - {e}^{2} + C\right) - \left({e}^{0} \cdot 0 - {e}^{0} + C\right)$

$\left({e}^{2} \left(2 - 1\right) + C\right) - \left(0 - 1 + C\right)$

${e}^{2} + C + 1 - C$

${e}^{2} + 1$, which is equal to:

$8.389$

Feb 21, 2018

${\int}_{0}^{2} \setminus x {e}^{x} \setminus \mathrm{dx} = {e}^{2} + 1$

#### Explanation:

Let us start, as indicated, by differentiating the function $x {e}^{x}$ using the product rule:

$\frac{d}{\mathrm{dx}} x {e}^{x} = x \left(\frac{d}{\mathrm{dx}} {e}^{x}\right) + \left(\frac{d}{\mathrm{dx}} x\right) {e}^{x}$
$\setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus = x {e}^{x} + {e}^{x}$

And so we we can write:

$x {e}^{x} = \frac{d}{\mathrm{dx}} \left(x {e}^{x}\right) - {e}^{x}$

If we now integrate wrt $x$ we can deduce:

$\int \setminus x {e}^{x} \setminus \mathrm{dx} = \int \setminus \frac{d}{\mathrm{dx}} \left(x {e}^{x}\right) \setminus \mathrm{dx} - \int \setminus {e}^{x} \setminus \mathrm{dx}$
$\setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus = x {e}^{x} - {e}^{x} + C$

So we can readily evaluate the definite integral:

${\int}_{0}^{2} \setminus x {e}^{x} \setminus \mathrm{dx} = {\left[x {e}^{x} - {e}^{x}\right]}_{0}^{2}$
$\setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus = \left(2 {e}^{2} - {e}^{2}\right) - \left(0 - {e}^{0}\right)$
$\setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus = 2 {e}^{2} - {e}^{2} + 1$
$\setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus \setminus = {e}^{2} + 1$