Gamma |
public class GammaDistribution : ProbabilityDistribution
The GammaDistribution type exposes the following members.
| Name | Description | |
|---|---|---|
| GammaDistribution(Double, Double) | Initializes a new instance of the GammaDistribution class. | |
| GammaDistribution(Double, Double, RandomGenerator) | Initializes a new instance of the GammaDistribution class. |
| Name | Description | |
|---|---|---|
| Generator | Returns the random generator used by the distribution to generate the random values. (Inherited from ProbabilityDistribution) | |
| Location | Gets the inverse scale parameter of the distribution. | |
| Order | Gets the shape parameter of the distribution. |
| Name | Description | |
|---|---|---|
| CDF |
Gives the cumulative probability at x.
(Overrides ProbabilityDistributionCDF(Double)) | |
| Equals | Determines whether the specified object is equal to the current object. (Inherited from Object) | |
| Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object) | |
| GetHashCode | Serves as the default hash function. (Inherited from Object) | |
| GetType | Gets the Type of the current instance. (Inherited from Object) | |
| Initialize | Initializes the parameters for the gamma distribution. | |
| MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object) | |
| NextDouble |
Generates a random value distributed according to the distribution.
(Overrides ProbabilityDistributionNextDouble) | |
|
Gives the probability density at x.
(Overrides ProbabilityDistributionPDF(Double)) | ||
| Quantile |
Gives the pth quantile of the distribution.
(Overrides ProbabilityDistributionQuantile(Double)) | |
| ToString | Returns a string that represents the current object. (Inherited from Object) |
| Name | Description | |
|---|---|---|
| _invTheta | Cached coefficients used by the gamma distribution implementation. | |
| algorithmGD | Cached flag indicating whether algorithm GD is used. | |
| alpha | Cached coefficients used by the gamma distribution implementation. | |
| b | Cached coefficients used by the gamma distribution implementation. | |
| c | Cached coefficients used by the gamma distribution implementation. | |
| d | Cached coefficients used by the gamma distribution implementation. | |
| exponentialDistribution | Cached exponential helper distribution used by the gamma distribution implementation. | |
| generator | Pointer to generator. (Inherited from ProbabilityDistribution) | |
| normalDistribution | Cached helper distributions used by the gamma distribution implementation. | |
| q0 | Cached coefficients used by the gamma distribution implementation. | |
| r | Cached coefficients used by the gamma distribution implementation. | |
| s | Cached coefficients used by the gamma distribution implementation. | |
| s2 | Cached coefficients used by the gamma distribution implementation. | |
| scale | Cached coefficients used by the gamma distribution implementation. | |
| si | Cached coefficients used by the gamma distribution implementation. |
Return Gamma distributed random deviates according to:
a-1 -bx
b (bx) e
p (x) dx = ---------------- dx for x > 0
a,b Gamma(a)
= 0 otherwise
//
The arguments must satisfy the conditions:
a > 0 (positive)
b != 0 (non-zero)
References:
For parameter a >= 1 corresponds to algorithm GD in:
J. H. Ahrens and U. Dieter, Generating Gamma Variates by a
Modified Rejection Technique, Comm. ACM, 25, 1, 47-54 (1982).
For parameter 0 < a < 1 corresponds to algorithm GS in:
J. H. Ahrens and U. Dieter, Computer Methods for Sampling
from Gamma, Beta, Poisson and Binomial Distributions,
Computing, 12, 223-246 (1974).