Mantis Bugtracker
  

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0007192 [Squeak] Kernel minor always 09-15-08 21:32 09-23-08 00:58
Reporter wiz View Status public  
Assigned To
Priority normal Resolution open  
Status new   Product Version
Summary 0007192: A mother for issues with Random and random number generators in general
Description There are several bugs with the simplistic rng class Random
 and how it is used.
This is a parent report to summarize, collect and track those bugs and their repairs.
Additional Information Research started by a note on the beginners list has shown there are a good deal of holes in how Random is used in the image.

My current list:

1) LargeInteger atRandom will not produce a sufficent choice (0007142)

2) aRandom seed: does not check the range of the argument.
This can lead to out of range randoms being returned.

3) Random seed: 0 or m (where m is the modulo 16r7FFFFFFF)
is accepted with a zero number generator the result. (0005155)

4) The dice roller is part of the Random class, it should be factor into its own class and have a ivar for the generator.

5) The way the atRandom is used will not gaurantee strictly equal probablitity
for each choice. (old 3.8 bug 0003831 mentions one aspect of this.)

The thing to think of is a choice among 3/4 * m numbers or items. one third of the numbers will have twice the probability of the the others.

6) There is also a need for other rngs to be allowed. and maybe a superclass that random deserves to belong to that handles modulo counting.

7) Also how should squeak collect and use true randomness. Currently the only source tapped is the time clock.
Attached Files

- Relationships

SYSTEM WARNING: Creating default object from empty value

SYSTEM WARNING: Creating default object from empty value

SYSTEM WARNING: Creating default object from empty value

SYSTEM WARNING: Creating default object from empty value

SYSTEM WARNING: Creating default object from empty value

SYSTEM WARNING: Creating default object from empty value

parent of 0007142new  LargerInteger>>atRandom produces insufficient random bits 
parent of 0005155new  Random>>seed: accepts zero but results in a broken generator 
parent of 0003831closed  Set>>atRandom is not uniform 
parent of 0007200new  [ENH] The dice rolling methods in random should be factored out 
Not all the children of this issue are yet resolved or closed.

- Notes
(0012665 - 80 - 92 - 92 - 92 - 92 - 92)
wiz
09-15-08 21:38

oh yeah:

8) Tests for rngs are needed to lend assurance as to their qualites.
 

- Issue History
Date Modified Username Field Change
09-15-08 21:32 wiz New Issue
09-15-08 21:33 wiz Relationship added parent of 0007142
09-15-08 21:33 wiz Relationship added parent of 0005155
09-15-08 21:34 wiz Relationship added parent of 0003831
09-15-08 21:38 wiz Note Added: 0012665
09-23-08 00:58 wiz Relationship added parent of 0007200


Mantis 1.0.8[^]
Copyright © 2000 - 2007 Mantis Group
48 total queries executed.
34 unique queries executed.
Powered by Mantis Bugtracker