PURPOSE:
=========

The purpose of this package is the computation of 
the incomplete gamma star function, gamma*(a,z), for
negative values of the argument z. This function is
related  to the lower incomplete gamma function, 
gamma(a,z), by

gamma*(a,z)=z**(-a)gamma(a,z)/GAMMA(a).

The gamma*(a,z) function is real for positive 
and negative values of a and z.


RANGE OF COMPUTATION
====================

 The code compute the function gamma*(a,z) for
a real and real negative z.


THIS PACKAGE CONTAINS THE FOLLOWING FILES: 
==========================================

1.  setprecision.f90 Includes the module set_precision that sets the 
                     various precisions used in the whole package.
 
2.  cons.f90        Includes the module Someconstants for internal 
                    global parameters

3.  constants       Data file for the module Someconstants 
                    
4.  gammaError.f90  Includes the module GammaError, with public routines
                    and functions for the computation of the error function, the
                    gamma function and other related functions. Some of these
                    routines are used by incgamNEG.

5.  incgamNEG.f90   Includes the module IncgamNEG, with the public routine
                    incgamstar for the computation of the incomplete
                    gamma star function.

6.  testgamstar.f90 Test program for the module IncgamNEG.

7.  OutGammStar     Expected results file 

8.  Makefile        "Make" file, including compiler/linker commands. 

When the file testgamstar.exe is executed, the file testGammStar (containing the
outputs of the test program) is created. It is then convenient
to compare testGammStar and outGammStar


DESCRIPTION OF THE MODULE incgamNEG
===================================

The public routine of the module incgamNEG is incgamstar, which
computes the incomplete gamma star function, gamma*(a,z).

CALLING SEQUENCE
 ----------------

 The calling sequence for the routine incgamstar is the following

 SUBROUTINE incgamstar(a,z,igam,ierr)
 REAL(r16), INTENT(IN) :: a
 REAL(r8), INTENT(IN) :: z
 REAL(r8), INTENT(OUT) :: igam
 INTEGER,  INTENT(OUT) :: ierr
 where r16 and r8 represents the available quadruple and
 double precision arithmetics, respectively. See the module
 set_precision for more details.

 The input parameter a should be given in quadruple 
 precision.

  Inputs and outputs
  ------------------

   Inputs:    
       a,   parameter of the function.
       z,   argument of the function.
    
    Outputs:
       igam,  function gamma*(a,z) 
       ierr , error flag
              ierr=0, computation succesful
              ierr=1, overflow/underflow problems. The computed function value 
                      is set to zero.
              ierr=2, the argument z is  out of range. The function value
                      is set to zero.

   Other routines included in the module incgamNEG which are used by 
   the routine incgamstar are:

   1. gseries: computes gamma*(a,z) using a series expansion. This
               routine is used when a is positive or a is negative but not
               close to an integer value.
   2. gsereps: computes gamma*(a,z) using a series expansion when a is negative 
               close to an integer value.
   3. gexpan:  computes gamma*(a,z) using a Poincare-type expansion. This
               routine is used for a positive. 
   4. incgamnegaeps:  computes gamma*(a,z) using a uniform asymptotic expansion.
                      This routine is used for a negative.
   5. incgamnegascal: computes a normalized function related to the gamma*(a,z).
                   
  
ACCURACY OF THE COMPUTED FUNCTION VALUES
=======================================

 The aimed relative accuracy for the function gamma*(a,z) 
 is close to 1.0e-13 in the whole range of parameters. 