0
$\begingroup$

I need to calculate the integral of a function $$f(x)=x^2e^{-x^2}$$ in the range of $a\leq |x|\leq b $.

My attempt: The integral can be divided in two integral according to range $$I=\int_{-b}^{-a}f(x)dx + \int_a^bf(x)dx $$ As it is clear that $f(x)$ is even function, so $$I=2\int_a^bf(x)dx $$ Now, integral can be divided into $$\int_{a}^{b}f(x)dx = \int_0^bf(x)dx-\int_0^af(x)dx$$Now by using this definition Integral, we can solve the Integral $$\int_0^ux^2e^{-q^2x^2}=\frac{1}{2q^3}\left(\frac{\sqrt{\pi}}{2}\Phi(qu)-qu e^{-q^2u^2} \right)$$ where $\Phi$ is CDF of standard normal distribution.

I am not sure whether I am correct or not.

$\endgroup$
9
  • $\begingroup$ What is $q$? In general, this integral can be computed via integration by parts. $\endgroup$ Dec 14, 2016 at 10:33
  • $\begingroup$ Write the integrand as $x.xe^{-x^{2}}$ and then use parts on $u=x, v=xe^{-x^{2}}$ $\endgroup$
    – user284001
    Dec 14, 2016 at 10:35
  • $\begingroup$ @ Oles Wohnzimmer: $q$ is a constant. $\endgroup$
    – Marcus
    Dec 14, 2016 at 10:43
  • $\begingroup$ I am more curious about limits. Is my attempt of handling with limits is wrong?? $\endgroup$
    – Marcus
    Dec 14, 2016 at 10:44
  • $\begingroup$ What is $\Phi$? $\endgroup$
    – 5xum
    Dec 14, 2016 at 10:45

1 Answer 1

0
$\begingroup$

Integrate by parts

\begin{equation} \int x^{2} \mathrm{e}^{-x^{2}} dx = \frac{1}{2} \sqrt{\pi} x^{2} \mathrm{erf}(x) - \sqrt{\pi} \int x \, \mathrm{erf}(x) dx \end{equation}

Integrate by parts again \begin{align} \int x \,\mathrm{erf}(x) dx &= x^{2} \mathrm{erf}(x) + \frac{1}{\sqrt{\pi}} x \mathrm{e}^{-x^{2}} - \int x \,\mathrm{erf}(x) dx - \frac{1}{\sqrt{\pi}} \int \mathrm{e}^{-x^{2}} dx \\ &= x^{2} \mathrm{erf}(x) + \frac{1}{\sqrt{\pi}} x \,\mathrm{e}^{-x^{2}} - \int x \mathrm{erf}(x) dx - \frac{1}{2} \mathrm{erf}(x) \\ &= \frac{1}{2} x^{2} \mathrm{erf}(x) + \frac{1}{2\sqrt{\pi}} x \mathrm{e}^{-x^{2}} - \frac{1}{4} \mathrm{erf}(x) \end{align}

Thus we have \begin{equation} \int x^{2} \mathrm{e}^{-x^{2}} dx = \frac{\sqrt{\pi}}{4} \mathrm{erf}(x) - \frac{1}{2} x \mathrm{e}^{-x^{2}} \end{equation}

$\endgroup$
1
  • $\begingroup$ You didn't touch my point. I want focus on limits with mod $\endgroup$
    – Marcus
    Dec 14, 2016 at 13:25

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .