
1 Apr
2009
1 Apr
'09
1:09 a.m.
AMDG Barco You wrote:
Hi Henning,
Thanks for your reply! but, g = generator(rng, boost::bernoulli_distribution<>(p));
Try g.distribution() = boost::bernoulli_distribution<>(p); or just construct the variate generator whenever you need a random number: std::cout << generator(rng, boost::bernoulli_distribution<>(p))() << std::endl; In Christ, Steven Watanabe