New PRNG for calculators
|
08-08-2024, 05:48 PM
(This post was last modified: 08-09-2024 12:58 PM by SlideRule.)
Post: #15
|
|||
|
|||
RE: New PRNG for calculators
Stumbled on Example 4: HP-25 Pocket Calculator, Computational Statistics, 25th Conference, page 131
"The pseudorandom numbers of the HP-25 pocket calculator are generated by the algorithm ui ≡ ( ui-1+3)5 (mod 1) With a seed u0, 0 < u0 < 1, the floating-point arithmetic creates sequences which behave as demonstrated in Example 1. After a more or less ran- dom behaviour they enter a short subsequence repeating itself. The HP-25 calculator may enter such a cycle of only 29 numbers. This effect can be attributed to the rounding errors of the floating-point arithmetic. The generators of the BASIC interpreters on the Commodore and Apple microcomputers (CBM PET 2001 Series and Apple II europlus ) are further examples for generators having this defect. They are described and analysed in Afflerbach (1985) and Ripley ( 1987, p.18 ). In Afferbach (1985) it is shown that they may reach short cycles of period 202 and 703, respectively. Examples 3 and 4 elucidate why congruential generators de- fined by integer calculations ( and division by the modulus ) should be pre- ferred to congruential generators mod 1. More about the implementation of pseudorandom number generators can be found in Gentle (1990) and Ripley ( 1990 )." BEST!9SlideRule argh - yet another senior moment! |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 2 Guest(s)