Function cmb_random_gamma

Function Documentation

static inline double cmb_random_gamma(const double shape, const double scale)

Gamma distribution on [0, oo) with shape parameter shape and scale parameter scale, both > 0.

Generalizes the Erlang distribution to noninteger n (here shape). The mean is shape * scale, the variance shape * scale^2.

Used for various servicing, waiting, and repair times in queuing systems, along the exponential and Erlang distributions.

See also https://en.wikipedia.org/wiki/Gamma_distribution