Digital Library of Mathematical Functions
About the Project
NIST
5 Gamma FunctionComputation

§5.21 Methods of Computation

An effective way of computing \mathop{\Gamma\/}\nolimits\!\left(z\right) in the right half-plane is backward recurrence, beginning with a value generated from the asymptotic expansion (5.11.3). Or we can use forward recurrence, with an initial value obtained e.g. from (5.7.3). For the left half-plane we can continue the backward recurrence or make use of the reflection formula (5.5.3).

Similarly for \mathop{\ln\/}\nolimits\mathop{\Gamma\/}\nolimits\!\left(z\right), \mathop{\psi\/}\nolimits\!\left(z\right), and the polygamma functions.

Another approach is to apply numerical quadrature (§3.5) to the integral (5.9.2), using paths of steepest descent for the contour. See Schmelzer and Trefethen (2007).

For a comprehensive survey see van der Laan and Temme (1984, Chapter III). See also Borwein and Zucker (1992).

For the computation of the q-gamma and q-beta functions see Gabutti and Allasia (2008).