gamma(3) Library Functions Manual gamma(3)

# NOMBRE¶

gamma, gammaf, gammal - (logaritmo de la) función gamma

# BIBLIOTECA¶

Biblioteca Matemática (libm, -lm)

# SINOPSIS¶

`#include <math.h>`
```[[a extinguir]] double gamma(double x);
[[a extinguir]] float gammaf(float x);
[[a extinguir]] long double gammal(long double x);```

Requisitos de Macros de Prueba de Características para glibc (véase feature_test_macros(7)):

gamma():

```
_XOPEN_SOURCE

|| /* Desde glibc 2.19: */ _DEFAULT_SOURCE

|| /* glibc <= 2.19: */ _BSD_SOURCE || _SVID_SOURCE```

gammaf(), gammal():

```
_XOPEN_SOURCE >= 600 || (_XOPEN_SOURCE && _ISOC99_SOURCE)

|| /* A partir de glibc 2.19: */ _DEFAULT_SOURCE

|| /* glibc <= 2.19: */ _BSD_SOURCE || _SVID_SOURCE```

# DESCRIPCIÓN¶

Estas funciones están obsoletas. En su lugar, emplee tgamma(3) o lgamma(3) según se adapte.

Para obtener una explicación de la función Gamma, consulte tgamma(3).

## versión BSD¶

The libm in 4.4BSD and some versions of FreeBSD had a gamma() function that computes the Gamma function, as one would expect.

## versión glibc¶

glibc has a gamma() function that is equivalent to lgamma(3) and computes the natural logarithm of the Gamma function.

Vea lgamma(3).

Vea lgamma(3).

# ATRIBUTOS¶

Para obtener una explicación de los términos usados en esta sección, véase attributes(7).

 Interfaz Atributo Valor gamma(), gammaf(), gammal() Seguridad del hilo MT-Unsafe race:signgam

# ESTÁNDARES¶

Because of historical variations in behavior across systems, this function is not specified in any recent standard. It was documented in SVID 2.

# NOTAS¶

## Historia¶

4.2BSD had a gamma() that computed ln(|Gamma(|x|)|), leaving the sign of Gamma(|x|) in the external integer signgam. In 4.3BSD the name was changed to lgamma(3), and the man page promises

"At some time in the future the name gamma will be rehabilitated and used for the Gamma function"

This did indeed happen in 4.4BSD, where gamma() computes the Gamma function (with no effect on signgam). However, this came too late, and we now have tgamma(3), the "true gamma" function.