Integration of complex function how do we do start doing the following integral?

$$\int_{-\infty}^{\infty}e ^{-\pi(x^2a^2+2iux)}\,dx$$

Any help will be appreciated
NOTE: $i$ is the square root of $-1$.
 A: I apologise for not having a graphing software, therefore I'll have to describe the contour I used: it's a rectangle $\Gamma$ of vertices $+R$, $+R+i\frac{u}{a^2}$, $-R+i\frac{u}{a^2}$, -R, which we use counterclockwise.
By the Residues' Theorem we have
$$ 
\oint_\Gamma e^{-\pi a^2 z^2}\mathrm{d}z = 0.
$$ 
Splitting on the 4 segments:
$$
\int_{-R}^{R} e^{-\pi a^2x^2} \mathrm{d}x + \int_{0}^{u/a^2} e^{-\pi a^2(R+iy)^2}i \mathrm{d}y + \int_{R}^{-R} e^{-\pi a^2(x+iu/a^2)^2} \mathrm{d}x + \int_{u/a^2}^{0} e^{-\pi a^2(-R+iy)^2}i \mathrm{d}y=0. 
$$
It is easy to prove that the second and fourth integral tend to zero as $R$ approaches infinity, then, in that limit:
$$
\int_{-\infty}^{\infty} e^{-\pi a^2x^2} \mathrm{d}x = \int_{-\infty}^{\infty} e^{-\pi a^2(x+iu/a^2)^2} \mathrm{d}x
$$
$$
\frac{1}{a} = e^{\pi u^2 / a^2 }\int_{-\infty}^{\infty} e^{-\pi (a^2x^2+2iux)} \mathrm{d}x
$$
where we used 
$$
\int_{-\infty}^{\infty} e^{-\pi a^2x^2} \mathrm{d}x = \frac{1}{a}.
$$
Finally:
$$
\int_{-\infty}^{\infty} e^{-\pi (a^2x^2+2iux)} \mathrm{d}x = \frac{1}{a} e^{-\pi u^2 / a^2 }.
$$
