Boost logo

Boost :

From: Beman Dawes (beman_at_[hidden])
Date: 2000-06-08 07:58:36

At 11:35 PM 6/7/00 +0200, Jens Maurer wrote:

>Csaba Szepesvari wrote:
>> 3) checking conformance
>> When an rng is passed along, the client might want to have a means
>> checking if it received an appropriate one (appropriate
>Ok. The plan is to have an enum
>enum random_distribution { random_uniform_int, [...] random_normal }
>and an appropriate "static const" member within each distribution.
>Or do we want a traits class (more extensible than a member) like
>this (similar to std::iterator_traits<>)?
>template<class T>
>class random_traits {
> static const random_distribution = ...

My general sense is that the random number library is already quite
feature rich, particularly from the standpoint of a casual user. If
you try to solve all problems you will end up with something only
experts will use. A problem presented as "the client might want..."
doesn't sound serious enough to warrant more than a very simple
change, if any change at all.

>> As a
>> result you can not have two linear congruential generators with
>> parameters in the same program
>Yes, you can. LCGs with different parameters have different types
>(note the template value parameters), thus the "static" members are
>actually disjoint.

You might want to point that out in the docs if you haven't done so



Boost list run by bdawes at, gregod at, cpdaniel at, john at