home *** CD-ROM | disk | FTP | other *** search
/ minnie.tuhs.org / unixen.tar / unixen / PDP-11 / Trees / V6 / usr / man / man3 / gamma.3 < prev    next >
Encoding:
Text File  |  1975-06-26  |  652 b   |  44 lines

  1. .th GAMMA III 5/15/74
  2. .sh NAME
  3. gamma \*- log gamma function
  4. .sh SYNOPSIS
  5. .br
  6. .ft B
  7. jsr    pc,gamma
  8. .s3
  9. double gamma(x)
  10. .br
  11. double x;
  12. .ft R
  13. .sh DESCRIPTION
  14. If \fIx\fR is passed (in fr0)
  15. .it gamma
  16. returns
  17. ln |\*|\*G(\*|\fIx\fR\*|)\*|| (in fr0).
  18. The sign of
  19. \*G(\*|\fIx\fR\*|)
  20. is returned in the external integer
  21. .it signgam.
  22. The following C program might be
  23. used to calculate
  24. \*G:
  25. .s3
  26.     y = gamma(x);
  27. .br
  28.     if (y > 88.)
  29. .br
  30.         error( );
  31. .br
  32.     y = exp(y);
  33. .br
  34.     if(signgam)
  35. .br
  36.         y = \*-y;
  37. .sh DIAGNOSTICS
  38. The c-bit is
  39. set on negative integral arguments and the
  40. maximum value is returned.
  41. There is no error return for C programs.
  42. .sh BUGS
  43. No error return from C.
  44.