math 3680 lecture #3 probability

59
Math 3680 Lecture #3 Probability

Upload: jason

Post on 12-Jan-2016

52 views

Category:

Documents


3 download

DESCRIPTION

Math 3680 Lecture #3 Probability. We hear about chance in several different contexts: 1. A certain horse is given 5:1 odds to win a race. 2. A banker recommends a certain stock for investment. 3. Josh Hamilton is batting 0.361 for the season. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Math 3680 Lecture #3 Probability

Math 3680

Lecture #3

Probability

Page 2: Math 3680 Lecture #3 Probability

We hear about chance in several different contexts:

1. A certain horse is given 5:1 odds to win a race.2. A banker recommends a certain stock for investment.3. Josh Hamilton is batting 0.361 for the season.4. In a recent poll, 48% of Americans approve of the

president’s performance.5. The chance of being dealt the queen of spades is 1 in 52.6. The chance of winning a Pick 4 lottery game is 1 in 10,000.

We have three different types of probabilities:

 

1) Expert opinion (subjective)2) Relative frequency (empirical)3) Equally likely outcomes (theoretical)

Page 3: Math 3680 Lecture #3 Probability

Definition: The probability of event A is denoted P(A).

1) Chances are between 0% and 100%. That is:

0 ≤ P(A) ≤ 1.

We denote an impossible event (the empty set) by Ø:

P(Ø) = 0.

Page 4: Math 3680 Lecture #3 Probability

There is a technical difference between the phrases impossible and probability zero.

Example: I pick a real number in the interval [0,1] and you try to guess my number. It’s not impossible, but the probability that you pick my number is zero.

Question: Would the same be true if I told you that I rounded my number to six decimal places?

Page 5: Math 3680 Lecture #3 Probability

2) The chance of something not happening is 100% minus the chance of it happening. That is,

P(not E) = P(E’ ) = 1 - P(E).

This event, “not E,” is referred to as the complement of E.

Page 6: Math 3680 Lecture #3 Probability

3) When you draw at random, we assume that all the possible outcomes are equally likely, so that

number of favorable outcomes P(E) = number of possible outcomes

The word “draw” is used to suggest “select”, or “pick”, or “choose.” There are two ways that draws can be made:

1. Draws with replacement, such as rolling a die repeatedly or tossing a coin repeatedly.  

2. Draws without replacement, such as dealing cards from a deck or 5 CD random shuffle.

Page 7: Math 3680 Lecture #3 Probability

4) If E implies F, then F is more likely than E.

If , then P(E) ≤ P(F).

Example: Let E = “a dealt card is a heart”

Let F = “a dealt card is red”

FE

Page 8: Math 3680 Lecture #3 Probability

Definition: Conditional probability.

The conditional probability that A happens given thatB happens is denoted by

P(A | B)

Formula:

Here, A ∩ B denotes the intersection of A and B; that is, the event that A and B both happen.

)(

)()|(

BP

BAPBAP

Page 9: Math 3680 Lecture #3 Probability

Ex: Two tickets are drawn without replacement from the box

A) What is the chance that the second ticket is , given the first is ? (Conditional probability)

 

B) What is the chance that the first ticket is ? (Unconditional probability)

C) What is the chance that the second ticket is ? (Again unconditional probability!)D) Repeat if the draws are made with replacement.

1 2 3 4

24

2

2

Page 10: Math 3680 Lecture #3 Probability

Example: Five cards are dealt off the top of a well-shuffled deck.

A) Find the chance that the fifth card is the queen of spades.

B) Find the chance that the fifth card is the queen of spades, given that the first four cards are hearts.

Page 11: Math 3680 Lecture #3 Probability

Example: A penny is tossed five times.

A) Find the chance that the fifth toss is a head. 

B) Find the chance that the fifth toss is a head, given that the first four tosses are tails.

Page 12: Math 3680 Lecture #3 Probability

Solution #1: Counting the possibilities.

 

RW WR BR

RB WB BW

 

So the chance is 61

Example: A box has three tickets – red, white and blue. Two tickets are drawn at random without replacement. What is the chance that the red ticket is drawn first, and the white ticket second?

Page 13: Math 3680 Lecture #3 Probability

Solution #2: Multiplication Rule. Imagine a large group of people attempting this experiment. Roughly one-third will get the first draw correct.

Of these people, about half will get the second draw correct. Thus, from the original population,

will get both draws correct. 6

1

2

1

3

1

Page 14: Math 3680 Lecture #3 Probability

Definition: Multiplication Rule.

The chance that events A and B both happen is found by multiplying the chance that event A happens by the chance that B happens, given that A has happened:

P(A ∩ B) = P(A) P(B | A)

Page 15: Math 3680 Lecture #3 Probability

Example: A deck of cards is shuffled and two cards are dealt. What is the probability that both are hearts?

Method #1: List the possible outcomes.

Page 16: Math 3680 Lecture #3 Probability
Page 17: Math 3680 Lecture #3 Probability

Example: A deck of cards is shuffled and two cards are dealt. What is the probability that both are hearts?

Method #2: Use the multiplication rule.

Page 18: Math 3680 Lecture #3 Probability

Example: Five cards are dealt from a well-shuffled deck. What is the probability that all 5 are hearts?

Page 19: Math 3680 Lecture #3 Probability

Example: In poker, what is the probability of being dealt a flush?

Page 20: Math 3680 Lecture #3 Probability

Example: A die is rolled four times. What is the probability that all four rolls are different?

Page 21: Math 3680 Lecture #3 Probability

Definition: Independent.

We say that two events A and B are independent if the outcome of event A does not influence the outcome of event B. In mathematical notation,

P(B | A) = P(B)

Page 22: Math 3680 Lecture #3 Probability

Example: A coin is tossed twice. Let

A = “the first flip lands heads”

B = “the second flip lands heads”

Are events A and B independent?

Page 23: Math 3680 Lecture #3 Probability

Example: A die is rolled once. Let

A = “the die lands on four”

B = “the die lands on six”

Are events A and B independent?

Page 24: Math 3680 Lecture #3 Probability

Example: Two cards are dealt. Let

A = “the first card is an ace”

B = “the second card is an ace”

Are events A and B independent?

Page 25: Math 3680 Lecture #3 Probability

Example: One card is dealt. Let

A = “the card is a jack”

B = “the card is a heart”

Are events A and B independent?

Page 26: Math 3680 Lecture #3 Probability

Rule of thumb:

When drawing with replacement, the draws are independent.

When drawing without replacement, the draws are dependent.

Page 27: Math 3680 Lecture #3 Probability

Example: A die is rolled 10 times. Find the chance of ...

A) getting 10 sixes

 

B) not getting 10 sixes

C) all the rolls showing 5 or fewer dots

D) getting at least one six

Are B) and C) the same?

Page 28: Math 3680 Lecture #3 Probability

Definition: Mutually Exclusive. Two events are called mutually exclusive (or disjoint) if they cannot occur simultaneously.

WARNING: Disjoint is a different concept than independent.

If E and F are disjoint, then P(F | E) = 0.

If E and F are independent, then P(F | E) = P(F).

Page 29: Math 3680 Lecture #3 Probability

Example: A coin is flipped twice. Let

A = “the first flip lands heads”

B = “the second flip lands heads”

Are events A and B disjoint?

Page 30: Math 3680 Lecture #3 Probability

Example: A die is rolled once. Let A = “the die lands on four” B = “the die lands on six”

Are events A and B disjoint?

Page 31: Math 3680 Lecture #3 Probability

Example: Two cards are dealt. Let

A = “the first card is an ace”

B = “the second card is an ace”

Are events A and B disjoint?

Page 32: Math 3680 Lecture #3 Probability

Example: One card is dealt. Let

A = “the card is a jack”

B = “the card is a heart”

Are events A and B disjoint?

Page 33: Math 3680 Lecture #3 Probability

Property: If A and B are disjoint, then

P(B) P(A) P(A or B)

Note: The word “or” has a different meaning in probability than in ordinary English usage. It does not mean “exclusive or”.

That is, “A or B” means

“A, or B, or both A and B.”

Page 34: Math 3680 Lecture #3 Probability

Example: A card is dealt from a shuffled deck. What is the probability that the card is a face card?

Solution:

P(jack or queen or king) = P(jack) + P(queen) + P(king)

52

4

52

4

52

4

13

3

Page 35: Math 3680 Lecture #3 Probability

Example: A card is dealt from a well-shuffled deck. What is the probability that it is a red?

 

Solution:

P(heart or diamond) = P(heart) + P(diamond)

(mutually exclusive)

Page 36: Math 3680 Lecture #3 Probability

Example: Two dice are rolled. What’s the probability that an ace (one dot) appears?

 

Common Mistake:

P(ace on first or ace on second)

= P(ace on first ) + P(ace on second)

= +

=

6

1

3

16

1

Page 37: Math 3680 Lecture #3 Probability

Correct Answer #1: Look at a chart of the 36 possible

outcomes for the roll of two dice. There are 11 pairs in

which an ace appears. So the answer is . 36

11

11 12 13 14 15 16

21 22 23 24 25 26

31 32 33 34 35 36

41 42 43 44 45 46

51 52 53 54 55 56

61 62 63 64 65 66

Page 38: Math 3680 Lecture #3 Probability

Because these two events are not mutually exclusive, the first (incorrect) method produced an answer that was too big instead of .

Subtracting something makes sense. After all, the probability of an ace appearing on 7 dice cannot be .

36

12

3611

67

Page 39: Math 3680 Lecture #3 Probability

Correct Answer #2: Use the general formula for events which are not mutually exclusive:

P(A ∩ B ) P ( B) P(A) P(A or B)

Notice that the Rule of Addition saves a lot of time.

Page 40: Math 3680 Lecture #3 Probability

Example: A card is dealt. What is the probability it is either a queen or a spade?

Page 41: Math 3680 Lecture #3 Probability

Example: True or false? In a shuffled deck of cards:

A) The chance that the top card is the jack of clubs is 1/52.

 

B) The chance that the bottom card is eight of hearts is 1/52.

C) The chance that the top card is the jack of clubs or the bottom card is the eight of hearts is 2/52.

Page 42: Math 3680 Lecture #3 Probability

D) The chance that the top card is the jack of clubs or the bottom card is the jack of clubs is 2/52.

  E) The chance that the top card is the jack of clubs and the bottom card is the eight of hearts is

F) The chance that the top card is the jack of clubs and the bottom card is the jack of clubs is

521

521

52

1x

52

1

Page 43: Math 3680 Lecture #3 Probability

Example: Four tickets are drawn from a box that contains 5 tickets each numbered from “1” to “5”. Find P(at least one 2) if the draws are made

A) with replacement

B) without replacement

Page 44: Math 3680 Lecture #3 Probability

Example: Suppose that P(A) = 0.2, P(B) = 0.3 and = 0.4. Use a Venn diagram to find the following quantities:

1.

2.

3.

4.

P(A ∩ B )

P(A or B)

P(A ∩ B’ )

P(A’ ∩ B’ ) P(A | B)

Page 45: Math 3680 Lecture #3 Probability

Multiplication Trees and

Bayes’ Rule

Page 46: Math 3680 Lecture #3 Probability

Example: Suppose there are two electrical components. The chance that the first component fails is 20%. If the first fails, the chance that the second fails is 30%. However, if the first works, the chance that the second fails is 10%.

Find the probability that:

1. At least one component works.

2. Exactly one component works.

3. The second component works.

Page 47: Math 3680 Lecture #3 Probability

Solution: A multi-stage problem like this can be visualized with a tree diagram:

Works

Fails

0.2

0.8

Works

Fails

Works

Fails

0.9

0.1

0.7

0.3

0.72

0.08

0.14

0.06

Page 48: Math 3680 Lecture #3 Probability

Works

Fails

0.2

0.8

Works

Fails

Works

Fails

0.9

0.1

0.7

0.3

0.72

0.08

0.14

0.06

P(at least one component works) = P(exactly one component works) = P(second component works) =

Page 49: Math 3680 Lecture #3 Probability

Example: In a class of 50 students, what is the probability that at least two share a birthday?

Page 50: Math 3680 Lecture #3 Probability

Example: In Barcelona, the local men tend not to be overweight due to genetic and dietary reasons. However, the tourists from around the world whovisit Barcelona tend to be as overweight as the rest of Europe and America.

Suppose:• 2% of Barcelona men are overweight• 35% of Barcelona’s male tourists are overweight • 10% of the men in Barcelona are tourists

If a man is selected at random, what is the probability that he’s overweight?

Page 51: Math 3680 Lecture #3 Probability
Page 52: Math 3680 Lecture #3 Probability

Example: Suppose 2% of Barcelona men are overweight, while 35% of Barcelona’s male tourists are overweight. Also, suppose 10% of the men in Barcelona are tourists.

If you see an overweight man at a distance in Barcelona, what is the probability that he’s a tourist?

Solution: Let A = “man is overweight”, B = “man is a tourist.”Then we are given

P(A | B) = 0.35

P(A | B’ ) = 0.02

P(B) = 0.1

But we want P(B | A)… the reverse conditional probability.

Page 53: Math 3680 Lecture #3 Probability

.66.0

)02.0)(9.0()35.0)(1.0(

)35.0)(1.0(

)(

)(

)|(

overweightP

overweighttouristP

overweighttouristP

Page 54: Math 3680 Lecture #3 Probability

Example: In a study of 101 patients, 37 do not have coronary artery disease (CAD) and 64 have CAD. All 101 patients were given a certain test for CAD. Of the 37 patients without CAD, 34 had a negative test while 3 had a positive test. Of the 64 patients with CAD, 54 had a positive test and 10 had a negative test.

A man in his 50s with a family history of CAD sees a doctor, complaining of chest pain. Because of his age and family history, the doctor estimates the probability that the patient has CAD as 0.6. The patient is then given the above test, and it comes back positive. Find the posterior probability that the patient has CAD.

Page 55: Math 3680 Lecture #3 Probability

Solution: We begin with the tree diagram:

Disease positive

0.4

0.6

54/64

34/37

0.506

0.094

0.032

0.368

Disease negative

Test positive

Test positive

Test negative

Test negative

10/64

3/37

Page 56: Math 3680 Lecture #3 Probability

.94.0

)37/3)(4.0()64/54)(6.0(

)64/54)(6.0(

)(

)(

)|(

positivetestP

positivetestpositivediseaseP

positivetestpositivediseaseP

Page 57: Math 3680 Lecture #3 Probability

Definition:

Sensitivity = P(test positive | disease positive)

Specificity = P(test negative | disease negative)

In a perfect world, both of these conditional probabilities would be 100%, but that’s unrealistic. Bayes’ rule allows us to take the information from a clinical trial and use it in a diagnostic setting.

Measuring these two quantities is absolutely essential in a clinical medical trial. Let’s look up how many articles have been published which contain these words in the abstract.

Page 58: Math 3680 Lecture #3 Probability

Example: The receptor interleukin-8 is measured as a test for ectopic (tubal) pregnancy. For 17 women with ectopic pregnancy, 14 tested positive and 3 tested negative. For 55 women without an ectopic pregnancy, 10 tested positive and 45 tested negative.

(a) Find the sensitivity and specificity of the test.(b) An obstetrician treats a woman with mild pelvic pain. Based on her professional experience, the doctor believes the probability of an ectopic pregnancy to be 0.2. The patient is tested, and the test returns negative. Find the posterior probability of an ectopic pregnancy.

Page 59: Math 3680 Lecture #3 Probability