I want to compute something similar to the Gaussian integral like below: \begin{align} I = \int_{-\infty}^{\infty} \ e^{(i\pi x^2)}dx \end{align} WolframAlpha says the result is $I = \sqrt{i}$ but I have no idea how to get this answer. Below is the derivation I tried: \begin{align} I^2 &= \left(\int_{-\infty}^{\infty} e^{(i\pi x^2)}dx \right) \left(\int_{-\infty}^{\infty} e^{(i\pi y^2)}dy \right)\\ &= \int_{-\infty}^{\infty} e^{\{i\pi (x^2+y^2)\}}dx \end{align} Let $x = r \cos{\theta}, \ y = r \sin{\theta}$, then \begin{align} I^2 &= \int_{0}^{2\pi}\int_{0}^{\infty} e^{(i\pi r^2) } r \ dr \ d\theta \\ &= 2 \pi \int_{0}^{\infty} e^{(i\pi r^2) } r \ dr \end{align} Let $s=r^2$, then $ds = 2r dr$. Thus, \begin{align} I^2 &= 2\pi\int_0^{\infty}e^{(i\pi r^2)}\cdot\frac{1}{2}\cdot 2rdr \\ &= \pi \int_0^{\infty}e^{(i\pi s)}ds \\ &= \frac{1}{i} e^{(i\pi s)}|_{0}^{\infty} \end{align} Here, I get a problem. I tried to compute the limit: $$\displaystyle{\lim_{s\rightarrow\infty}} e^{(i\pi s)} = \displaystyle{\lim_{s\rightarrow\infty}} \cos{(\pi s)} + i \sin{(\pi s)}$$ but I think it becomes indeterminate.
Am I doing something wrong? How do you get $I=\sqrt{i}$ ?

