C305: Gamma Function for Complex Argument

Author(s): K.S. Kölbig Library: MATHLIB
Submitter: Submitted: 02.05.1966
Language: Fortran Revised: 15.03.1993

Function subprograms CGAMMA and WGAMMA calculate the gamma function

displaymath81

for complex arguments tex2html_wrap_inline83 .

The double-precision version WGAMMA is available only on computers which support a COMPLEX*16 Fortran data type.

Structure:

FUNCTION subprograms
User Entry Names: CGAMMA, WGAMMA
Files Referenced: Unit 6
External References: MTLMTR, ABEND

Usage:

In any arithmetic expression,

CGAMMA(Z) or WGAMMA(Z) has the value tex2html_wrap_inline85

where CGAMMA is of type COMPLEX, WGAMMA is of type COMPLEX*16, and Z has the same type as the function name.

Method:

The method is described in Ref. 1.

Accuracy:

CGAMMA (except on CDC and Cray computers) has full single-precision accuracy. For most values of the argument Z, WGAMMA (and CGAMMA on CDC and Cray computers) has an accuracy of approximately one significant digit less than the machine precision.

Error handling:

Error C305.1: tex2html_wrap_inline87 The function value is set equal to zero, and a message is written on Unit 6, unless subroutine MTLSET (N002) has been called.

References:

  1. Y.L. Luke, The special functions and their approximations, v.II, (Academic Press, New York 1969) 304-305
tex2html_wrap_inline89

Michel Goossens Tue Jun 4 21:04:37 METDST 1996