RandomG.GammaDistribution

gamma distribution f=x^(alpha-1)*exp(-x/theta)/(gamma(alpha)*theta^alpha) alpha has to be bigger than 1, for alpha<1 use gammaD(alpha)=gammaD(alpha+1)*pow(r.uniform!(T),1/alpha) from Marsaglia and Tsang, ACM Transaction on Mathematical Software, Vol. 26, N. 3 2000, p 363-372

Members

Functions

getRandom
T getRandom(T a, T t)

returns a single random number

opCall
GammaDistribution opCall(U a, S args)

chainable call style initialization of variables (thorugh a call to randomize)

randomize
U randomize(U b, T a, T t)

initializes b with gamma distribued random numbers

randomizeOp
U randomizeOp(S delegate(T) op, U b, T a, T t)

maps op on random numbers (of type T) and initializes b with it

Static functions

create
GammaDistribution create(RandomG r, T alpha, T theta)
Undocumented in source. Be warned that the author may not have intended to support it.

Variables

alpha
T alpha;
Undocumented in source.
r
RandomG r;
Undocumented in source.
theta
T theta;
Undocumented in source.

Meta