1 .\" Copyright 2002 Walter Harms (walter.harms@informatik.uni-oldenburg.de)
3 .\" %%%LICENSE_START(GPL_NOVERSION_ONELINE)
4 .\" Distributed under GPL
7 .\" Modified 2003-11-18, aeb: historical remarks
9 .TH GAMMA 3 2021-03-22 "GNU" "Linux Programmer's Manual"
11 gamma, gammaf, gammal \- (logarithm of the) gamma function
16 .BI "double gamma(double " x ");"
17 .BI "float gammaf(float " x ");"
18 .BI "long double gammal(long double " x ");"
24 Feature Test Macro Requirements for glibc (see
25 .BR feature_test_macros (7)):
31 || /* Since glibc 2.19: */ _DEFAULT_SOURCE
32 || /* Glibc <= 2.19: */ _BSD_SOURCE || _SVID_SOURCE
38 _XOPEN_SOURCE >= 600 || (_XOPEN_SOURCE && _ISOC99_SOURCE)
39 || /* Since glibc 2.19: */ _DEFAULT_SOURCE
40 || /* Glibc <= 2.19: */ _BSD_SOURCE || _SVID_SOURCE
43 These functions are deprecated: instead, use either the
47 functions, as appropriate.
49 For the definition of the Gamma function, see
52 The libm in 4.4BSD and some versions of FreeBSD had a
54 function that computes the Gamma function, as one would expect.
58 function that is equivalent to
60 and computes the natural logarithm of the Gamma function.
68 For an explanation of the terms used in this section, see
76 Interface Attribute Value
81 T} Thread safety MT-Unsafe race:signgam
87 Because of historical variations in behavior across systems,
88 this function is not specified in any recent standard.
89 It was documented in SVID 2.
95 .RI ln(|Gamma(| x |)|),
98 in the external integer
100 In 4.3BSD the name was changed to
102 and the man page promises
105 "At some time in the future the name gamma will be rehabilitated
106 and used for the Gamma function"
109 This did indeed happen in 4.4BSD, where
111 computes the Gamma function (with no effect on
113 However, this came too late, and we now have
115 the "true gamma" function.
116 .\" The FreeBSD man page says about gamma() that it is like lgamma()
117 .\" except that is does not set signgam.
118 .\" Also, that 4.4BSD has a gamma() that computes the true gamma function.