Routine ID: G106 | |
---|---|
Author(s): K.S. Kölbig | Library: MATHLIB |
Submitter: | Submitted: 01.05.1990 |
Language: Fortran | Revised: 15.03.1993 |
Function subprogram GAMDIS calculates the gamma distribution function (incomplete gamma function)
$P(x,a)\; =\; 1\Gamma (a)\; \int $_{0}^{x} e^{-t} t^{a-1} dt
for real arguments $x\; \ge 0$ and a > 0.
Structure:
FUNCTION subprogram
User Entry Name: GAMDIS
Files Referenced: Unit 6
External References: GAMMA (C302), ALGAMA (C304),
MTLMTR (N002), ABEND (Z035)
Usage:
In any arithmetic expression, GAMDIS(X,A) has the value $P(X,A)$ ,
where GAMDIS, X and A are of type REAL.
Method:
The method is described in Ref. 1.
Accuracy:
Approximately six digits are correct.
Error handling:
Error G106.1: $X<0$
or $A\; \le 0$
.
Error G106.2: Difficulties of convergence (unlikely).
The function value is set equal to zero, and a message is written on
Unit 6, unless subroutine MTLSET (N002) has been called.
Notes:
This subprogram is based on a Fortran program for the incomplete gamma functions published in Ref. 2.
References: