∫+∞−∞e−x2dx\int_{-\infty}^{+\infty} e^{-x^2} dx with complex analysis

Inspired by this recently closed question, I’m curious whether there’s a way to do the Gaussian integral using techniques in complex analysis such as contour integrals.

I am aware of the calculation using polar coordinates and have seen other derivations. But I don’t think I’ve ever seen it done with methods from complex analysis. I am ignorant enough about complex analysis to believe it can somehow be done without knowing how it would be done.


What follows is a list of solutions that I enjoy, and use complex analysis either implicitly or explicitly. I will update the list as I come up with more. (Note: Solution 4 is my favorite, and is completely complex analysis oriented. I also quite like Solution 6.)

First, let u=x2, du=2xdx. Then our integral becomes ex2dx=0u12eudu=Γ(12). where Γ(s) is the Gamma function.

Solution 1:
Since Γ(1s)Γ(s)=πsinπs for all complex s, we conclude Γ(12)=π.

Solution 2: Recall the Beta function, B(x,y)=10tx1(1t)y1dt=Γ(x)Γ(y)Γ(x+y). Setting x=y=12 we have


To evaluate this, set t=sin2(x) to find (Γ(12))2=π202sinxcosxsinxcosxdt=π.
Alternatively, we could evaluate the last integral by choosing branch’s such that the integrand is analytic on C[0,1] and then integrating around this cut. (The residue then comes from the residue at infinity)

Solution 3: Setting s=12 in the duplication formula, Γ(s)Γ(s+12)=π212sΓ(2s), yields Γ(12)=π.

Solution 4: My personal favorite:
Recall the functional equation for the zeta function, namely that πz2Γ(z2)ζ(z)=π1z2Γ(1z2)ζ(1z). Taking the limit as z1, we know that ζ(z)1z1 and Γ(1z2)21(z1) so that we must have the equality π12Γ(12)=2ζ(0). By taking the limit in the right half plane as s0 using the identity ζ(s)=ss1s1{u}usdu, which holds for σ>0, we can find that ζ(0)=12. (notice the pole/zero cancellation). Consequently Γ(12)=π.

Solution 5: From complex integration, for a,b>0 we have the identity (1ix)a(1+ix)bdx=22abπΓ(a+b1)Γ(a)Γ(b). Set a=12,b=32 to find that
1ix(1+x2)32dx=2πΓ(12)2. Hence 01(1+x2)32dx=πΓ(12)2. Since the integrand on left hand side has anti derivative xx2+1+C, it follows that the integral is 1 and henceΓ(12)=π.

Solution 6: More with the Beta function. Consider the Mellin Transform M(1(1+t)a)(z):=0tz1(1+t)adt=B(az,z). The last equality follows by substituting v=11+t, and then rewriting the integral as 10vaz1(1v)z1dv. Now, plug in a=1 and z=12 to get 01t(1+t)dt=Γ(12)2 and then let t=x2 to find

Solution 7: We can also prove the result by using Stirling’s formula. Admittedly, this isn’t really using complex analysis, but I find it interesting.

Since zΓ(z)=Γ(z+1) we see that
By Stirling’s formula,

\binom{2n}{n}\frac{1}{4^{n}}\sim\frac{1}{\sqrt{\pi n}}\ \text{as}\ n\rightarrow\infty



Using the fact that \lim_{n\rightarrow\infty}\left(1+\frac{a}{n}\right)^{n}=e^{a}, it then follows that


Consequently, taking the limit as n\rightarrow\infty in the formula \Gamma\left(\frac{1}{2}\right)=\frac{\Gamma\left(n+\frac{1}{2}\right)}{n!}\frac{4^{n}}{\binom{2n}{n}} yields \Gamma\left(\frac{1}{2}\right)=\sqrt{\pi}.

Hope that helps,

Remark: All of the formulas used here can be proven without use the fact that \Gamma(1/2)=\sqrt{\pi}, so that none of these are cyclic. This is mainly worth pointing out for 4.

Edit: I put what were solutions 2 and 3 together since they were not different.

Source : Link , Question Author : JasonMond , Answer Author : Did

Leave a Comment