33.0 PP 1201 1205 Gamma Beta and Error Functions
33.0 PP 1201 1205 Gamma Beta and Error Functions
In several places in this book we have made mention of the gamma, beta and error
functions. These convenient functions appear in a number of contexts and here
we gather together some of their properties. This appendix should be regarded
merely as a reference containing some useful relations with a minimum of formal
proofs.
which converges for n > 0. Replacing n by n + 1 in (A1) and integrating the RHS
by parts, we find
∞
Γ(n + 1) = xn e−x dx
0
∞
n −x ∞
= −x e 0 + nxn−1 e−x dx
∞ 0
1201
Downloaded from https://www.cambridge.org/core. IIT Kanpur, on 24 Sep 2020 at 09:06:59, subject to the Cambridge Core terms of use,
available at https://www.cambridge.org/core/terms. https://doi.org/10.1017/CBO9781139164979.031
GAMMA, BETA AND ERROR FUNCTIONS
Γ(n )
6
n
−4 −3 −2 −1 1 2 3 4
−2
−4
−6
In fact, equation (A3) serves as a definition of the factorial function even for
non-integer n. For negative n the factorial function is defined by
(n + m)!
n! = , (A4)
(n + m)(n + m − 1) · · · (n + 1)
where m is any positive integer that makes n + m > 0. Different choices of m
(> −n) do not lead to different values for n!. A plot of the gamma function is
given in figure A1.1, where it can be seen that the function is infinite for negative
integer values of n, in accordance with (A4).
By letting x = y 2 in (A1), we immediately obtain another useful representation
of the gamma function given by
∞
y 2n−1 e−y dy.
2
Γ(n) = 2 (A5)
0
1
Setting n = 2 we find the result
∞
∞ √
e−y dy = e−y dy =
2 2
Γ 12 = 2 π,
0 −∞
where have used the standard integral discussed in subsection 6.4.2. From this
result, Γ(n) for half-integral n can be found using (A2). Some immediately
derivable factorial values of half integers are
3 √ 1 √ 1 1√
3 3√
− 2 ! = −2 π, − 2 ! = π, 2 ! = 2 π, 2 ! = 4 π.
1202
Downloaded from https://www.cambridge.org/core. IIT Kanpur, on 24 Sep 2020 at 09:06:59, subject to the Cambridge Core terms of use,
available at https://www.cambridge.org/core/terms. https://doi.org/10.1017/CBO9781139164979.031
A1.2 THE BETA FUNCTION
From (A1), the extended definition of the factorial function (which is valid for n > −1) is
given by
∞ ∞
n! = xn e−x dx = en ln x−x dx. (A8)
0 0
If we let x = n + y, then
y
ln x = ln n + ln 1 +
n
y y2 y3
= ln n + − 2 + 3 − · · · .
n 2n 3n
Substituting this result into (A8), we obtain
∞
y y2
n! = exp n ln n + − 2 + · · · − n − y dy.
−n n 2n
Thus, when n is sufficiently large, we may approximate n! by
∞ √ √
2
n! ≈ en ln n−n e−y /(2n) dy = en ln n−n 2πn = 2πn nn e−n ,
−∞
1203
Downloaded from https://www.cambridge.org/core. IIT Kanpur, on 24 Sep 2020 at 09:06:59, subject to the Cambridge Core terms of use,
available at https://www.cambridge.org/core/terms. https://doi.org/10.1017/CBO9781139164979.031
GAMMA, BETA AND ERROR FUNCTIONS
The beta function may also be written in terms of the gamma function as
Γ(m)Γ(n)
B(m, n) = . (A11)
Γ(m + n)
erf(0) = 0,
erf(∞) = 1, erf(−x) = −erf(x).
√
By making the substitution y = 2u in (A12), we find
√2x
1
e−y /2 dy.
2
erf(x) = √
2π 0
The cumulative probability function Φ(x) for the standard Gaussian distribution
(discussed in section 26.9.1) may be written in terms of the error function as
1204
Downloaded from https://www.cambridge.org/core. IIT Kanpur, on 24 Sep 2020 at 09:06:59, subject to the Cambridge Core terms of use,
available at https://www.cambridge.org/core/terms. https://doi.org/10.1017/CBO9781139164979.031
A1.3 THE ERROR FUNCTION
follows
x
1
e−y /2 dy
2
Φ(x) = √
2π −∞
x
1 1
e−y /2 dy
2
= +√
2 2π 0
1 x
= + erf √ .
2 2
It is also sometimes useful to define the complementary error function
∞
2
e−u du.
2
erfc(x) = 1 − erf(x) = √ (A13)
π x
1205
Downloaded from https://www.cambridge.org/core. IIT Kanpur, on 24 Sep 2020 at 09:06:59, subject to the Cambridge Core terms of use,
available at https://www.cambridge.org/core/terms. https://doi.org/10.1017/CBO9781139164979.031