Function cmb_random_binomial
Defined in File cmb_random.h
Function Documentation
-
unsigned cmb_random_binomial(unsigned n, double p)
Binomial distribution, number of successes in n independent Bernoulli trials each with probability
p.Models a drawing process with replacement (or from an infinite pool).
Mean
np, variancenp(1-p).Performs the calculation by simulating the experiment.
See also https://en.wikipedia.org/wiki/Geometric_distribution