IMSL C# Numerical Library

Cdf.InverseGamma Method 

Evaluates the inverse of the gamma cumulative probability distribution function.

public static double InverseGamma(
   double p,
   double a
);

Parameters

p
A double specifying the probability at which the function is to be evaluated.
a
A double specifying the shape parameter, a. This must be positive.

Return Value

A double specifying the probability that a gamma random variable takes a value less than or equal to this value is p.

Remarks

Method InverseGamma evaluates the inverse distribution function of a gamma random variable with shape parameter a, that is, it determines x={\rm InverseGamma} (p, a), such that

P = \frac{1}{{\Gamma \left( a \right)}}\int_o^x 
            {e^{ - t} } t^{a - 1} dt

where \Gamma(\cdot) is the gamma function. The probability that the random variable takes a value less than or equal to x is P. See the documentation for routine Gamma for further discussion of the gamma distribution.

InverseGamma uses bisection and modified regula falsi to invert the distribution function, which is evaluated using method Gamma.

See Also

Cdf Class | Imsl.Stat Namespace | Example