Integral of exponential within a region Are there methods to compute the following integral for $a \leq b$? Here $x\in\mathbb{R}$
$$
\int\limits_{a \leq -\frac{x^2}{2} \leq b} \frac{1}{\sqrt{2\pi}} e^{-\frac{x^2}{2}}\,dx
$$
Substitution
The error function is
$$
\text{erf}(z) = \frac{2}{\sqrt{\pi}} \int_0^z e^{-t^2} dt
$$
Using the substitution $t^2=\frac{x^2}{2}$ we have $2dt = dx$ and $\sqrt{-b}\leq t \leq \sqrt{-a}$
$$
\frac{1}{\sqrt{2}}\cdot \frac{2}{\sqrt{\pi}}\int_{\sqrt{-b}}^{\sqrt{-a}} e^{-t^2}dt = \frac{1}{\sqrt{2}}\cdot \left[\frac{2}{\sqrt{\pi}}\int_{0}^{\sqrt{-a}} e^{-t^2}dt + \frac{2}{\sqrt{\pi}}\int^0_{\sqrt{-b}} e^{-t^2} dt\right]
$$
Using the definition of error function and substituting $t' = -t$
$$
\frac{1}{\sqrt{2}}\left[\text{erf}(\sqrt{-a}) - \frac{2}{\sqrt{\pi}}\int_0^{-\sqrt{-b}} e^{-t^2} dt\right] = \frac{1}{\sqrt{2}}\left[\text{erf}(\sqrt{-a}) - \text{erf}(-\sqrt{-b})\right]
$$
 A: You can not compute it directly. But you can use normal distribution in other to have a very accurate estimate. In fact by supposing that $b\leq0$, the region $a\leq -\frac{x^2}{2}\leq b$ is the same as $\{\sqrt{-2b}\leq x\leq \sqrt{-2a}\}\cup\{-\sqrt{-2a}\leq x\leq -\sqrt{-2b}\}$.
So, $\begin{align*}
\int_{a\leq -\frac{x^2}{2}\leq b} \frac{1}{\sqrt{2\pi}}e^{-\frac{x^2}{2}}dx &= \int_{\sqrt{-2b}}^{\sqrt{-2a}} \frac{1}{\sqrt{2\pi}}e^{-\frac{x^2}{2}}dx + \int_{-\sqrt{-2a}}^{-\sqrt{-2b}} \frac{1}{\sqrt{2\pi}}e^{-\frac{x^2}{2}}dx\\
 &= \left[\Phi(\sqrt{-2a}) - \Phi(\sqrt{-2b})\right] + \left[\Phi(-\sqrt{-2b}) - \Phi(-\sqrt{-2a})\right]\\
&= 2\left[1+\Phi(\sqrt{-2a}) - \Phi(\sqrt{-2b})\right]
\end{align*}$
where $\Phi(.)$ is the normal cumulating distribution function.
A: We can use $\operatorname{erf}$ in place of $\Phi$.  By definition,
$$
\frac{d}{dx}\operatorname{erf}(x) = \frac{2}{\sqrt{\pi}}e^{-x^2}
\tag1$$
Now start with
$$
V = \int\limits_{a \leq -\frac{x^2}{2} \leq b} \frac{1}{\sqrt{2\pi}} e^{-\frac{x^2}{2}}\,dx
$$
where $a < b \le 0$.
Divide into two equal parts, $x>0$ and $x<0$, to get
$$
V = \frac{\sqrt2}{\sqrt{\pi}}\int_{\sqrt{-2b}}^{\sqrt{-2a}}e^{-x^2/2}dx
$$
In order to match $(1)$ substitute $x=\sqrt{2}\,y$, $dx = \sqrt{2}\,dy$ to get
$$
V =\frac{2}{\sqrt{2\pi}}\int_{\sqrt{-b}}^{\sqrt{-a}} e^{-y^2} dy
=\frac{2}{\sqrt{\pi}}\left(
\frac{\sqrt{\pi}}{2}\operatorname{erf}(\sqrt{-a})-
\frac{\sqrt{\pi}}{2}\operatorname{erf}(\sqrt{-b})
\right)
=\operatorname{erf}(\sqrt{-a})-\operatorname{erf}(\sqrt{-b})
$$
A: I think but I am not sure that it could be solved similarly to the Gaussian integral proof. https://en.wikipedia.org/wiki/Gaussian_integral. Firstly, you consider the integral squared, then you consider the second integral that is multiplied with a variable $y$. After that, you make a transform to polar coordinates and then make the substitution like the one in the link.
It reminds me of the Gaussian integral.
