Questions on the algorithms for and uses of (pseudo)random number generators in scientific computing.
4
votes
1answer
38 views
Random access random permutations
I have a large number of parallel processes and a large integer $n$, and want to randomly partition the integers $[0,n)$ among the processes with only $O(1)$ communication.
One nice way to do this ...
2
votes
1answer
68 views
Randomly choose among N alternatives
I understand how to generate a random sequence of binary variables where 1 occurs with probability p and ...
4
votes
4answers
435 views
Simulated Annealing proof of convergence
I implemented downhill simplex simulated annealing algorithm. Algorithm is very hard to tune, w.r.t. parameters including cooling schedule, starting temperature...
My first question is about ...
1
vote
1answer
67 views
Random placement of euclidean points with constrained inter-point distances in a fixed area
I'd like to place as many random points as possible in a 2D square $S=[0,1]x[0,1]$ such that the euclidean distance $d$ between any two points $d$ is greater than a given value $b$ (b is small). I'm ...
11
votes
4answers
193 views
How to create a random 3D domain representing a plant's root structure?
I would like to model laminar flow of water from roots to the stem of a plant. At the very end of the roots, the tubes vary from millimeter to centimeter scale in diameter and length. As we get closer ...
4
votes
1answer
456 views
How can I determine the period of my pseudo-random number generator?
Suppose I'm using a linear congruential pseudo-random number generator (PRNG). Given a seed $x_0$, the multiplying factor (a), the shift factor (c) and the modulus factor (m), how can I determine the ...
3
votes
1answer
59 views
Adding deliberate imperfection to RNG output - toolkits?
Are there any existing software toolkits, libraries, frameworks or whatever for studying the quality of pseudorandom number generators that allow one to add a known amount of imperfection - e.g ...
5
votes
2answers
497 views
How can I seed a parallel linear congruential pseudo-random number generator for maximal period?
Normally when I seed a sequential random number generator in C, I use the call
srand(time(NULL))
then use
rand() mod N
...
4
votes
1answer
804 views
Looking for C/C++ implementations of sampling from multinomial and Dirichlet distributions
I'm looking for C/C++ implementations of functions that return random variates multinomial and Dirichlet distributions. This is in the context of a calculation for posterior predictive p-values, part ...
3
votes
1answer
248 views
Sampling from posterior predictive distribution
First post. I'm working on this problem using Bayesian methods. In desperation I'm considering using p-values (shock horror), specifically posterior predictive p-values. So I need to simulate from the ...
14
votes
4answers
657 views
Is Fortuna or Mersenne Twister preferable as an algorithmic RNG?
A recent answer mentioned the use of Fortuna or Mersenne Twister Random Number Generators (RNGs) to seed a Monte Carlo simulation. I hadn't heard of Fortuna before so I looked it up - looks like it is ...
5
votes
4answers
185 views
How do I know which low-discrepancy sequence to use?
Whenever one uses a quasi-Monte Carlo method for cubature or optimization, it seems that there's a wide variety of low-discrepancy sequences to choose from, associated with the names of van der ...