Integrating a product of exponentials and error functions
Solution 1:
I think it's best to just proceed as is natural
$\displaystyle \begin{aligned}\int_0^{\infty}x^2e^{-\delta x^2}\text{erf}(\gamma x)\; dx &= \frac{2}{\sqrt{\pi}}\sum_{n=0}^{\infty}\frac{(-1)^n\gamma^{2n+1}}{n!(2n+1)}\int_0^{\infty} e^{-\delta x^2}x^{2n+3}\; dx\\ &= \frac{1}{\sqrt{\pi}}\sum_{n=0}^{\infty}\frac{(-1)^n\gamma^{2n+1}\Gamma(n+2)}{n!(2n+1)\delta^{n+2}}\\ &=\frac{1}{\sqrt{\pi}}\sum_{n=0}^{\infty}\frac{(-1)^n\gamma^{2n+1}(n+1)}{\delta^{n+2}(2n+1)}\\ &=\frac{1}{\delta^{\frac{3}{2}}\sqrt{\pi}}\left(\frac{1}{2}\sum_{n=0}^{\infty}(-1)^n\left(\frac{\gamma}{\sqrt{\delta}}\right)^{2n+1}+\frac{1}{2}\sum_{n=0}^{\infty}\frac{(-1)^n\left(\frac{\gamma}{\sqrt{\delta}}\right)^{2n+1}}{2n+1}\right)\\ &=\frac{1}{2\delta^{\frac{3}{2}}\sqrt{\pi}}\left(\frac{\gamma\sqrt{\delta}}{\gamma^2+\delta}+\arctan\left(\frac{\gamma}{\sqrt{\delta}}\right)\right)\end{aligned}$
Where the only non-trivial facts used was the common expression $\displaystyle \int_0^{\infty}e^{-x^2}x^n\; dx=\frac{\Gamma\left(\frac{n+1}{2}\right)}{2}$. Also, note that I used the Maclaurin series for arctangent, and so we need to have a restriction on $\displaystyle \frac{\gamma}{\sqrt{\delta}}$.
Solution 2:
Let $\mathcal{I}(\gamma)= \int_0^\infty x^2\exp(-\delta x^2)\operatorname{erf}(\gamma x)\, \mathrm{d} x$, then $I^\prime(\gamma) = \frac{2}{\sqrt{\pi}} \int_0^\infty x^3 \exp(-x^2 \left( \delta + \gamma^2 \right) ) \mathrm{d} x = \frac{1}{(\gamma^2 + \delta)^2} \frac{1}{\sqrt{\pi}}$.
Integrating: $$ I(\gamma) = \int_0^\gamma \frac{1}{\sqrt{\pi}} \frac{1}{(\gamma^2+\delta)^2} \mathrm{d} \gamma = \frac{\gamma }{2 \sqrt{\pi } \delta \left(\gamma ^2+\delta \right)}+\frac{1}{2 \sqrt{\pi } \delta ^{3/2}} \arctan\left(\frac{\gamma }{\sqrt{\delta }}\right) $$