Boost logo

Boost Users :

Subject: Re: [Boost-users] [Math/Statistical Distributions+Random] Random number generation
From: Marco Guazzone (marco.guazzone_at_[hidden])
Date: 2009-08-22 04:53:53


On Sat, Aug 22, 2009 at 4:22 AM, er<erwann.rogard_at_[hidden]> wrote:
> Marco Guazzone wrote:
>
>>
>> Thank you!
>> I've taken a look... Very interesting.
>
> Thanks.
>
>>
>> But. why using different statistical distribution classes
>>
>> #include <boost/standard_distribution/distributions/gamma.hpp>
>>
>
> This file does not define a new gamma distribution, only extra, non
> overlapping functionality. For example, you can map the gamma distribution
> to the gamma random engine :
>
> typedef boost::math::gamma_distribution<T,P> gamma_;
> typedef dist_random< gamma_ > meta;
> typedef meta::type random_;
> gamma_ gamma(5.0);
> random_ r = meta::make(gamma);
>

Got it!

>> What I mean is that I think an integration between Boost.Random and
>> Boost.StatisticalDistribution would be very useful for users
>
> Perhaps, but it's not under my control. Anyhow, if you do e.g
>
>  generate_n(it,n,gamma,urng);
>
> the interface make no reference to boost/random (hidden in implementation)
>

Hope the authors of Statistical Distribution toolkit consider to merge
your code in the near future :)

Thank you very much!

Cheers,

-- Marco


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net