A short study of the gamma function

In the last exercise of the course Topology and Multivariable Calculus (MAA202) last semester, we have a kinda nice (but skipped) exercise. So I'll try to tackle it today.

Exercise

For x>0x > 0, we define Euler’s Gamma function by

Γ(x)=0+tx1etdt \Gamma(x) = \int_0^{+\infty} t^{x-1} e^{-t} \mathrm{d}t

1. Prove that ΓC0(R+)\Gamma \in \mathcal{C}^0(\mathbb{R}_+^*).

2. (a) Show that Γ(x+1)=xΓ(x) \Gamma(x+1) = x\Gamma(x) for all x>0x > 0.

2. (b) Deduce that Γ(n)=(n1)!\Gamma(n) = (n-1)! for all nNn \in \mathbb{N}^*.

So, let me try...

My attempt

1. Ahh... What to do... It's obvious :( but I can't prove it! Hmm, maybe DCT? Let's try unfolding the term ete^{-t}. Since ex=exp(x)=k=0xkk!e^x = \exp(x) = \sum_{k=0}^{\infty} \frac{x^k}{k!}, we have

Γ(x)=0+tx1k=0(1)ktkk!dt=0+k=0(1)ktk+x1k!dt \Gamma(x) = \int_0^{+\infty} t^{x-1} \sum_{k=0}^{\infty} \frac{(-1)^k t^k}{k!} \mathrm{d}t = \int_0^{+\infty} \sum_{k=0}^{\infty} \frac{(-1)^k t^{k+x-1}}{k!} \mathrm{d}t

No... This doesn't look so good. (I planned to swap the sum with the integral, using some theorems...) If they're swapped (even if it works), then one must (infinitely) sum the integrals 0+(1)ktk+x1k!dt\int_0^{+\infty} \frac{(-1)^k t^{k+x-1}}{k!} \mathrm{d}t for all kk, which, very clearly, the integral diverges (since the antiderivative of ttct \mapsto t^c is ttc+1ct \mapsto \frac{t^{c+1}}{c}, and limt+εtc+1=±\lim_{t \to +\infty} \varepsilon t^{c+1} = \pm \infty (diverges, as a simple evaluation of polynomials at infinity) for any ε>0\varepsilon > 0.

Let us observe Γ(x)\Gamma(x) for x]0,1[x \in ]0, 1[. We have Γ(1)=0+t0etdt=[et]0+=0(1)=1\Gamma(1) = \int_0^{+\infty} t^0 e^{-t} \mathrm{d}t = [-e^{-t}]_0^{+\infty} = 0-(-1) = 1. Ahh it doesn't tell me anything.

Can we prove that Γ\Gamma is differentiable everywhere in ]0,+[]0, +\infty[ first? Then it would follow that it is continuous... No. It's too complicated swapping the derivative with the improper integral.

Uh... How about let Γn(x)=nn+1tx1etdt\Gamma_n(x) = \int_n^{n+1} t^{x-1} e^{-t} \mathrm{d}t? Then Γ(x)=n=0Γn(x)\Gamma(x) = \sum_{n=0}^\infty \Gamma_n(x). Note that for us to be sure, we'd need to prove first that the integral from the definition of Γ\Gamma converges as it tends to infinity (because limx+ϕ(x)=\lim_{x \to +\infty} \phi(x) = \ell implies limn+ϕ(n)=\lim_{n \to +\infty} \phi(n) = \ell).

Hmm... No. We don't really need to. The function ϕx(y)=0ytx1etdt=k=0y1Γk(x)+yytx1etdt\phi_x(y) = \int_0^y t^{x-1} e^{-t} \mathrm{d}t = \sum_{k=0}^{\lfloor y \rfloor -1} \Gamma_k(x) + \int_{\lfloor y \rfloor}^y t^{x-1} e^{-t} \mathrm{d}t is increasing because tx1et>0t^{x-1} e^{-t} > 0 for all t>0t > 0, and bounded by ϕx(y)\phi_x(\lceil y \rceil).

No, no, stop, stop. This is too complicated than what it should be. Let's recall Proposition 4.1.3.

Proposition 4.1.3. Let II and JJ be two intervals of R\mathbb{R}. Let f ⁣:I×JCf \colon I \times J \to \mathbb{C}. Let x0Ix_0 \in I. Assume that

  • for all xIx \in I, tf(x,t)t \mapsto f(x, t) is piecewise continuous,
  • for all tJt \in J, xf(x,t)x \mapsto f(x, t) is continuous at x0x_0,
  • there exists φ\varphi integrable on JJ and VV a neighborhood of x0x_0 such that for all xV,tJ,f(x,t)φ(t)x \in V, t \in J, |f(x,t)| \leq \varphi(t),

then the map

g(x)=Jf(x,t)dt g(x) = \int_J f(x, t) \mathrm{d}t

is well-defined and continuous at x0x_0.

The sad thing is that, in this chapter, the lecture notes didn't fully prove things, so there are a lot of gaps and it's a bit hard to follow. bruhhh sad. Anyway, let us go back to the 1.

Let x0]0,+[x_0 \in ]0, +\infty[ be any number.

Let f(x,t)=tx1etf(x, t) = t^{x-1} e^{-t} be defined on I×JI \times J where I:=]0,+[I := ]0, +\infty[ and J:=[0,+[J := [0, +\infty[. Then,

Ok. Let me restart this from square zero, all over again, for φ\varphi. Divide into three cases. Case 1. 0<x0<10 < x_0 < 1. Let φ(t)=tx0et\varphi(t) = t^{x_0} e^{-t}. Ah shit this is fucking insane. Perturbation doesn't work.

Let's do it the ugly way. No cases on x0x_0 now. Define

φ(t)={1 if t1tx0et otherwise \varphi(t) = \begin{cases} 1 & \text{ if } t \leq 1 \\ t^{x_0} e^{-t} & \text { otherwise} \end{cases}

Clearly, f(x,t)=tx1et1|f(x, t)| = t^{x-1} e^{-t} \leq 1 for all 0t10 \leq t \leq 1 (no matter the neighborhood of xx; we don't even need to care). Now, for t>1t > 1, f(x,t)=tx1ettx0et=φ(t)|f(x, t)| = t^{x-1} e^{-t} \leq t^{x_0} e^{-t} = \varphi(t) for all x1x0x-1 \leq x_0, so we can easily assign V=[x02,x0+1]V = [\frac{x_0}{2}, x_0+1] as a neighborhood which gives f(x,t)φ(t)|f(x, t)| \leq \varphi(t). And we've proved that the old φ\varphi is integrable on any interval (not necessary compact) of [0,+[[0, +\infty[, now the new φ\varphi only differs from the old one in [0,1][0, 1], so the new one's integral is bounded by the old one plus one, hence integrable.

By 4.1.3., we have Γ(x)=g(x)=0+tx1etdt\Gamma(x) = g(x) = \int_0^{+\infty} t^{x-1} e^{-t} \mathrm{d}t well-defined, and continuous at x0x_0. Since we assumed x0x_0 to be any positive real, gg is continuous everywhere in ]0,+[]0, +\infty[. Therefore, ΓC0(R+)\Gamma \in \mathcal{C}^0(\mathbb{R}_+^*). \square

2. (a) Hmm... I think we can do integration by parts, right? Let f ⁣:ttxf \colon t \mapsto t^x and let gg be such that g ⁣:tetg' \colon t \mapsto e^{-t}, then abfg=[fg]ababgf\int_a^b f g' = [fg]_a^b - \int_a^b gf'. (Note that ff and gg are defined on ]0,+[]0, +\infty[). Clearly, gg is tett \mapsto -e^{-t}. So 0+txetdt=[txet]0+0+etxtx1dt \int_0^{+\infty} t^x e^{-t} \mathrm{d}t = [-t^x e^{-t}]_0^{+\infty} - \int_0^{+\infty} -e^{-t} x t^{x-1} \mathrm{d}t for x>0x > 0.

Now, let us calculate [txet]0y[-t^x e^{-t}]_0^y for y]0,+[y \in ]0,+\infty[.

[txet]0y=yxey(0xe0)=yxey[-t^xe^{-t}]_0^y = -y^x e^{-y} - (-0^xe^{-0}) = -y^x e^{-y}

Clearly, as y+y \to +\infty, this quantity tends to zero (because (yyx)O(yey)(y \mapsto y^x) \in \mathcal{O}(y \mapsto e^{y}). So, limy+[txet]0y=0\lim_{y \to +\infty} [-t^x e^{-t}]_0^y = 0.

Coming back to the integration by parts, we have

Γ(x+1)=0+txetdt=0+etxtx1dt=x0+ettx1dt=xΓ(x) \Gamma(x+1) = \int_0^{+\infty} t^x e^{-t} \mathrm{d}t = -\int_0^{+\infty} -e^{-t}xt^{x-1}\mathrm{d}t = x\int_0^{+\infty} e^{-t}t^{x-1}\mathrm{d}t = x \Gamma(x) for any x>0x > 0. This completes the proof. \square

2. (b) This is very easy. Compute Γ(1)=1\Gamma(1) = 1, then let us do an induction that Γ(n)=(n1)!\Gamma(n) = (n-1)!. Suppose Γ(n)=(n1)!\Gamma(n) = (n-1)!, then let us prove that Γ(n+1)=n!\Gamma(n+1) = n!. By 2. (a), we have Γ(n+1)=nΓ(n)=n(n1)!=n!\Gamma(n+1) = n \Gamma(n) = n (n-1)! = n!. This completes the induction. \square

Afterthought

It took me way too long to finish the 1. and I don't see how one can do it faster (with approximately the same level of rigor).

Ok, so now I'm ready to watch this. Hmmm too lazy to watch everything lol (skipped the logarithm part), but it's a nice video! What if I try to reconstruct a function Γ~C0(R+)\widetilde{\Gamma} \in \mathcal{C}^0(\mathbb{R}_+^*) by myself, such that it satisfies the property of the gamma function... Ah no, well, the function is unique anyway, so it's left to prove that it's unique.

Here I'll give myself two bonus exercises:

Bonus 1 (Bohr–Mollerup theorem)

Prove that the function f ⁣:R+Rf \colon \mathbb{R_+^*} \to \mathbb{R} defined by the following properties:

is unique. Note that I thought it would be just a simple exercise, but a quick Wikipedia search shows that this is a full textbook theorem! Maybe too hard for me lol.

Bonus 2

The map xlimNNxk=1Nkx+k x \mapsto \lim_{N \to \infty} N^x \prod_{k=1}^N \frac{k}{x+k} defined on ]0,+[]0, +\infty[ is exactly the same as the map x0+tx1etdt x \mapsto \int_0^{+\infty} t^{x-1} e^{-t} \mathrm{d}t on ]0,+[]0, +\infty[.

Comment. Well, I think it's enough to prove that both satisfy the characterization of the gamma function, and by applying Bohr-Mollerup theorem, since the function is unique, they must be the same.

Well, for now I'm too lazy to do this, but hopefully I'll come back to this one later.

Bonus 3

(Really bonus in the sense that I don't really think I can make it but well, why not state it here) Find the analytic continuation of the gamma function defined on ]0,+[]0, +\infty[ (to the whole domain CZ\mathbb{C} \setminus \mathbb{Z}_-).