62
Chapter 4: Probability 0 0.1 0.2 0.3 0.4 0.5 0.6 0 200 400 600 800 1000 Trials Relative Frequenc Limiting Relative Frequency

Chapter 4: Probability

Embed Size (px)

DESCRIPTION

Chapter 4: Probability. Limiting Relative Frequency. Chapter Goals. Learn the basic concepts of probability. Learn the rules that apply to the probability of both simple and compound events. - PowerPoint PPT Presentation

Citation preview

Page 1: Chapter 4: Probability

Chapter 4: Probability

0

0.1

0.2

0.3

0.4

0.5

0.6

0 200 400 600 800 1000Trials

Rel

ativ

e F

req

uen

cy

Limiting Relative Frequency

Page 2: Chapter 4: Probability

Chapter Goals

• Learn the basic concepts of probability.

• Learn the rules that apply to the probability of both simple and compound events.

• In order to make inferences, we need to study sample results in situations in which the population is known.

Page 3: Chapter 4: Probability

4.1: The Nature of Probability

Example: Consider an experiment in which we roll two six-sided fair dice and record the number of threes face up. The only possible outcomes are 0 three’s, 1 three, or 2 three’s. Here are the results after 100 and after 1000 rolls.

100 Rolls 1000 RollsOutcome Frequency Outcome Frequency

0 80 0 6901 19 1 2822 1 2 28

Page 4: Chapter 4: Probability

We can express these results (from the 1000 rolls) in terms of relative frequencies and display the results using a histogram.

0 1 2

Three's Face Up

0.0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

Rel

ativ

e F

requ

ency

Page 5: Chapter 4: Probability

If we continue this experiment for several thousand more rolls:

1. The frequencies will have approximately a 25:10:1 ratio in totals.

2. The relative frequencies will settle down.

Note: We can simulate many probability experiments.

1. Use random number tables.

2. Use a computer to randomly generate number values representing the various experimental outcomes.

3. Key to either method is to maintain the probabilities.

Page 6: Chapter 4: Probability

4.2: Probability of Events

Probability that an Event Will Occur: The relative frequency with which that event can be expected to occur.

The probability of an event may be obtained in three different ways:

Empirically

Theoretically

Subjectively

Page 7: Chapter 4: Probability

Experimental or empirical probability:

1. The observed relative frequency with which an event occurs.

2. Prime notation is used to denote empirical probabilities:

3. n(A): number of times the event A has occurred.

4. n: number of times the experiment is attempted.

Question: What happens to the observed relative frequency as n increases?

Pn

n( )

( )A

A

Page 8: Chapter 4: Probability

Example: Consider tossing a fair coin. Define the event H as the occurrence of a head. What is the probability of the event H, P(H)?

1. In a single toss of the coin, there are two possible outcomes.

2. Since the coin is fair, each outcome (side) should have an equally likely chance of occurring.

3. Intuitively, P(H) = 1/2 (the expected relative frequency).

Note:

(a) This does not mean exactly one head will occur in every two tosses of the coin.

(b) In the long run, the proportion of times that a head will occur is approximately 1/2.

Page 9: Chapter 4: Probability

To illustrate the long-run behavior:

1. Consider an experiment in which we toss the coin several times and record the number of heads.

2. A trial is a set of 10 tosses.

3. Graph the relative frequency and cumulative relative frequency of occurrence of a head.

4. A cumulative graph demonstrates the idea of long-run behavior.

5. This cumulative graph suggests a stabilizing, or settling down, effect on the observed cumulative probability.

6. This stabilizing effect, or long-term average value, is often referred to as the law of large numbers.

Page 10: Chapter 4: Probability

Experimental results of tossing a coin 10 times each trial:Number of Relative Cumulative

Trial Heads Observed Frequency Relative Frequency1 5 5/10 5/10 = 0.50002 4 4/10 9/20 = 0.45003 4 4/10 13/30 = 0.43334 5 5/10 18/40 = 0.45005 6 6/10 24/50 = 0.48006 7 7/10 28/60 = 0.46677 6 6/10 34/70 = 0.48578 4 4/10 38/80 = 0.47509 7 7/10 45/90 = 0.5000

10 3 3/10 48/100 = 0.480011 4 4/10 52/110 = 0.472712 6 6/10 58/120 = 0.483813 7 7/10 65/130 = 0.500014 4 4/10 69/140 = 0.492915 3 3/10 72/150 = 0.480016 7 7/10 79/160 = 0.493817 6 6/10 85/170 = 0.500018 3 3/10 88/180 = 0.488919 6 6/10 94/190 = 0.494720 4 4/10 98/200 = 0.4900

Page 11: Chapter 4: Probability

0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0 5 10 15 20

Relative Frequency:

Expected value = 1/2

Trial

Page 12: Chapter 4: Probability

Cumulative Relative Frequency:

0.4

0.45

0.5

0.55

0.6

0 5 10 15 20

Expected value = 1/2

Page 13: Chapter 4: Probability

Law of Large Numbers: If the number of times an experiment is repeated is increased, the ratio of the number of successful occurrences to the number of trials will tend to approach the theoretical probability of the outcome for an individual trial.

Interpretation:The law of large numbers says: the larger the number of experimental trials n, the closer the empirical probability (A) is expected to be to the true probability P(A).

In symbols:

As )A()A(' , PPn

P'

Page 14: Chapter 4: Probability

4.3: Simple Sample Spaces

• We need to talk about data collection and experimentation more precisely.

• With many activities, like tossing a coin, rolling a die, selecting a card, there is uncertainty as to what will happen.

• We will study and characterize this uncertainty.

Page 15: Chapter 4: Probability

Experiment: Any process that yields a result or an observation.

Outcome: A particular result of an experiment.

Example: Suppose we select two students at random and ask each if they have a car on campus.

1. A list of possible outcomes:

(Y, Y), (Y, N), (N, Y), (N, N)

2. This is called ordered pair notation.

3. The outcomes may be displayed using a tree diagram.

Page 16: Chapter 4: Probability

Tree diagram:

Student 1 Student 2 Outcomes

Y Y, YY

N Y, N

Y N, YN

N N, N

1. This diagram consists of four branches: 2 first generation branches and 4 second generation branches.

2. Each branch shows a possible outcome.

Page 17: Chapter 4: Probability

Sample Space: The set of all possible outcomes of an experiment. The sample space is typically called S and may take any number of forms: a list, a tree diagram, a lattice grid system, etc. The individual outcomes in a sample space are called sample points. n(S) is the number of sample points in the sample space.

Event: any subset of the sample space. If A is an event, then n(A) is the number of sample points that belong to A.

Example: For the student car example above:

S = { (Y, Y), (Y, N), (N, Y), (N, N) }

n(S) = 4

Page 18: Chapter 4: Probability

Example: An experiment consists of two trials. The first is tossing a penny and observing a head or a tail; the second is rolling a die and observing a 1, 2, 3, 4, 5, or 6. Construct the sample space.

S = { H1, H2, H3, H4, H5, H6, T1, T2, T3, T4, T5, T6 }

Example: Three voters are randomly selected and asked if they favor an increase in property taxes for road construction in the county. Construct the sample space.

S = { NNN, NNY, NYN, NYY, YNN, YNY, YYN, YYY}

Page 19: Chapter 4: Probability

Example: An experiment consists of selecting electronic parts from an assembly line and testing each to see if it passes inspection (P) or fails (F). The experiment terminates as soon as one acceptable part is found or after three parts are tested. Construct the sample space.

Outcome

F FFF

F

F P FFP

P FP

P P

S = { FFF, FFP, FP, P }

Page 20: Chapter 4: Probability

Example: The 1200 students at a local university have been cross tabulated according to resident and college status:

The experiment consists of selecting one student at random from the entire student body.

n(S) = 1200

Arts and Sciences Business

Resident 600 280Nonresident 175 145

Page 21: Chapter 4: Probability

Example: On the way to work, some employees at a certain company stop for a bagel and/or a cup of coffee. The accompanying Venn diagram summarizes the behavior of the employees for a randomly selected work day.

The experiment consists of selecting one employee at random.

n(S) = 77

Coffee Bagel

1832 16

11

Page 22: Chapter 4: Probability

Note:

1. The outcomes in a sample space can never overlap.

2. All possible outcomes must be represented.

3. These two characteristics are called mutually exclusive and all inclusive.

Page 23: Chapter 4: Probability

4.4: Rules of Probability

• Consider the concept of probability and relate it to the sample space.

• Recall: the probability of an event is the relative frequency with which the event could be expected to occur, the long-term average.

Page 24: Chapter 4: Probability

Equally Likely Events:

1. In a sample space, suppose all sample points are equally likely to occur.

2. The probability of an event A is the ratio of the number of sample points in A to the number of sample points in S.

3. In symbols:

4. This formula gives a theoretical probability value of event A’s occurrence.

5. The use of this formula requires the existence of a sample space in which each outcome is equally likely.

Pnn S

( )( )( )

AA

Page 25: Chapter 4: Probability

Example: A fair coin is tossed 5 times, and a head (H) or a tail (T) is recorded each time. What is the probability of A = {exactly one head in 5 tosses}, andB = {exactly 5 heads}?

The outcomes consist of a sequence of 5 H’s and T’s

A typical outcome: HHTTH

There are 32 possible outcomes, all equally likely.

A = {HTTTT, THTTT, TTHTT, TTTHT, TTTTH}

B = {HHHHH}

Pnn S

( )( )( )

AA 5

32

Pnn S

( )( )( )

BB 1

32

Page 26: Chapter 4: Probability

Subjective Probability:

1. Suppose the sample space elements are not equally likely, and empirical probabilities cannot be used.

2. Only method available for assigning probabilities may be personal judgment.

3. These probability assignments are called subjective probabilities.

4. Personal judgment of the probability is expressed by comparing the likelihood among the various outcomes.

Page 27: Chapter 4: Probability

Basic Probability Ideas:

1. Probability represents a relative frequency.

2. P(A) is the ratio of the number of times an event can be expected to occur divided by the number of trials.

3. The numerator of the probability ratio must be a positive number or zero.

4. The denominator of the probability ratio must be a positive number (greater than zero).

5. The number of times an event can be expected to occur in n trials is always less than or equal to the total number of trials, n.

Page 28: Chapter 4: Probability

Properties:

1. The probability of any event A is between 0 and 1.

2. The sum of the probabilities of all outcomes in the sample space is 1.

Note:

1. The probability is zero if the event cannot occur.

2. The probability is one if the event occurs every time (a sure thing).

0 1 P( )A

P( )Aall outcomes

1

Page 29: Chapter 4: Probability

Example: On the way to work Bob’s personal judgment is that he is four times more likely to get caught in a traffic jam (TJ) than have an easy commute (EC). What values should be assigned to P(TJ) and P(EC)?

P P( ) ( )TJ EC 4

P P( ) ( )TJ EC 1

4 1

5 1

15

4 415

45

P P

P

P

P P

( ) ( )

( )

( )

( ) ( )

EC EC

EC

EC

TJ EC

Page 30: Chapter 4: Probability

Odds: another way of expressing probabilities.

If the odds in favor of an event A are a to b, then

1. The odds against A are b to a.

2. The probability of event A is

3. The probability that event A will not occur is

Pa

a b( )A

Pb

a b( )A does not occur

Page 31: Chapter 4: Probability

Example: The odds in favor of you passing an introductory statistics class are 11 to 3. Find the probability you will pass and the probability you will fail.

Using the preceding notation: a = 11 and b = 3.

Complement of an Event: The set of all sample points in the sample space that do not belong to event A. The complement of event A is denoted by (read “A complement”).

P( )pass

1111 3

1114

P( )fail

311 3

314

A

Page 32: Chapter 4: Probability

Example:

1. The complement of the event “success” is “failure.”

2. The complement of the event “rain” is “no rain.”

3. The complement of the event “at least 3 patients recover” out of 5 patients is “2 or fewer recover.”

Note:

1.

2.

3. Every event A has a complementary event

4. Complementary probabilities are very useful when the question asks for the probability of “at least one.”

P P( ) ( )A A for any event A 1

P P( ) ( )A A 1

A

Page 33: Chapter 4: Probability

Example: A fair coin is tossed 5 times, and a head(H) or a tail (T) is recorded each time. What is the probability of

A = {at least one head in 5 tosses},

B = {at most 3 heads in 5 tosses}?

P P

P

( ) ( )

( )

A A

0 heads in 5 tosses

1

1

11

323132

P P

P

P P

( ) ( )

( )

( ( ) ( ))

B B

4 or 5 heads

4 heads 5 heads

1

1

1

15

321

321

632

2632

1316

Page 34: Chapter 4: Probability

Example: A local automobile dealer classifies purchases by number of doors and transmission type. The table below gives the number of each classification.

If one customer is selected at random, find the probability that

1. The selected individual purchased a car with automatic transmission.

2. The selected individual purchased a 2-door car.

Manual AutomaticTransmission Transmission

2-door 75 1554-door 85 170

Page 35: Chapter 4: Probability

Solution:

P( )Automatic Transmission

155 17075 85 155 170

325485

6597

P( )2 - door

75 15575 85 155 170

230485

4697

Page 36: Chapter 4: Probability

4.5: Mutually Exclusive Events and the Addition Rule

• Compound Events: formed by combining several simple events.

• The probability that either event A or event B will occur: P(A or B).

• The probability that both events A and B will occur: P(A and B).

• The probability that event A will occur given that event B has occurred: P(A | B)

Page 37: Chapter 4: Probability

Mutually Exclusive Events: Events defined in such a way that the occurrence of one event precludes the occurrence of any of the other events. (In short, if one of them happens, the others cannot happen.)

Note:

1. Complementary events are also mutually exclusive.

2. Mutually exclusive events are not necessarily complementary.

Page 38: Chapter 4: Probability

Example: The following table summarizes visitors to a local amusement park.

One visitor from this group is selected at random.

1. Define the event A as “the visitor purchased an all-day pass.”

2. Define the event B as “the visitor selected purchased a half-day pass.”

3. Define the event C as “the visitor selected is female.”

All-Day Half-DayPass Pass Total

Male 1200 800 2000Female 900 700 1600

Total 2100 1500 3600

Page 39: Chapter 4: Probability

Solution:

1. The events A and B are mutually exclusive.

2. The events A and C are not mutually exclusive. The intersection of A and C can be seen in the table above or in the Venn diagram below.

A C

9001200 700

800

Page 40: Chapter 4: Probability

General Addition Rule: Let A and B be two events defined in a sample space S.

Illustration:

Note: If two events A and B are mutually exclusive:

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

P( )A and B 0

A B

Page 41: Chapter 4: Probability

Special Addition Rule: Let A and B be two events defined in a sample space. If A and B are mutually exclusive events, then

This can be expanded to consider more than two mutually exclusive events:

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

P P P P( ) ( ) ( ) ( )A or B or C or ... or E A B E

AB

CD

Page 42: Chapter 4: Probability

Example: All employees at a certain company are classified as only one of the following: manager (A), service (B), sales (C), or staff (D). It is known that P(A) = .15, P(B) = .40, P(C) = .25, and P(D) = .20

P P( ) ( ) . .A A 1 1 15 85

P( )A and B (A and B are mutually exclusive.)0

P P P( ) ( ) ( ) . . .B or C B C 40 25 65

P P P P( ) ( ) ( ) ( ) . . . .A or B or C A B C 15 40 25 80

Page 43: Chapter 4: Probability

Example: A consumer is selected at random. The probability the consumer has tried a snack food (F) is .5, tried a new soft drink (D) is .6, and tried both the snack food and the soft drink is .2.

P

P P P P

( )

( ) ( ) ( ) ( ) . . . .

Tried the snack food or the soft drink

F or D F D F and D 5 6 2 9

P P P( ) ( ) ( ) . .Not tried the snack food F F 1 1 5 5

P

P P

( )

[( )'] ( ) . .

Tried neither the snack food nor the soft drink

F or D F or D 1 1 9 1

P P P( ) ( ) ( ) . . .Tried only the soft drink D F and D 6 2 4

Page 44: Chapter 4: Probability

4.6: Independence, the Multiplication Rule, and Conditional Probability

Independent Events: Two events A and B are independent events if the occurrence (or nonoccurrence) of one does not affect the probability assigned to the occurrence of the other.

Note: If two events are not independent, they are dependent.

Page 45: Chapter 4: Probability

Background:

1. Sometimes two events are related in such a way that the probability of one depends upon whether the second event has occurred.

2. Partial information may be relevant to the probability assignment.

Conditional Probability: The symbol P(A | B) represents the probability that A will occur given B has occurred. This is called conditional probability.

1.

2. Given B has occurred, the relevant sample space is no longer S, but B (reduced sample space).

3. A has occurred if and only if the event A and B has occurred.

PP

P( | )

( )( )

A BA and B

B

Page 46: Chapter 4: Probability

Independent Events: Two events A and B are independent events if

P(A | B) = P(A) or P(B | A) = P(B)

Note:

1. If A and B are independent, the occurrence of B does not affect the occurrence of A.

2. If A and B are independent, then so are:

3. Independence cannot be shown on a Venn diagram.

A and B

A and B

A and B

Page 47: Chapter 4: Probability

Example: Consider the experiment in which a single fair die is rolled: S = {1, 2, 3, 4, 5, 6 }. Define the following events:A = “a 1 occurs,” B = “an odd number occurs,” andC = “an even number occurs.”

PP

P( | )

( )( )

//

A BA and B

B 1 6

3 613

PP

P( | )

( )( ) /

A CA and C

C 0

3 60

PP

P( | )

( )( )

//

B AB and A

A 1 6

1 61

Page 48: Chapter 4: Probability

Example: In a sample of 1200 residents, each person was asked if he or she favored building a new town playground. The responses are summarized in the table below.

If one resident is selected at random, what is the probability the resident will:

1. Favor the new playground?

2. Favor the playground if the person selected is less than 30?

3. Favor the playground if the person selected is more than 50?

4. Are the events F and M independent?

Age Favor (F) Oppose Total

Less than 30 (Y) 250 50 300

30 to 50 (M) 600 75 675More than 50 (O) 100 125 225

Total 950 250 1200

Page 49: Chapter 4: Probability

Solution:

P( )F 9501200

1924

PP

P( | )

( )( )

//

F YF and Y

Y 6 250 1200

300 12005

PP

P( | )

( )( )

//

F OF and O

O 100 1200

225 120049

PP

PP( | )

( )( )

//

( )F MF and M

MF

F and M are dependent

600 1200675 1200

89

Page 50: Chapter 4: Probability

General Multiplication Rule: Let A and B be two events defined in sample space S. Then

or

Note: How to recognize situations that result in the compound event “and.”

1. A followed by B.

2. A and B occurred simultaneously.

3. The intersection of A and B.

4. Both A and B.

5. A but not B (equivalent to A and not B).

P P P( ) ( ) ( | )A and B A B A

P P P( ) ( ) ( | )A and B B A B

Page 51: Chapter 4: Probability

Special Multiplication Rule: Let A and B be two events defined in sample space S. If A and B are independent events, then

This formula can be expanded. If A, B, C, …, G are independent events, then

Example: Suppose the event A is “Allen gets a cold this winter,” B is “Bob gets a cold this winter,” and C is “Chris gets a cold this winter.” P(A) = .15, P(B) = .25, P(C) = .3, and all three events are independent. Find the probability that

1. All three get colds this winter.

2. Allen and Bob get a cold but Chris does not.

3. None of the three gets a cold this winter.

P P P( ) ( ) ( )A and B A B

P P P P P( ) ( ) ( ) ( ) ( )A and B and C and ... and G A B C G

Page 52: Chapter 4: Probability

Solution:

P

P P P P

( )

( ) ( ) ( ) ( )

(. )(. )(. ) .

All three get colds this winter

A and B and C A B C 15 25 30 0113

P

P P P P

( )

( ) ( ) ( ) ( )

(. )(. )(. ) .

Allen and Bob get a cold, but Chris does not

A and B and C A B C 15 25 70 0263

P

P P P P

( )

( ) ( ) ( ) ( )

(. )(. )(. ) .

None of the three gets a cold this winter

A and B and C A B C 85 75 70 4463

Page 53: Chapter 4: Probability

Note:

1. Independence and mutually exclusive are two very different concepts.

a. Mutually exclusive says the two events cannot occur together, that is, they have no intersection.

b. Independence says each event does not affect the other event’s probability.

2. P(A and B) = P(A) P(B) when A and B are independent.

a. Since P(A) and P(B) are not zero, P(A and B) is nonzero.

b. Thus, independent events have an intersection.

3. Events cannot be both mutually exclusive and independent.

a. If two events are independent, then they are not mutually exclusive.

b. If two events are mutually exclusive, then they are not independent.

Page 54: Chapter 4: Probability

4.7: Combining the Rules of Probability

• Many probability problems can be represented by tree diagrams.

• Using the tree diagram, the addition and multiplication rules are easy to apply.

Page 55: Chapter 4: Probability

Example: A certain company uses three overnight delivery services: A, B, and C. The probability of selecting service A is 1/2, of selecting B is 3/10, and of selecting C is 1/5. Suppose the event T is “on time delivery.” P(T|A) = 9/10, P(T|B) = 7/10, and P(T|C) = 4/5. A service is randomly selected to deliver a package overnight. Construct a tree diagram representing this experiment.

Note:

1. A set of branches that initiate from a single point has a total probability 1.

2. Each outcome for the experiment is represented by a branch that begins at the common starting point and ends at the terminal points at the right.

Page 56: Chapter 4: Probability

The resulting tree diagram

Service Delivery

T

A

T

B

T

C

T

T

T

1 2/

3 10/

1 5/

9 10/

1 10/

7 10/

3 10/

4 5/

1 5/

Page 57: Chapter 4: Probability

Using the tree diagram:

1. The probability of selecting service A and having the package delivered on time.

2. The probability of having the package delivered on time.

P P P( ) ( ) ( | )A and T A T A 12

910

920

P P P P

P P P P P P

( ) ( ) ( ) ( )

( ) ( | ) ( ) ( | ) ( ) ( | )

T A and T B and T C and T

A T A B T B C T C

12

910

310

710

15

45

920

21100

425

4150

Page 58: Chapter 4: Probability

Example: A manufacturer is testing the production of a new product on two assembly lines. A random sample of parts is selected and each part is inspected for defects. The results are summarized in the table below.

Suppose a part is selected at random.

1. Find the probability the part is defective.

2. Find the probability the part is produced on Line 1.

3. Find the probability the part is good or produced on Line 2.

Good (G) Defective (D) Total

Line 1 (1) 70 40 110Line 2 (2) 80 25 105

Total 150 65 215

Page 59: Chapter 4: Probability

Solution:

1.

2.

3.

P( )D

(total defective divided by total number of parts)

65215

P( )1

(total produced by Line 1 divided by total number of parts)

110215

Pn

n S

P P P

( )( )

( )

( ) ( ) ( )

G or 2G or 2

(total good or produced on Line 2 divided by total parts)

G G and 2

175215

2150215

105215

80215

Page 60: Chapter 4: Probability

Example: This problem involves testing individuals for the presence of a disease. Suppose the probability of having the disease (D) is .001. If a person has the disease, the probability of a positive test result (Pos) is .90. If a person does not have the disease, the probability of a negative test result (Neg) is .95. For a person selected at random:

1. Find the probability of a negative test result given the person has the disease.

2. Find the probability of having the disease and a positive test result.

3. Find the probability of a positive test result.

Page 61: Chapter 4: Probability

Resulting tree diagram:

Test

Disease Result

Pos

D

Neg

Pos

Neg

D

.001

.999

.90

.10

.05

.95

Page 62: Chapter 4: Probability

Solution:

1.

2.

3.

P P( ) ( ) . .Neg|D Pos|D 1 1 90 10

P P P( ) ( ) ( ) (. )(. ) .D and Pos D Pos|D 001 90 0009

P P P

P P P P

( ) ( ) ( )

( ) ( ) ( ) ( | )

(. )(. ) (. )(. ) .

Pos D and Pos D and Pos

D Pos|D D Pos D

001 90 999 05 05085