# Evaluating $\int(2x^2+1)e^{x^2}dx$

$$\int(2x^2+1)e^{x^2}dx$$

The answer of course: $$\int(2x^2+1)e^{x^2}\,dx=xe^{x^2}+C$$

But what kind of techniques we should use with problem like this ?

-
@Babak Sorouh thanks . –  Frank Aug 20 '12 at 0:23

You can expand the integrand, and get

$$2x^2e^{x^2}+e^{x^2}=$$

$$x\cdot 2x e^{x^2}+1\cdot e^{x^2}=$$

Note that $x'=1$ and that $(e^{x^2})'=2xe^{x^2}$ so you get

$$=x\cdot (e^{x^2})'+(x)'\cdot e^{x^2}=(xe^{x^2})'$$

Thus you integral is $xe^{x^2}+C$. Of course, the above is integration by parts in disguise, but it is good to develop some observational skills with problems of this kind.

-

As @Peter note above, you can integrate this by separating the integrand and integrating by parts: \begin{align} \int(2x^2+1)e^{x^2}dx &=\int2x^2e^{x^2}dx+\int e^{x^2}dx\\ &=\int x(2xe^{x^2})dx+\int e^{x^2}dx\\ &= \int x\left(\frac{d}{dx}e^{x^2}\right)dx\ + \int e^{x^2}dx\\ &= xe^{x^2}-\int e^{x^2}dx+ \int e^{x^2}dx= xe^{x^2} + C \end{align}

-
$\quad$:+)$\quad$ –  amWhy Mar 13 '13 at 0:58
Look at the integral $$\int 2x^2e^{x^2}\, dx.$$ Try integrating by parts as follows. $u = x$, $dv = 2xe^{x^2}dx$, $v = e^{x^2}$, $du = dx$.