Next: Problem Session,09/25/98: De Méré's Up: Sample Space 09/24 Previous: Discrete Uniform Random Distribution

### Computer Simulation

If you go one of the leland computers and call the program matlab you will be able to try the following example:

```rnum=floor(100*rand(1,50)+1)

ans=
Columns 1 through 12
76    16    72    85    79   100    59    37    38    99    89    19
Columns 13 through 24
25    25    18    34    41    63    90    68    14    48    97    50
Columns 25 through 36
40    99    77    99    24    47     4    74    85    52    15    78
Columns 37 through 48
45    17    26    73     7    12    82    47    91    90    21    88
Columns 49 through 50
24    69

sum(rnum<51)

ans =
25
```

This means that out of the 50 simulated numbers there were 25 that were strictly smaller than 25. Nearly too good to be true!

Try it, you will get a different set of numbers, but should get similar results.

This is the basic motivation of why probability is so related to combinatorics (ie enumerating or counting the cardinal of sets).

Susan Holmes
1998-12-07