A New Kind of Science: The NKS Forum > Applied NKS > Just how non-random are some RNGs?
Author
Jason Cawley
Wolfram Science Group
Phoenix, AZ USA

Registered: Aug 2003
Posts: 712

Just how non-random are some RNGs?

Mathematica uses cellular automata to generate random numbers, and gets intrinsically generated randomness that way that passes all standard tests of randomness easily.

But not all random number generators are so successful. This website details problems with one used by Sun (in java) -

http://alife.co.uk/nonrandom/

See also the note on page 974 for some background on regularities found in some previous RNGs.

Report this post to a moderator | IP: Logged

12-03-2006 02:44 AM
Val Smith

Registered: Jun 2005
Posts: 39

It's just Counting!

All RNGs (PRNGs) look to me like counters.

They are faulty IF they sometimes repeat
exactly the same sequence again.

To get true randomness you must seed from
a fast counter every time a key is pressed.

Sun did exactly what I did in 1981 when I
discovered not hissy static but interesting
audiovisual video while attempting to
"calculate" very large random numbers:
(I've linked to this here often.)

http://ultravires.net/xor2.mov

Anyway, apparent randomness is caused
by incomplete information, as most PRNGs
count but only provide part of the number
when random is requested. This includes
linear feedback registers and CA, because
xor2 is BOTH of those, and also called a
"Polynomial Counter".

Real TV static is a consequence of tuning
in to a limited band of frequencies, ignoring
the remaining spectrum, which has apparent
patterns at base band (frequency zero),
and at the planckspacetime end also.

I wonder whether pi is any more useful than
a base-converted champernowne constant
as an analytical source of "randomness",
and ask the same of ANY non-observer-seeded RNG.

__________________
If something is zero, and zero is nothing, then something must be nothing.

Report this post to a moderator | IP: Logged

04-29-2007 08:25 AM
Ion Saliu

Gettysburg, Pennsylvania, USA

Registered: Nov 2006
Posts: 5

Random and degree of randomness

Everything is random. The Universe is ruled by randomness. The variation is in the degree of certainty (or probability of appearance). Randomness is the fairest form of being and not-being. There is no force to decide what is to be and not-to-be. The random interaction of forces creates what is and what is not.

As of randomness in computer software, some say it is pseudo-randomness. They actually refer to software written for the original IBM PC and Microsoft BASIC. The software generates "random" numbers based on a "seed", usually the timer. The timer measures number of seconds since midnight. There are only 86,400 seconds in a day. The variation in randomness is just too low, not only by computer standards. If the random generator is started exactly at the same second of the day, the same sequence of numbers is generated.

I heard stories of a state lottery being ripped-off by Keno players. The Keno numbers were generated by a computer precisely every 15 minutes: The same times of the day! The bare-bone timer was used as the randomizing seed. Thus, the Keno drawing of 9:00 PM yesterday will be the same today at 9:00 PM! The state lottery does not go bankrupt because they pay as prizes only 50% of ticket sales. But the lottery game itself would die, because lottery players expect fairness in randomness.

Free web lotteries, random numbers, combination, combinations generators; randomness.

The computers can generate numbers even “more randomly” than humans drawing lotto balls from a lottery machine. My solution: Replace the TIMER seed by a far more variable seed that is not dependent on the time of the day. Here is full-working code in BASIC:

Basic source code, algorithm to generate true random & unique numbers.

As of the statement:
“All RNGs (PRNGs) look to me like counters. They are faulty IF they sometimes repeat exactly the same sequence again.”

It is faulty in most cases. The sequences will repeat — otherwise they are not random, but human-picked. The situation is handled by ‘Ion Saliu’s Paradox of N Trials’:

Mathematics Of The Fundamental Formula Of Gambling (FFG).

If the probability p of an event is expressed as p = 1/N, then the degree of certainty tends to (1 – 1/e) or .632 (63.2%) that the event will come out in N trials. For example, the double-zero roulette has 38 possibilities (outcomes), from 0 to 37 (the placeholder for 00).

Super crocodilule, only 65% of the roulette numbers will be drawn in 38 spins. It tends to (1 – 1/e) when N tends to infinity. I verified for cases over 125 million (N) — a Powerball 5/53/1/42 lotto game. . It also means that 35% of the roulette numbers in 38 spins are repeats.

It is random alright. But it repeats mathematically.

Ion Saliu,
Precisely-Randomly At-Large

Report this post to a moderator | IP: Logged

07-06-2007 10:06 PM

wolframscience.com  |  wolfram atlas  |  NKS online  |  Wolfram|Alpha  |  Wolfram Science Summer School  |  web resources  |  contact us