2nd September 2009

Session 1.5

Random Variables

Pairs of Dice and Random Variables.

Case Study #1.7: Pairs to Sums

 

Case Description: Work with a random variable that acts on pairs of outcomes.

We assume that the dice are fair, and that the dice operate separately and independently.

 

Case Study Objectives:

 

We toss a pair of fair dice, one three-sided d3:(faces 1,2,3) and one four-sided d4:(faces 1,2,3,4).

How many pairs are possible, and what is the probability for each pair ?

 

Fair D4 model 

Face Value

Probability

1

1/4

2

1/4

3

1/4

4

1/4

Total

4/4

Fair D3 model

 Face Value

Probability

1

1/3

2

1/3

3

1/3

Total

3/3

There are 4*3=12 distinct pairs possible: Writing each pair as (d4 face value, d3 face value):

(1,1), (2,1), (3,1), (4,1), (1,2), (2,2), (3,2), (4,2), (1,3), (2,3), (3,3), (4,3)

(d4,d3)

1

2

3

4

1

(1,1)

(2,1)

(3,1)

(4,1)

2

(1,2)

(2,2)

(3,2)

(4,2)

3

(1,3)

(2,3)

(3,3)

(4,3)

 

Under the independent multiplication principle,

 

Pr{(event from d4, event from d3)} = Pr{ event from d4}*Pr{ event from d3}, so:

 

Pr{(1,1)} = Pr{1 shows from d4}*Pr{1 shows from d3} = (1/4)*(1/3) = 1/12

Pr{(2,1)} = Pr{2 shows from d4}*Pr{1 shows from d3} = (1/4)*(1/3) = 1/12

Pr{(3,1)} = Pr{3 shows from d4}*Pr{1 shows from d3} = (1/4)*(1/3) = 1/12

Pr{(4,1)} = Pr{4 shows from d4}*Pr{1 shows from d3} = (1/4)*(1/3) = 1/12

 

Pr{(1,2)} = Pr{1 shows from d4}*Pr{2 shows from d3} = (1/4)*(1/3) = 1/12

Pr{(2,2)} = Pr{2 shows from d4}*Pr{2 shows from d3} = (1/4)*(1/3) = 1/12

Pr{(3,2)} = Pr{3 shows from d4}*Pr{2 shows from d3} = (1/4)*(1/3) = 1/12

Pr{(4,2)} = Pr{4 shows from d4}*Pr{2 shows from d3} = (1/4)*(1/3) = 1/12

 

Pr{(1,3)} = Pr{1 shows from d4}*Pr{3 shows from d3} = (1/4)*(1/3) = 1/12

Pr{(2,3)} = Pr{2 shows from d4}*Pr{3 shows from d3} = (1/4)*(1/3) = 1/12

Pr{(3,3)} = Pr{3 shows from d4}*Pr{3 shows from d3} = (1/4)*(1/3) = 1/12

Pr{(4,3)} = Pr{4 shows from d4}*Pr{3 shows from d3} = (1/4)*(1/3) = 1/12

 

Pair → Sum

1

2

3

4

1

(1,1) → 2

(2,1) → 3

(3,1) → 4

(4,1) → 5

2

(1,2) → 3

(2,2) → 4

(3,2) → 5

(4,2) → 6

3

(1,3) → 4

(2,3) → 5

(3,3) → 6

(4,3) → 7

Compute probabilities for each sum. Map the pairs to sums, and list the pairs that lead to each sum. Using the probabilities for each pair, compute probabilities for each sum value:

Pr{Sum=2} =

Pr{(1,1)} =

1/12

 

Pr{Sum=3} =

Pr{One of (1,2),(2,1) Shows} =

Pr{(1,2)}+Pr{(2,1)} =

(1/12)+(1/12)=

2/12

 

Pr{Sum=4} =

Pr{One of (1,3),(2,2),(3,1) Shows} =

Pr{(1,3)}+Pr{(2,2)}+Pr{(3,1)} =

(1/12)+(1/12) +(1/12)=

3/12


Pr{Sum=5} =

Pr{One of (4,1),(2,3),(3,2) Shows} =

Pr{(4,1)}+Pr{(2,3)}+Pr{(2,3)} =

(1/12)+(1/12) +(1/12)=

3/12

 

Pr{Sum=6} =

Pr{One of (4,2),(3,3) Shows} =

Pr{(4,2)}+Pr{(3,3)} =

(1/12)+(1/12)=

2/12

 

Pr{Sum=7} =

Pr{(4,3)} =

1/12

 

Case Study #1.8

Probability Computation Rules

Case Description: Compute selected probabilities associated with a pair of dice.

 

D4 model 

Face Value

Probability

1

4/10

2

3/10

3

2/10

4

1/10

Total

10/10

d3 model

 Face Value

Probability

1

1/6

2

2/6

3

3/6

Total

1.00

 

The experiment: On each trial of the experiment, we toss the pair of dice (defined above) and observe the pair of faces that show.

Case Objectives: Lay out the possible face-pairs, and compute the probability for each pair. State any required assumptions.

Consider the random variable that maps the pair of face values into the sum of the face values.

 

The PAIR Model

 

There are 4*3=12 distinct pairs possible: Writing each pair as (d4 face value, d3 face value):

(1,1), (2,1), (3,1), (4,1), (1,2), (2,2), (3,2), (4,2), (1,3), (2,3), (3,3), (4,3)

(d4,d3)

1

2

3

4

1

(1,1)

(2,1)

(3,1)

(4,1)

2

(1,2)

(2,2)

(3,2)

(4,2)

3

(1,3)

(2,3)

(3,3)

(4,3)

 

Under the independent multiplication principle,

 

Pr{(event from d4, event from d3)} = Pr{ event from d4}*Pr{ event from d3}, so:

  

Pr{(1,1)} = Pr{1 shows from d4}*Pr{1 shows from d3} = (4/10)*(1/6) = 4/60

Pr{(2,1)} = Pr{2 shows from d4}*Pr{1 shows from d3} = (3/10)*(1/6) = 3/60

Pr{(3,1)} = Pr{3 shows from d4}*Pr{1 shows from d3} = (2/10)*(1/6) = 2/60

Pr{(4,1)} = Pr{4 shows from d4}*Pr{1 shows from d3} = (1/10)*(1/6) = 1/60

 

Pr{(1,2)} = Pr{1 shows from d4}*Pr{2 shows from d3} = (4/10)*(2/6) = 8/60

Pr{(2,2)} = Pr{2 shows from d4}*Pr{2 shows from d3} = (3/10)*(2/6) = 6/60

Pr{(3,2)} = Pr{3 shows from d4}*Pr{2 shows from d3} = (2/10)*(2/6) = 4/60

Pr{(4,2)} = Pr{4 shows from d4}*Pr{2 shows from d3} = (1/10)*(2/6) = 2/60

 

Pr{(1,3)} = Pr{1 shows from d4}*Pr{3 shows from d3} = (4/10)*(3/6) = 12/60

Pr{(2,3)} = Pr{2 shows from d4}*Pr{3 shows from d3} = (3/10)*(3/6) = 9/60

Pr{(3,3)} = Pr{3 shows from d4}*Pr{3 shows from d3} = (2/10)*(3/6) = 6/60

Pr{(4,3)} = Pr{4 shows from d4}*Pr{3 shows from d3} = (1/10)*(3/6) = 3/60


The SUM Model

 

Pair → Sum

1

2

3

4

1

(1,1) → 2

(2,1) → 3

(3,1) → 4

(4,1) → 5

2

(1,2) → 3

(2,2) → 4

(3,2) → 5

(4,2) → 6

3

(1,3) → 4

(2,3) → 5

(3,3) → 6

(4,3) → 7

 

Pr{Sum=2} = Pr{(1,1)} = 4/60

 

Pr{Sum=3} =

Pr{One of (1,2),(2,1) Shows} =

Pr{(1,2)}+Pr{(2,1)}=

(3/60)+(8/60)=

11/60

 

Pr{Sum=4} =

Pr{One of (3,1),(2,2),(1,3) Shows} =

Pr{(1,3)}+Pr{(2,2)}+Pr{(3,1)} =

(2/60)+(6/60)+(12/60)=

20/60

 

Pr{Sum=5} =

Pr{One of (4,1),(3,2),(2,3) Shows} =

Pr{(4,1)}+Pr{(3,2)}+Pr{(2,3)} =

(1/60)+(4/60) +(9/60)=

14/60

 

Pr{Sum=6} =

Pr{One of (4,2),(3,3) Shows} =

Pr{(4,2)}+Pr{(3,3)} = (2/60)+(6/60) =

8/60

 

Pr{Sum=7} =

Pr{(4,3)} =

3/60

Compare sample proportions (p) to model probabilities (P). Compare precision with increasing sample size.

Samples

 

6.30 Samples

 

Fair Pair

Loaded Pair

#1

#4

Sum

#

p

P

Sum

#

p

P

2

2

2/50=0.04

1/12=0.083333

2

2

2/50=0.04

4/60=0.066667

3

12

12/50=0.24

2/12=0.166667

3

16

16/50=0.32

11/60=0.183333

4

15

15/50=0.3

3/12=0.25

4

14

14/50=0.28

20/60=0.333333

5

10

10/50=0.2

3/12=0.25

5

9

9/50=0.18

14/60=0.233333

6

6

6/50=0.12

2/12=0.166667

6

7

7/50=0.14

8/60=0.133333

7

5

5/50=0.1

1/12=0.083333

7

2

2/50=0.04

3/60=0.05

Total

50

1

12/12=1

Total

50

1

60/60=1

#2

#5

Sum

#

p

P

Sum

#

p

P

2

6

0.12

0.083333

2

4

0.08

0.066667

3

5

0.1

0.166667

3

8

0.16

0.183333

4

12

0.24

0.25

4

23

0.46

0.333333

5

11

0.22

0.25

5

7

0.14

0.233333

6

11

0.22

0.166667

6

4

0.08

0.133333

7

5

0.1

0.083333

7

4

0.08

0.05

Total

50

1

1

Total

50

1

1

#3

#6

Sum

#

p

P

Sum

#

p

P

2

6

0.12

0.083333

2

4

0.08

0.066667

3

7

0.14

0.166667

3

6

0.12

0.183333

4

16

0.32

0.25

4

12

0.24

0.333333

5

14

0.28

0.25

5

15

0.3

0.233333

6

7

0.14

0.166667

6

8

0.16

0.133333

7

0

0

0.083333

7

5

0.1

0.05

Total

50

1

1

Total

50

1

1

123

456

Sum

#

p

P

Sum

#

p

P

2

14

0.093333

0.083333

2

10

0.066667

0.066667

3

24

0.16

0.166667

3

30

0.2

0.183333

4

43

0.286667

0.25

4

49

0.326667

0.333333

5

35

0.233333

0.25

5

31

0.206667

0.233333

6

24

0.16

0.166667

6

19

0.126667

0.133333

7

10

0.066667

0.083333

7

11

0.073333

0.05

Total

150

1

1

Total

150

1

1

 

 

8.00 Samples

 

Fair Pair

Loaded Pair

#1

#4

Sum

#

p

P

Sum

#

p

P

2

4

0.08

0.08333333

2

5

0.1

0.06666667

3

7

0.14

0.16666667

3

9

0.18

0.18333333

4

19

0.38

0.25

4

16

0.32

0.33333333

5

11

0.22

0.25

5

11

0.22

0.23333333

6

6

0.12

0.16666667

6

5

0.1

0.13333333

7

3

0.06

0.08333333

7

4

0.08

0.05

Total

50

1

1

Total

50

1

1

#2

#5

Sum

#

p

P

Sum

#

p

P

2

6

0.12

0.08333333

2

3

0.06

0.06666667

3

5

0.1

0.16666667

3

14

0.28

0.18333333

4

11

0.22

0.25

4

15

0.3

0.33333333

5

15

0.3

0.25

5

10

0.2

0.23333333

6

10

0.2

0.16666667

6

8

0.16

0.13333333

7

3

0.06

0.08333333

7

0

0

0.05

Total

50

1

1

Total

50

1

1

#3

#6

Sum

#

p

P

Sum

#

p

P

2

3

0.06

0.08333333

2

1

0.02

0.06666667

3

6

0.12

0.16666667

3

16

0.32

0.18333333

4

17

0.34

0.25

4

15

0.3

0.33333333

5

14

0.28

0.25

5

6

0.12

0.23333333

6

7

0.14

0.16666667

6

10

0.2

0.13333333

7

3

0.06

0.08333333

7

2

0.04

0.05

Total

50

1

1

Total

50

1

1

123

456

Sum

#

p

P

Sum

#

p

P

2

13

0.086666667

0.08333333

2

9

0.06

0.06666667

3

18

0.12

0.16666667

3

39

0.26

0.18333333

4

47

0.313333333

0.25

4

46

0.306666667

0.33333333

5

40

0.266666667

0.25

5

27

0.18

0.23333333

6

23

0.153333333

0.16666667

6

23

0.153333333

0.13333333

7

9

0.06

0.08333333

7

6

0.04

0.05

Total

150

1

1

Total

150

1

1


 

We’re seeing the pair model inheriting its probability structure from the individual dice. The random variable in turn inherits its probability structure from the pair model.

 

Begin working case types involving random variables and pairs of dice.