The Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.


Math Forum » Discussions » sci.math.* » sci.math

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: Need *predictable* random number sequence
Replies: 29   Last Post: Feb 5, 2001 4:55 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
r3769

Posts: 30
Registered: 12/12/04
Re: Need *predictable* random number sequence
Posted: Jan 21, 2001 5:31 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply



Here's a sketch of something that might work:

Pick a prime p, and for a given seed, s, set x[s]=1/p and compute a[i], i>=s
as follows:

a[i]=ceil((i+1)/x[i])-1
x[i+1]=a[i]*x[i]-i


The sequence <a[i]> is fairly wiggly and a[i] mod 256 doesn't FAIL (m)any of
the DIEHARD tests.

To get the predictable part of the PRNG, note that for t>s and b[i], i>=t,
where b[i] is computed as above with seed t, there is some i0 near t s.t.
b[i]=a[i], all i>i0.


Regards,

R. Burge


Rudolf Potucek wrote in message <948lhm$l54$1@nserve1.acs.ucalgary.ca>...
>Hi Everyone!
>
>I am looking for a way to generate a *reproducible* and *predictable*
>pseudo random series (it should still be statistically distributed).
>Ideally it would also be possible to generate the n-th element in the
>series directly from the seed/first value instead of having to generate
>all the intermediate series elements first. Can anyone give me a pointer
>where to look?
>
>Thx,
>
> Rudolf
>








Date Subject Author
1/19/01
Read Need *predictable* random number sequence
Rudolf Potucek
1/19/01
Read Re: Need *predictable* random number sequence
Richard Bos
1/19/01
Read Re: Need *predictable* random number sequence
Richard Heathfield
1/19/01
Read Re: Need *predictable* random number sequence
Clive Tooth
1/19/01
Read Re: Need *predictable* random number sequence
naisbodo@enteract.com
1/20/01
Read Re: Need *predictable* random number sequence
Richard Heathfield
1/20/01
Read Re: Need *predictable* random number sequence
GerardS
1/24/01
Read Re: Need *predictable* random number sequence
Jan-Eric Duden
1/24/01
Read Re: Need *predictable* random number sequence
Godwin Vickers
1/20/01
Read Re: Need *predictable* random number sequence
Mike Oliver
1/19/01
Read Re: Need *predictable* random number sequence
Chris Welty
1/19/01
Read Re: Need *predictable* random number sequence
Herman Rubin
1/19/01
Read Re: Need *predictable* random number sequence
Rudolf Potucek
1/19/01
Read Re: Need *predictable* random number sequence
Christian Bau
1/19/01
Read Re: Need *predictable* random number sequence
Lynn Killingbeck
1/19/01
Read Re: Need *predictable* random number sequence
George Marsaglia
1/19/01
Read Re: Need *predictable* random number sequence
Rudolf Potucek
1/20/01
Read Re: Need *predictable* random number sequence
Rudolf Potucek
1/19/01
Read Re: Need *predictable* random number sequence
Erik Max Francis
1/20/01
Read Re: Need *predictable* random number sequence
Jan Kristian Haugland
1/20/01
Read Re: Need *predictable* random number sequence
Jim Bubb
1/21/01
Read Re: Need *predictable* random number sequence
cbfalconer@my-deja.com
1/21/01
Read Re: Need *predictable* random number sequence
Rudolf Potucek
1/22/01
Read Re: Need *predictable* random number sequence
Gerry Quinn
1/21/01
Read Re: Need *predictable* random number sequence
r3769
2/4/01
Read Re: Need *predictable* random number sequence
spiralcenter314@my-deja.com
2/5/01
Read Re: Need *predictable* random number sequence
Robin Poot
2/5/01
Read Re: Need *predictable* random number sequence
Richard Heathfield
2/5/01
Read Re: Need *predictable* random number sequence
Nathan Mates
2/5/01
Read Re: Need *predictable* random number sequence
Richard Heathfield

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.