# Integral involving error function

Could someone help me in evaluating this integral please? :

$$\int_{0}^x t^2\exp(-t^2) dt$$

I spliced the integrand into $t\cdot t\cdot \exp(-t^2)$ then doing integral by parts I arrived to $-\frac{x}{2}\exp(-x^2)+\frac{1}{2}\text{erf}(x)$
But in my problem set the result is given by $-\frac{x}{2}\exp(-x^2) + \frac{\sqrt{\pi}}{4}\text{erf}(x)$
• The usual definition is $\text{erf}(x)=\frac{2}{\sqrt{\pi}}\int_0^x \exp(-t^2)dt$ – Frank Lu Dec 5 '16 at 20:29