Proof of probability of a value lying between $\pm \sigma$ from the mean of a gaussian distribution

38 Views Asked by At

I wish to show that the likelihood of a value lying between $\pm\sigma$ from the mean of a Gaussian distribution is $\approx 68.2\%$. The Gaussian distribution function is given by $$f(x)=\frac{1}{2\sqrt{2\pi}}\exp\bigg(-\frac{(x-\mu)^2}{2\sigma^2}\bigg)$$ Centering this about the mean and integrating from $-\sigma$ to $\sigma$ we get $$\frac{1}{2\sqrt{2\pi}}\int_{-\sigma}^{\sigma}\exp\bigg(-\frac{x^2}{2\sigma^2}\bigg)\ \mathrm{d}x$$ Defining an integral, $I$ to be $$I=\int_{-\sigma}^{\sigma}\exp\bigg(-\frac{x^2}{2\sigma^2}\bigg) \ \mathrm{d}x$$we can write $$I^2=\int_{-\sigma}^{\sigma}\exp\bigg(-\frac{x^2}{2\sigma^2}\bigg) \ \mathrm{d}x\int_{-\sigma}^{\sigma}\exp\bigg(-\frac{y^2}{2\sigma^2}\bigg) \ \mathrm{d}y$$ $$=\int_{-\sigma}^{\sigma}\int_{-\sigma}^{\sigma}\exp\bigg(-\frac{1}{2\sigma^2}(x^2+y^2)\bigg)\mathrm{d}x\ \mathrm{d}y$$ Converting to polar coordinates $$=\int_0^{2\pi}\int_0^{\sigma}r\exp\bigg(-\frac{r^2}{2\sigma^2}\bigg)\ \mathrm{d}r\ \mathrm{d}\theta$$ $$=\int_0^{2\pi}\bigg[-\sigma^2\exp\bigg(-\frac{r^2}{2\sigma^2}\bigg)\bigg]_0^\sigma\ \mathrm{d}\theta$$ $$=\int_0^{2\pi}\sigma^2-\sigma^2\exp\bigg(-\frac{1}{2}\bigg)\ \mathrm{d}\theta$$ $$=2\pi\sigma^2\bigg(1-\exp\bigg(-\frac{1}{2}\bigg)\bigg)$$ So the original integral can be calcualted $$\frac{1}{2\sqrt{2\pi}}\int_{-\sigma}^{\sigma}\exp\bigg(-\frac{x^2}{2\sigma^2}\bigg)\ \mathrm{d}x=\sqrt{1-e^{-1/2}}$$ However this gives a value of $\approx 0.627$ or $62.7\%$, which is not the desired value. Can anyone help me as to where I've gone wrong?