By considering the integral of the function $f(z) = exp(-az^2)$, with $a > 0$, around an appropriate contour, show that the integral
$$ I(p,a) = \int_{-\infty+ip}^{\infty+ip} exp(-az^2)dz$$
which is evaluated along the line $Im(z) = p$, independent of the real number $p$.
I really have no idea of which contour to evaluate this along. I have verified that the integrand is analytic over all of the complex plane but not sure how exactly to proceed.
Consider the integral
$$\oint_C dz \, e^{-a z^2}$$
where $C$ is the rectangle having vertices $-R+i p$, $R+i p$, $R$, $-R$, in that order. Then this integral is
$$\int_{-R+i p}^{R+i p} dx \, e^{-a x^2} + i \int_p^{-p} dy \, e^{a (y+i R)^2} \\ + \int_R^{-R} dx \, e^{-a x^2} + i \int_{-p}^{p} dy \, e^{a (y-i R)^2}$$
By Cauchy's theorem, the integral is zero. Also, note that the second and fourth integrals vanish as $R \to \infty$ (as $e^{-a R^2}$). Thus,
$$\int_{-\infty+i p}^{\infty+i p} dx \, e^{-a x^2} = \int_{-\infty}^{\infty} dx \, e^{-a x^2}$$
independent of $p$.