Gamma function¶
Complex valued special functions.
- boring_math.special_functions.gamma.gamma(z: complex) complex¶
Gamma function valid for all complex values of z.
Note
Lanczos approximation of Gamma using
g = 7withn = 9terms. The values of g and n were chosen to balance accuracy with speed. Typically accurate to 13 correct decimal places.Code modified from the Wikipedia Lanczos appoximation article.
- boring_math.special_functions.gamma.gamma_real(x: float) float¶
Gamma function valid for all real values of x.