Date : Mon, 08 Apr 1985 08:50:46-EST
From : Lee.Sailer@CMU-CS-C.ARPA
Subject: More randomness
Cuccia's (non) solution is an example of my problem. I call it a non-solution
because (1) it defines a constant M >> the upper limit allowed in most Z80
Pascals, and (2) the statement x := (x*A) mod M is eventually gonna overflow.
Another problem: A and M relatively prime is NOT sufficient to guarantee good
statistical properties of a rn generator.
So, in more direct form, here is my problem: I am writing a journal article
that includes a monte-carlo statistical simulation. I know that the journal
@i(requires) a "good" rn generator--most people use IMSL. A good rn generator
is one that passes a wide variety of statistical tests for randomness.
Therefore, I must now find a "good" generator for the Z80, or port my program
over to a mainframe with IMSL.
I have nothing against linear congruential generators as suggested by Cuccia,
but I gotta know what the right constants are for my z80, and I hafta have
a citation that says they are the right ones, else the journal will laugh
and say, "resubmit when you have duplicated your results on a real computer."
One last point--I have tested the built in random in Turbo Pascal, and it sure
isn't random.
lee