Math 106 Lecture 3

Math 106
Lecture 3
Probability - Basic Terms
Combinatorics and Probability - 1
Odds, Payoffs
Rolling a die (virtually)
1
© m j winter, 2004
Description
We roll a six-sided die and look to see whether the face
showing is divisible by 3.
2
1
Vocabulary
•
Roll a (6-sided) die
Experiment
•
1, 2, 3, 4, 5, 6
(Equally likely) Outcomes
•
Face is divisible by 3
Event
• 3, 6
Outcomes favorable to the event
Probability of event = P(face divisible by 3) =
...
number of (e.l.)outcomes favorable to the event
2 1
= =
total number of (e.l)outcomes
6 3
....
3
What is probability of exactly 5 Heads in 10
tosses of a coin?
Experiment: toss a coin 10 times, record the sequence
of H and T
H ___
H ___ ___ ___
H ___
H ___ ___ ___ ___
H
___
Count the outcomes:
_2_ _2_ _2_ _2_ _2_ _2_ _2_ _2_ _2_ _2_ = 210
possible, equally likely, outcomes.
Event: Exactly 5 of the tosses are heads
There are 10C5 ways to put down the 5 H’s. Others
must be T’s.
p(exactly 5 heads in 10 tosses) = 10C5/ 210 = 0.246…..
4
2
p(exactly 5 heads in 10 tosses) = 10C5/ 210 = 0.246…
What does this mean?
0.246 ≈ 0.25 = 1/4
•The chances are 1 out of 4 that you will have exactly 5
heads
•If you did the experiment a lot of times, about 1/4 would be
5 heads.
•If a lot of people did the experiment once, you’d expect
about 1/4 to get exactly 5 heads.
5
What’s the probability of exactly 10 heads in
20 tosses?
Now there are 2 20 possible outcomes
Of these, 20
C10 will be exactly 10 heads.
20C10 == 0.176.....
20
2
Proportional Reasoning usually does not apply in
probability.
6
3
Look at this with Excel
7
Roll Two Dice; sum the faces showing
• List the equally likely outcomes
1 2 3 4 5 6
1 2 3 4
5 6 7
2 3 4 5
6 7 8
3
4
5
6
4 5 6 7
8 9
5 6 7 8
9 10
6 7 8 9 10 11
Sample Space: set of
all outcomes.
Sometimes listed as
equally likely,
sometimes listed as
distinct.
7 8 9 10 11 12
8
4
Sample Space for Sum of Two Dice
Equally likely outcomes
Distinct Outcomes
11
12 2
2 3
3
3
4
10
5
9
4
4
4
5
5
5
5
6
8
7
9
1 2
3
4
5 6
1
2 3
4
5
6 7
2
3 4
5
6
7 8
3
4 5
6
7
8 9
4
5 6
7
8
9 10
5
6 7
8
9
10 11
6
7 8
9
10 11 12
Find the probability of each event
You roll doubles
6 1
=
36 6
0.16666….
.. sum is divisible by 4
The
9 1
0.250…..
=
36 4
.. sum is 6, 7, or 8
The
..
16
4
0.444...
=
36
9
..
When
comparing
probabilities,
use decimals
10
5
Combinatorics & Probability
• Your twin nieces received two Nancy Drew books for
their birthday and would like some more. You don’t
know which ones they have, but Amazon.com has
154 Nancy Drew books. You decide on three at
random.
• What is the probability all three are new to them?
11
Nancy Drew - 2
•
Experiment: Select 3 from 154
154!
= 596,904
3! 151!
152!
• Event: The 3 do not overlap
C3 =
= 573,800
152
with the 2 they have. Number
3!149!
•
Number of outcomes
154 C3
=
of outcomes favorable to the event:
..
C
P (no ov erla p) = 1 52 3 = 0 .9 61 ...
1 54 C 3
..
12
6
Roll a die with your calculator
•
TI: MATH ==> PRB ==>randInt( ==>1,6)
Display shows: randInt(1,6)
•
TI Roll three dice:
randInt(1,6,3) want 3 random integers between 1 and 6
13
Roll a die with Excel (this week’s project)
1.Open Excel. If a new, blank spreadsheet doesn't appear, go to File,
New, and click OK
2. Move to cell A1. Type
=RANDBETWEEN(1,6)
hit return. An integer between 1 and 6 should appear.
If it doesn’t: Go to Tools, Add-Ins, and put a check next to Analysis
Toolpak
3. Select cell A1. Move the cursor until it changes to the + sign, then hold
down the mouse button and drag down so that cells A1 through B36
are highlighted. The specified area should fill with random integers
between 1 and 6..
4. Hit F9 to re-evaluate the spreadsheet. A new set of random numbers will
be generated.
Instead of #3, you could use =INT(6*RAND()+1)
14
7
The formula: =INT(6*RAND()+1)
• RND() is a random number (not integer) between 0
and 1; never 0 and never 1.
• 6*RND(1) is a random number between 0 and 6.
never 0 and never 6.
• 6*RND()+1 is a random integer between 1 and 7
(never 1 and never 7)
• INT(6*RND()+1) is an integer between 1 and 6,
inclusive.
15
Back to Excel: Checking for Doubles
Use the IF function; if the values are the same, we
want a “1”; otherwise a “0”
Hit Enter, and drag down to
D36
Find out how many “1’s” in
column D. (Add column D)
16
8
Rolling Doubles with Excel
Could also use =SUM(D:D)
or
=SUM(select the range)
17
Odds
• Simple Game: roll a die.
• You win if 1 or 2; you lose if 3, 4, 5, 6
2
4
; P(lose) =
6
6
To calculate your odds, (the odds of your winning), take:
P(win) =
2
P(win) 6 2 1
= = =
P(lose) 4 4 2
6
Your odds = odds of your winning are 1:2
Odds of your losing are 2:1
18
9
Odds and Vocabulary
• Suppose there are a equally likely outcomes
favorable to event A, and b favorable to event B.
Suppose that the total number of outcomes is a + b.
• a:b = odds that A occurs
• a:b = odds against B occurring
• Sometime phrased as
• odds of B are a:b against
19
2
4
P(win) = ; P(lose) =
6
6
Fair Payoff
Odds against you are 2 - 1
Suppose you pay $1 to play each game.
If you lose, you lose the dollar. In the long run, you will lose
twice as often as you win.How much should you win if the
game is to be fair? i.e., your average winnings are $0.
Consider an “ideal” world.
We’ll play 6 games; you lose 4 times, and you win 2 times.
You’ve paid $6 to play. For the game to be fair, your
winnings should total $6. You won twice, so your winnings
each game should be 6/2 = $3. You get your $1 back plus
$2 more.
20
10
Fair Game: Odds and Payoffs
If the odds against you are 2 - 1; the payoff should be 2 - 1.
This means, you get back your bet (stake) plus two times
the amount of the stake.
There will be more about “fair games” in a later lecture.
21
Problems with odds
• The odds of your winning are 5 - 2 against. What is
the probability of winning?
• The odds against you are 5 - 2. If the game costs $1
to play, what should the payoff be if the game is fair?
22
11
Problems with odds
• The odds are 5 - 2 against. What is the probability of
winning?
2
p ( w in) =
7
• The odds against you are 5 - 2. If the game costs $1
to play, what should the payoff be if the game is fair?
Another way to express the odds is
5 2.5
=
.
2 1
The payoff should be 2.5 - 1; i.e., you should receive $2.50
23
plus your bet whenever you win.
Roulette
Payoffs
24
12
Odds vs Payoff
25
Payoffs Calculated as if no 0 and no 00
P(A) =
1
; odds of A 1:37
38
Odds against you are 37 - 1
Payoff is only 35 - 1
26
13