$E(\frac{1}{1+x^2})$ under a Gaussian This question is leading on from the following question.
https://math.stackexchange.com/questions/360275/e1-1x2-under-a-normal-distribution
Basically what is the $E\left(\frac{1}{1+x^2}\right)$ under a general Gaussian $\mathcal{N}(\mu,\sigma^2)$. I tried rewriting $\frac{1}{1+x^2}$ as a scalar mixture of Gaussians ($\propto \int\mathcal{N}(x|0,\tau^{-1})Ga(\tau|1/2,1/2)d\tau$). This also came to a halt, unless you folks have got a trick under your belt.
If this integral isn't analytical any sensible bounds?
 A: This is an idea how to solve it which uses the identity 
$$\frac{1}{S}=\int_0^\infty \exp(-tS)dt$$
which was proposed by Did here. You could use
\begin{align}E\left(\frac{1}{x^2+1}\right) &= \frac{1}{\sqrt{2\pi}}\int_0^\infty \int_{-\infty}^{\infty}\exp\left(-t(x^2+1)\right)\exp\left(-\frac{x^2}{2}\right)\mathrm dx \mathrm dt\\
&=\int_0^\infty \exp\left(-t\right)\left(1+2t\right)^{-\frac{1}{2}} \mathrm dt\\
&=\sqrt{\frac{e\pi}{2}}\left[\mbox{erf}\left(\sqrt{t+\frac{1}{2}}\right)\right]_0^\infty\\
&=\sqrt{\frac{e\pi}{2}}\left(1-\mbox{erf}\left(\sqrt{\frac{1}{2}}\right)\right)\end{align}
A: Let $f_\sigma(x) = \frac{1}{\sqrt{2\pi}\sigma}\exp\left(-\frac{x^2}{2\sigma^2}\right)$ be the Normal$(0,\sigma)$ PDF and $g(x) = \frac{1}{\pi}\left(1+x^2\right)^{-1}$ be the PDF of a Student t distribution with one d.f.  Because the PDF of a Normal$(\mu,\sigma)$ variable $X$ is $f_\sigma(x-\mu) = f_\sigma(\mu-x)$ (by symmetry), the expectation equals
$$\mathbb{E}_{\sigma,\mu}\left(\frac{1}{1+X^2}\right) =  \mathbb{E}_{\sigma,\mu}\left(\pi g(X)\right) = \int_\mathbb{R} f_\sigma\left((\mu-x)^2\right) \pi g(x)dx.$$
This is the defining formula for the convolution $(f\star \pi g)(\mu)$.  The most basic result of Fourier analysis is that the Fourier transform of a convolution is the product of Fourier transforms.  Moreover, characteristic functions (c.f.) are (up to suitable multiples) Fourier transforms of PDFs.  The c.f. of a Normal$(0,\sigma)$ distribution is
$$\widehat{f}_\sigma(t) = \exp(-t^2\sigma^2/2)$$
and the c.f. of this Student t distribution is
$$\widehat{g}(t) = \exp(-|t|).$$
(Both can be obtained by elementary methods.)  The value of the inverse Fourier transform of their product at $\mu$ is, by definition, 
$$\frac{1}{2\pi}\int_\mathbb{R} \widehat{f}_\sigma(t)\pi\widehat{g}(t) \exp(-i t \mu) dt =\frac{1}{2}\int_\mathbb{R} \exp(-t^2\sigma^2/2-|t|-i t \mu) dt.$$
Its calculation is elementary: carry it out separately over the intervals $(-\infty,0]$ and $[0,\infty)$ to simplify $|t|$ to $-t$ and $t$, respectively, and complete the square each time.  Integrals akin to the Normal CDF are obtained--but with complex arguments.  One way to write the solution is
$$\mathbb{E}_{\sigma,\mu}\left(\frac{1}{1+X^2}\right) = \frac{\sqrt{\frac{\pi }{2}} e^{-\frac{(\mu +i)^2}{2 \sigma ^2}} \left(e^{\frac{2 i \mu }{\sigma ^2}} \text{erfc}\left(\frac{1+i \mu }{\sqrt{2} \sigma }\right)-\text{erf}\left(\frac{-1+i\mu}{\sqrt{2} \sigma }\right)+1\right)}{2 \sigma }.$$
Here, $\text{erfc}(z) = 1 - \text{erf}(z)$ is the complementary error function where
$$\text{erf}(z) = \frac{2}{\sqrt{\pi}}\int_0^z \exp(-t^2)dt.$$
A special case is $\mu=0, \sigma=1$ for which this expression reduces to $$\mathbb{E}_{1, 0}\left(\frac{1}{1+X^2}\right)  = \sqrt{\frac{e\pi}{2}}\text{erfc}\left(\frac{1}{\sqrt{2}}\right)=0.65567954241879847154\ldots.$$
Here is contour plot of $\mathbb{E}_{\sigma,\mu}$ (on a logarithmic axis for $\sigma$).

