Boost logo

Boost :

Subject: Re: [boost] [random] Speed up binomial and poisson distributions
From: Ross Levine (ross.levine_at_[hidden])
Date: 2009-03-09 15:05:16


I sent Jens an email just now.

I have a style questions as well. First of all, this new
poisson_distribution is policy-based (don't worry -- it's
backwards-compatible with the old one; old code using the
poisson_distribution will not need to be changed). Since
poisson_distribution resides in the boost namespace, I didn't know if
the policies should be placed there as well, or in the boost/random
nested namespace. For now, they are in the boost/random/detail
namespace and typedef'ed into the boost namespace. They are named
pd_fast, pd_small, and pd_legacy. However, it occurred to me that
perhaps having policy classes in the boost namespace wasn't such a
good idea, since these classes are not meant to be instatiated
directly. At the very least, they could have private constructors and
be friends with the poisson_distribution, but I still don't know if
they ought to reside in the main boost namespace.

If anyone knows any rules for this, let me know. As it is there isn't
much mention of this situation in the developer faq.

In addition, this header probably needs formal documentation. I am
unaware of any stylistic guidelines I should follow.

Thanks,

Ross

On Mon, Mar 9, 2009 at 7:49 AM, Paul A. Bristow <pbristow_at_[hidden]> wrote:
> First of all, have you tried to contact the original author Jens Maurer
>
> http://www.boost.org/users/people/jens_maurer.html
>
> gives an email address.
>
> Or does anyone else have a current address?
>
> Paul
>
>> -----Original Message-----
>> From: boost-bounces_at_[hidden] [mailto:boost-bounces_at_[hidden]]
> On
>> Behalf Of Ross Levine
>> Sent: 09 March 2009 05:46
>> To: boost_at_[hidden]
>> Subject: Re: [boost] [random] Speed up binomial and poisson distributions
>>
>> Hey Stephan,
>>
>> I have a quick poisson generator based on Ahrens and Dieter's PD
>> algorithm. I've been too busy to formally submit it. If you want to
>> take a look it's here:
>> http://dl.getdropbox.com/u/416909/poisson_distribution.hpp
>>
>> If anyone knows how to submit this for review, please let me know.
>>
>> Ross Levine
>>
>> On Sat, Mar 7, 2009 at 5:04 AM, Paul A. Bristow <pbristow_at_[hidden]>
> wrote:
>> >
>> >
>> >> -----Original Message-----
>> >> From: boost-bounces_at_[hidden]
> [mailto:boost-bounces_at_[hidden]]
>> > On
>> >> Behalf Of Stephan
>> >> Sent: 06 March 2009 10:26
>> >> To: boost_at_[hidden]
>> >> Subject: [boost] [random] Speed up binomial and poisson distributions
>> >>
>> >> Hi,
>> >>
>> >> I was wondering why the binomial distribution still isn't optimized
>> >> for speed. If I look into the GSL as a comparison, they use much
>> >> smarter and faster algorithms. As is, the bosst::random distributions
>> >> are not usable for computational purposes to me, which is a pity since
>> >> I very much like the approach using variate_generators and stuff...
>> >>
>> >> I would be happy to contribute some faster code, but I don't know how
>> >> exactly I should proceed for that... should I contact the maintainer
>> >> directly?
>> >
>> > Yes - I think you should - and report back here if you fail -  someone
> else
>> > may be willing to take on the task
>> >
>> > - or help *you* to take it on ;-)
>> >
>> > Paul
>> >
>> >
>> > ---
>> > Paul A. Bristow
>> > Prizet Farmhouse
>> > Kendal, UK   LA8 8AB
>> > +44 1539 561830, mobile +44 7714330204
>> > pbristow_at_[hidden]
>> >
>> >
>> >
>> > _______________________________________________
>> > Unsubscribe & other changes:
> http://lists.boost.org/mailman/listinfo.cgi/boost
>> >
>> _______________________________________________
>> Unsubscribe & other changes:
> http://lists.boost.org/mailman/listinfo.cgi/boost
>
> _______________________________________________
> Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
>


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk