Open System Services Library Calls Reference Manual (G06.29+, H06.08+, J06.03+)

tgamma(3) OSS Library Calls Reference Manual
NAME
tgamma - Computes the true gamma function
LIBRARY
H-series and J-series native Guardian processes: $SYSTEM.ZDLLnnn.ZCREDLL
32-bit H-series and J-series OSS processes: /G/system/zdllnnn/zcredll
64-bit H-series and J-series OSS processes: /G/system/zdllnnn/ycredll
SYNOPSIS
#include <math.h>
double tgamma(
double x);
PARAMETERS
x Specifies a positive double value.
DESCRIPTION
The tgamma( ) function computes the true gamma function of x. In contrast, the lgamma( )
function and the gamma( ) function compute the logarithm of gamma.
NOTES
This function is implemented only for the IEEE_float oating-point option. Applications using
this function cannot be compiled if the specified floating-point option is Tandem_float.
RETURN VALUES
Upon successful completion, the tgamma() function returns the true gamma of x.
If the value of x is a negative integer, NaN is returned and errno is set to [EDOM].
If the value of x is NaN, NaN is returned.
If the value of x is positive infinity, x is returned.
If the value of x is negative infinity, NaN is returned and errno is set to [EDOM].
If the value of x is positive or negative zero, HUGE_VAL is returned and errno is set to
[ERANGE]
If the result would cause overflow, +HUGE_VAL or -HUGE_VAL (with the same sign as the
correct value of the function) is returned and errno is set to [ERANGE].
ERRORS
If any of the following conditions occurs, the tgamma() function sets errno to the corresponding
value:
[EDOM] The value of x is a negative integer or negative infinity.
[ERANGE] The value to be returned is positive or negative zero or would cause overflow.
RELATED INFORMATION
Functions: exp(3), lgamma(3), log(3), tgammaf(3), tgammal(3).
Files: math(4).
STANDARDS CONFORMANCE
This function conforms to the ISO/IEC 9899:1999 standard.
This function conforms to the IEEE Std 1003.1, 2004 Edition.
732 Hewlett-Packard Company 527187-017