0
$\begingroup$

This question is somehow related to this one.

Having multiple streams of pseudo-random numbers known to be independent and with a uniform distribution I want to do Monte Carlo simulations in parallel.

In other words, one thread will have a full-period independent and uniformly distributed stream of pseudo-random numbers. Each thread will consume these numbers in four different functions (a,b,c,d).

My concern is about the distribution for each function. Thread.1 func_a.1, thread.2 func_a.2... and so on. Do I still need to make sure this distribution is indeed uniform across func_a1, func_a2, etc? Failing to do so can make my simulation have flaws?

In summary,if I start using the pseudo-random numbers in a "random" fashion. Can I still be sure of the uniform distribution among the different parts?

$\endgroup$

1 Answer 1

0
$\begingroup$

Please read Darren Wilkinson's blogpost Getting started with parallel MCMC. Getting a deterministic computer to generate a pseudo-random number stream is nontrivial, and there is no reason to think streams starting from different seeds (as in the other question you referenced) will be independent, given that this was not a desideratum when designing the algorithm. Please use a Parallel Random Number Generator that was specifically designed for that purpose.

Wilkinson recommends SPRNG in this blogpost, and I've used that before. However more recently I've been using RngStreams as I find it's less hassle. The RngStreams approach is similar to what you've described in that the different threads will consume different parts of stream.

$\endgroup$
0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .