Ranges MEGA-million
- From: "\"Luis A. Afonso\"" <licas_@xxxxxxxxxxx>
- Date: Fri, 29 Apr 2005 14:05:04 EDT
Range = maximum number – minimum number + 1
Results Cumulative Frequencies
Range=12---0.005---0.005---0.005
Range=17---0.027---0.027---0.027
Range=50---0.979---0.978---0.978
Range=51---0.993---0.992---0.992
CONFIDENCE INTERVALS
[12,51]---p=98.7%
[17,50]---p=95.1%
REM "million1"
CLS
RANDOMIZE TIMER
DIM w(52), freq(52)
all = 400000
FOR repeat = 1 TO all
LOCATE 10, 10
PRINT USING "#######"; all - repeat
FOR j = 1 TO 52: w(j) = 1: NEXT j
maxx = o: minn = 56
FOR i = 1 TO 5
10 x = INT(RND * 52) + 1
IF w(x) = 0 THEN GOTO 10
IF x < minn THEN minn = x
IF x > maxx THEN maxx = x
w(x) = 0
NEXT i: a = maxx - minn + 1
freq(a) = freq(a) + 1
a = 0 : d= repeat/(all / 10)
IF d <> INT(d) THEN GOTO 1
RANDOMIZE TIMER
1 NEXT repeat
FOR y = 1 TO 52
s = s + freq(y) : b= s/all : b1=freq(y)/all
IF s = 0 THEN GOTO 20
PRINT USING "## #.### #.### "; y; b;b1;
20 NEXT y
END
Licas_@xxxxxxxx
.
- Prev by Date: One-Tailed Bivariate Chebyshev Inequalities
- Next by Date: A couple of curiosity questions
- Previous by thread: One-Tailed Bivariate Chebyshev Inequalities
- Next by thread: A couple of curiosity questions
- Index(es):
Relevant Pages
|
|