This preview shows pages 1–2. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: 1.1. SIMULATION OF DISCRETE PROBABILITIES 3 .203309 .762057 .151121 .623868 .932052 .415178 .716719 .967412 .069664 .670982 .352320 .049723 .750216 .784810 .089734 .966730 .946708 .380365 .027381 .900794 Table 1.1: Sample output of the program RandomNumbers . Let X be a random variable with distribution function m ( ω ), where ω is in the set { ω 1 , ω 2 , ω 3 } , and m ( ω 1 ) = 1 / 2, m ( ω 2 ) = 1 / 3, and m ( ω 3 ) = 1 / 6. If our computer package can return a random integer in the set { 1 , 2 , ..., 6 } , then we simply ask it to do so, and make 1, 2, and 3 correspond to ω 1 , 4 and 5 correspond to ω 2 , and 6 correspond to ω 3 . If our computer package returns a random real number r in the interval (0 , 1), then the expression 6 r + 1 will be a random integer between 1 and 6. (The notation x means the greatest integer not exceeding x , and is read “floor of x .”) The method by which random real numbers are generated on a computer is described in the historical discussion at the end of this section. The following example gives sample output of the program RandomNumbers . Example 1.1 (Random Number Generation) The program RandomNumbers generates n random real numbers in the interval [0 , 1], where n is chosen by the user. When we ran the program with n = 20, we obtained the data shown in Table 1.1....
View Full
Document
 Spring '09
 scf

Click to edit the document details