Calculus · Integrals with a Parameter
What is \( \left(\tfrac12\right)! \)? The question sounds meaningless until you meet the Gamma function, which extends the factorial to non-integer numbers. Together with its sibling, the Beta function, it turns a huge class of difficult integrals into simple arithmetic. This post introduces both and shows how to use them.
Why \(a, b > 0\)? The integral is improper at both ends when the exponents are negative. Near \(x = 0\) the integrand behaves like \(x^{a-1}\), which is integrable exactly when \(a - 1 > -1\), i.e. \(a > 0\). Near \(x = 1\) it behaves like \((1 - x)^{b-1}\), integrable exactly when \(b > 0\). (These are the p-integral rules from the posts on improper integrals.)
When \(a\) and \(b\) are natural numbers, the integrand is just a polynomial, and the Beta function is an ordinary definite integral. For example, \( \mathrm B(2, 2) = \int_0^1 x(1 - x)\,dx = \frac16 \). The power of the Beta function is that it works for any positive exponents.
The substitution \(x = 1 - t\) swaps the two factors:
\[ \mathrm B(a, b) = \mathrm B(b, a). \]Where it comes from. Integrate by parts with \( u = (1 - x)^{b-1} \), \( dv = x^{a-1}dx \):
\[ \mathrm B(a, b) = \underbrace{\Big[\tfrac{x^a}{a}(1 - x)^{b-1}\Big]_0^1}_{=0} + \frac{b - 1}{a}\int_0^1 x^a(1 - x)^{b-2}\,dx. \]Now write \( x^a = x^{a-1} - x^{a-1}(1 - x) \), so the last integral equals \( \mathrm B(a, b - 1) - \mathrm B(a, b) \). Therefore
\[ a\,\mathrm B(a, b) = (b - 1)\big[\mathrm B(a, b - 1) - \mathrm B(a, b)\big] \;\Longrightarrow\; (a + b - 1)\,\mathrm B(a, b) = (b - 1)\,\mathrm B(a, b - 1). \]Applying the recursion repeatedly until the second argument reaches 1, and using \( \mathrm B(a, 1) = \int_0^1 x^{a-1}dx = \frac1a \), we get for natural numbers \(m, n\):
Without the Beta function you would have to expand \((1 - x)^3\) and integrate four terms.
Different substitutions give equivalent formulas that are often easier to recognise:
In the previous posts we showed that this integral converges for every \(a > 0\) (the exponential wins at infinity; at \(0\) the integrand behaves like \(x^{a-1}\)), and that it converges uniformly on every interval \([\alpha, \beta] \subset (0, \infty)\), so \(\Gamma\) is continuous. In fact it is infinitely differentiable, by Leibniz's rule.
Proof: integrate by parts with \( u = x^a \), \( dv = e^{-x}dx \):
\[ \Gamma(a + 1) = \int_0^\infty x^ae^{-x}\,dx = \underbrace{\big[-x^ae^{-x}\big]_0^\infty}_{=0} + a\int_0^\infty x^{a-1}e^{-x}\,dx = a\,\Gamma(a). \]Since \( \Gamma(1) = \int_0^\infty e^{-x}dx = 1 \), the functional equation gives \( \Gamma(2) = 1 \), \( \Gamma(3) = 2 \), \( \Gamma(4) = 3\cdot 2 = 6 \), and in general
\[ \Gamma(n + 1) = n! \qquad (n = 0, 1, 2, \dots). \]So \(\Gamma\) is a smooth curve passing through all the factorials, shifted by one. Note: \( \Gamma(1) = \Gamma(2) = 1 \), which matches \(0! = 1! = 1\).
Substitute \(x = t^2\) (\(dx = 2t\,dt\)) in the definition:
\[ \Gamma\Big(\frac12\Big) = \int_0^\infty x^{-1/2}e^{-x}\,dx = \int_0^\infty \frac{1}{t}e^{-t^2}\,2t\,dt = 2\int_0^\infty e^{-t^2}\,dt = 2\cdot\frac{\sqrt\pi}{2} = \sqrt\pi, \]using the Gaussian integral computed in the previous post. So the answer to the opening question is \( \left(\tfrac12\right)! = \Gamma\big(\tfrac32\big) = \tfrac12\Gamma\big(\tfrac12\big) = \frac{\sqrt\pi}{2} \).
Applying the functional equation \(n\) times:
\[ \Gamma\Big(n + \frac12\Big) = \Big(n - \frac12\Big)\Big(n - \frac32\Big)\cdots\frac12\,\Gamma\Big(\frac12\Big) = \frac{1\cdot 3\cdot 5\cdots(2n - 1)}{2^n}\sqrt\pi. \]Check it at \( a = \frac12 \): \( \Gamma\big(\frac12\big)^2 = \frac{\pi}{\sin(\pi/2)} = \pi \), consistent with \( \Gamma\big(\frac12\big) = \sqrt\pi \). For \(0 < a < 1\) it follows from the Beta-Gamma relation below (see Problem 6).
The integral definition only works for \(a > 0\). But the functional equation, read backwards as \( \Gamma(a) = \frac{\Gamma(a + 1)}{a} \), lets us define \(\Gamma\) for negative non-integers: step up until the argument is positive. The reflection formula gives the same values directly, which is how it allows Gamma to be extended to negative arguments.
Check with reflection (\(a = -\frac12\)): \( \Gamma\big(-\frac12\big)\Gamma\big(\frac32\big) = \frac{\pi}{\sin(-\pi/2)} = -\pi \), so \( \Gamma\big(-\frac12\big) = \frac{-\pi}{\sqrt\pi/2} = -2\sqrt\pi \). Same answer.
At \(a = 0, -1, -2, \dots\) the Gamma function is not defined: the recursion would require dividing by zero, and \(|\Gamma(a)| \to \infty\) near these points (in the reflection formula, \(\sin\pi a = 0\) there).
This is the formula that makes both functions practical: compute Beta integrals using known Gamma values. For natural numbers it reduces to the factorial formula of Section 2.3.
A proof using the tools from the previous post. For \(t > 0\), the substitution \(x = (1 + t)s\) in the definition of \(\Gamma\) gives
\[ \frac{\Gamma(a + b)}{(1 + t)^{a+b}} = \int_0^\infty s^{a+b-1}e^{-(1+t)s}\,ds. \]Multiply by \(t^{a-1}\), integrate in \(t\), and use the infinite-interval form of \(\mathrm B\):
\[ \Gamma(a + b)\,\mathrm B(a, b) = \int_0^\infty t^{a-1}\,dt\int_0^\infty s^{a+b-1}e^{-(1+t)s}\,ds. \]The integrand is positive, so the order of integration may be swapped. The inner integral in \(t\) is \( \int_0^\infty t^{a-1}e^{-ts}\,dt = \frac{\Gamma(a)}{s^a} \), hence
\[ \Gamma(a + b)\,\mathrm B(a, b) = \Gamma(a)\int_0^\infty s^{b-1}e^{-s}\,ds = \Gamma(a)\,\Gamma(b). \]The general technique: use a substitution to bring the integral to one of the standard forms, then read off the answer.
| If the integral looks like… | …recognise it as |
|---|---|
| \( \int_0^\infty x^{p}e^{-x}\,dx \) | \( \Gamma(p + 1) \) |
| \( \int_0^\infty x^{p}e^{-x^q}\,dx \) | substitute \( t = x^q \) → Gamma |
| \( \int_0^1 x^{p}(1 - x)^{q}\,dx \) | \( \mathrm B(p + 1, q + 1) \) |
| \( \int_0^{\pi/2} \sin^{p}\varphi\cos^{q}\varphi\,d\varphi \) | \( \frac12\mathrm B\big(\frac{p+1}{2}, \frac{q+1}{2}\big) \) |
| \( \int_0^\infty \frac{t^{p}}{(1 + t)^{q}}\,dt \) | \( \mathrm B(p + 1, q - p - 1) \) |
| Formula | Validity |
|---|---|
| \( \mathrm B(a, b) = \int_0^1 x^{a-1}(1 - x)^{b-1}\,dx \) | \(a, b > 0\) |
| \( \mathrm B(a, b) = \mathrm B(b, a) \) | \(a, b > 0\) |
| \( \mathrm B(a, b) = \frac{b-1}{a+b-1}\mathrm B(a, b - 1) \) | \(a > 0,\ b > 1\) |
| \( \mathrm B(m, n) = \frac{(m-1)!(n-1)!}{(m+n-1)!} \) | \(m, n \in \mathbb N\) |
| \( \Gamma(a) = \int_0^\infty x^{a-1}e^{-x}\,dx \) | \(a > 0\) |
| \( \Gamma(a + 1) = a\Gamma(a) \), \( \Gamma(n + 1) = n! \) | \(a > 0\), \(n = 0, 1, 2, \dots\) |
| \( \Gamma\big(\frac12\big) = \sqrt\pi \), \( \Gamma\big(n + \frac12\big) = \frac{(2n-1)!!}{2^n}\sqrt\pi \) | \(n \in \mathbb N\) |
| \( \Gamma(a)\Gamma(1 - a) = \frac{\pi}{\sin\pi a} \) | \(a \notin \mathbb Z\) |
| \( \mathrm B(a, b) = \frac{\Gamma(a)\Gamma(b)}{\Gamma(a + b)} \) | \(a, b > 0\) |
Try these before opening the solution. More solved problems are in Definite Integrals.
\( \mathrm B(3, 6) = \frac{2!\,5!}{8!} = \frac{240}{40320} = \frac{1}{168} \).
\( \Gamma\big(\frac72\big) = \frac52\cdot\frac32\cdot\frac12\sqrt\pi = \frac{15\sqrt\pi}{8} \). \( \Gamma\big(-\frac32\big) = \frac{\Gamma(-1/2)}{-3/2} = \frac{-2\sqrt\pi}{-3/2} = \frac{4\sqrt\pi}{3} \).
Put \(t = 2x\): \( \frac{1}{2^7}\int_0^\infty t^6e^{-t}\,dt = \frac{6!}{128} = \frac{720}{128} = \frac{45}{8} \).
\( \frac12\mathrm B\big(\frac52, \frac32\big) = \frac12\cdot\frac{\Gamma(5/2)\Gamma(3/2)}{\Gamma(4)} = \frac12\cdot\frac{\frac34\sqrt\pi\cdot\frac12\sqrt\pi}{6} = \frac{\pi}{32} \).
Put \(t = x^2\), \(dx = \frac12t^{-1/2}dt\): \( \frac12\int_0^\infty t^{3/2}e^{-t}\,dt = \frac12\Gamma\big(\frac52\big) = \frac{3\sqrt\pi}{8} \).
By the infinite-interval form, the integral equals \( \mathrm B(a, 1 - a) = \frac{\Gamma(a)\Gamma(1 - a)}{\Gamma(1)} = \Gamma(a)\Gamma(1 - a) \). Evaluating this integral independently (for example with complex analysis) gives \( \frac{\pi}{\sin\pi a} \), which is exactly how the reflection formula is proved for \(0 < a < 1\).
Put \(t = x^3\), \(dx = \frac13t^{-2/3}dt\): \( \frac13\int_0^1 t^{-2/3}(1 - t)^{-1/2}\,dt = \frac13\mathrm B\big(\frac13, \frac12\big) = \frac{\Gamma(1/3)\Gamma(1/2)}{3\,\Gamma(5/6)} = \frac{\sqrt\pi\,\Gamma(1/3)}{3\,\Gamma(5/6)} \). (Not every answer simplifies to elementary constants, and that's fine.)
The Beta and Gamma functions show the whole "integrals with a parameter" theory paying off: they are defined by improper integrals, their continuity comes from uniform convergence, their key formulas come from integration by parts and changing the order of integration. In return, they give you a short table of values that replaces pages of integration. The workflow to remember: substitute until you see a standard form, then let \(\Gamma\) do the arithmetic.
Next in the series: the Fourier integral, which builds a non-periodic function out of waves.