4

I am looking at the expectation of a normal distribution with respect to a function of $x$. To simplify the problem, I considered the following integral: \begin{equation} \int_{-\infty}^\infty \frac{e^{-x^2}}{1+ae^{-x}} \ dx. \end{equation} To solve this, I considered the complex integral: \begin{equation} \oint_C \frac{e^{-z^2}}{1+ae^{-z}} \ dz, \end{equation} with the contour $C = C_1 + C_R$ where $C_1: z = x$ with $x \in [-R,R]$ and $C_R: z = R e^{i \theta}$, with $\theta \in [0,\pi]$.

First I considered the $C_R$ part: \begin{align} \int_0^\pi \frac{e^{-R^2 e^{2i \theta}}}{1 + a e^{-R e^{i \theta}}} i R e^{i \theta} d \theta \end{align} The standard argument here is to consider $R \to \infty$ and show that this integral hopefully decays to 0. However, $e^{-R^2 e^{2i \theta}}$ changes to positive at $\pi/2$ and so this integral actually grows.

If instead, I consider the rectangular contour with $C_1: z = x$ as before, $C_2: z = R + iy$, with $y \in [0,2\pi]$, $C_3: z = x + i(2\pi)$ and $C_4: z = -R + iy$, we can show that the integrals $C_2$ and $C_4$ decay to zero \begin{align} \int_0^{2\pi} \frac{e^{-(R+iy)^2}}{1+ae^{-(R+iy)}} i \ dy \stackrel{R \to \infty}{\to} 0. \end{align} Hence we are left with the pole at $z_0 = \ln a + i\pi$ which can be computed from Cauchy's integral formula $$\oint \frac{f(z) \ dz}{g(z)(z-z_0)} = 2\pi i \frac{f(z_0)}{g'(z_0)} = 2\pi i e^{-z_0^2}$$. The $C_1$ integral is the original integral. However the third integral is slightly different. Is there anyway to proceed here, or does someone have another way to evaluate this integral analytically? $$\int_{C_3} = e^{4 \pi^2} \int_R^{-R} \frac{e^{-x^2}e^{-4 \pi i x}}{1 + a e^{-x}} \ dx = -e^{4 \pi^2} \int_{-R}^{R} \frac{e^{-x^2}e^{-4 \pi i x}}{1 + a e^{-x}} \ dx $$

Gregory
  • 3,641
  • Doubt an analytical solution is obtainable here, but it's not too hard to find a good approximation for your function. We have $f(0) = \sqrt{\pi}$, $f(1) = \sqrt{\pi}/2$ and $f(a) \sim \frac{e^{1/4}\sqrt{\pi}}{a}$ as $a\to \infty$. Something simple like $f(a) \approx \frac{\sqrt{\pi}}{a+1}$ is already a decent approximation for $a\lesssim 2$. – Winther Nov 03 '18 at 23:22
  • A series expansion may be an alternative to doing the contour integral. – asd Nov 05 '18 at 05:51
  • Is a positive ? – Upax Nov 10 '18 at 20:21

0 Answers0