lgamma man page on 4.4BSD

Man page or keyword search:  
man Server   1065 pages
apropos Keyword Search (all sections)
Output format
4.4BSD logo
[printable version]

LGAMMA(3)		 BSD Library Functions Manual		     LGAMMA(3)

     lgamma gamma — log gamma function, gamma function

     #include <math.h>

     extern int signgam;

     lgamma(double x);

     gamma(double x);

     Lgamma(x) returns ln|Γ(x)|.

     The external integer signgam returns the sign of Γ(x).

     Gamma(x) returns Γ(x), with no effect on signgam.

     Do not use the expression “signgam∗exp(lgamma(x))” to compute g := Γ(x).
     Instead use a program like this (in C):

	   lg = lgamma(x); g = signgam∗exp(lg);

     Only after lgamma() has returned can signgam be correct.

     For arguments in its range, gamma() is preferred, as for positive argu‐
     ments it is accurate to within one unit in the last place.	 Exponentia‐
     tion of lgamma() will lose up to 10 significant bits.

     Gamma() and lgamma() return appropriate values unless an argument is out
     of range.	Overflow will occur for sufficiently large positive values,
     and non-positive integers.	 On the VAX, the reserved operator is
     returned, and errno is set to ERANGE For large non-integer negative val‐
     ues, gamma() will underflow.

     math(3), infnan(3)

     The lgamma function appeared in 4.3BSD.  The gamma function appeared in
     4.4BSD.  The name gamma() was originally dedicated to the lgamma() func‐
     tion, so some old code may no longer be compatible.

4.3 Berkeley Distribution      December 11, 1993     4.3 Berkeley Distribution

List of man pages available for 4.4BSD

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
Vote for polarhome
Free Shell Accounts :: the biggest list on the net