Post Reply 
Quick HP42S question
05-25-2020, 02:35 PM
Post: #13
RE: Quick HP42S question
.
Hi, all:

(05-25-2020 09:06 AM)J-F Garnier Wrote:  Same for the HP-71B (emu71).

But...
the 100,000th number is .935105198 (with 3 tailing 0s)
the 1,000,000th number is .83105198 (with 4 tailing 0s)
the 10,000,000th number is .4105198 (with 5 tailing 0s)

Even if the period is in the range of 1E12-1E13, it seems there are correlations between numbers long before. Has this been already noticed?


Thanks to all of you for your replies, I've checked right now and the sequence of random numbers generated from a seed of 1 is exactly the same for at least the first 100,000,000 random numbers in both Free42 and Emu71 and I see this as quite convincing evidence that they'll remain the same to the bitter end, the differences in my programs lie elsewhere.

As for the correlations, yes, I did notice it in August last year while vacationing. They're clearly exposed by running the following HP-71B program (the equivalent Free42 program does produce the exact same results):


      10 DESTROY ALL @ INPUT "K=";K
      20 FOR J=0 TO K @ N=10^J @ RANDOMIZE 1
      30 FOR I=1 TO N @ X=RND @ NEXT I
      40 DISP USING "10D,2X,Z.12D";N,X @ NEXT J

>RUN
K=
      8 [END LINE]

            N     Nth random number
     ---------------------------------
            1     0.731362440213
           10     0.723555832003
          100     0.056136887198
        1 000     0.411709251980
       10 000     0.823130519800
      100 000     0.935105198000
    1 000 000     0.831051980000
   10 000 000     0.410519800000
  100 000 000     0.205198000000


Not very random-looking, methinks, and that many trailing zeros ... Sad

Regards.
V.

  
All My Articles & other Materials here:  Valentin Albillo's HP Collection
 
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Quick HP42S question - Valentin Albillo - 05-24-2020, 11:31 PM
RE: Quick HP42S question - ijabbott - 05-24-2020, 11:36 PM
RE: Quick HP42S question - Thomas Okken - 05-24-2020, 11:37 PM
RE: Quick HP42S question - Thomas Okken - 05-25-2020, 12:29 AM
RE: Quick HP42S question - Joe Horn - 05-25-2020, 02:41 AM
RE: Quick HP42S question - ijabbott - 05-25-2020, 09:33 AM
RE: Quick HP42S question - Gerald H - 05-25-2020, 05:30 AM
RE: Quick HP42S question - ijabbott - 05-25-2020, 08:57 AM
RE: Quick HP42S question - Werner - 05-25-2020, 06:40 AM
RE: Quick HP42S question - J-F Garnier - 05-25-2020, 09:06 AM
RE: Quick HP42S question - Valentin Albillo - 05-25-2020 02:35 PM
RE: Quick HP42S question - Albert Chan - 05-25-2020, 05:09 PM
RE: Quick HP42S question - Joe Horn - 05-25-2020, 07:22 AM



User(s) browsing this thread: 1 Guest(s)