The Goodness of
Fit is evaluated by calculating

(2.12) |

where

(2.13) |

and

= | (2.14) | ||

= | (2.15) | ||

= | (2.16) |

is Euler gamma function. as well as are called

Neither complete nor incomplete gamma functions are a part
of ANSI Fortran specification, although the complete gamma function
is often provided with language libraries. For example, in UNIX
Euler gamma function is described in section 3 of the manual, and
can be loaded from in `libm.a`

.

There exists a series expansion
for
and
a continued fraction expansion for
.
The former
converges rapidly for *x* < *a*+1, and the latter converges
rapidly for *x*>*a*+1. Consequently when writing a subroutine to
calculate *Q*(*a*, *x*), we should check the regime we are in, and
use an expansion that converges fastest in that regime:

The expansions are as follows:

Continued fraction expansions are so hard to read (and typeset) that printers invented a special simplified notation for them, which helps programmers too, and so, the above expansion in that notation would look as follows:

(2.20) |