24
Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering and the Sciences by Jay L. Devore, Duxbury 1995 (4th edition) This topic also draws from Probability Concepts in Engineering Planning and Design: Volume I - Basic

Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Embed Size (px)

Citation preview

Page 1: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Topic 2: Intro to probability

CEE 11 Spring 2002

Dr. Amelia Regan

These notes draw liberally from the class text, Probability and Statistics for Engineering and the Sciences by Jay L. Devore, Duxbury 1995 (4th edition)

This topic also draws from Probability Concepts in Engineering Planning and Design: Volume I - Basic Principles by A. H-S. Ang and W. H.Tang, John

Wiley & Sons, 1975

Page 2: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

definitions The set of all outcomes in a probabilistic problem is collectively a

sample space. Each of the individual possibilities is a sample point.

An event is defined as a subset of the sample space.

Sample space may be discrete or continuous.

A discrete sample space may be finite or countably infinite. Examples: {H,T}, {1,2,3,4,5,6}, {1/2,1/4,1/8,…1/n}

Page 3: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Class Exercise Problem 3.6, slightly modified. Starting at a fixed time, each car entering an intersection is observed to see whether it turns left (L), right

(R) or goes straight ahead (S). The experiment terminates as soon as a car is observed to turn left.

Let the random variable X be equal to the number of cars entering the intersection before a car turns left.

What are the possible values for X?

List 5 outcomes and their associated X values.

Page 4: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

definitions

If the occurrence of one event precludes the occurrence of another event the two are said to be mutually exclusive. If two events A and B are mutually exclusive then:

P(A B)=0

Two or more events are said to be collectively exhaustive if the union of all of these events constitute the underlying sample space.

Page 5: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

some basic properties of probability

For any event A, P(A) 0. (no negative probabilities)

Let S represent the sample space, P(S) = 1 (probabilities sum to one)

if A1, A2, ...,An is a finite collection of mutually exclusive events, then

(the probability that at least one will occur is the sum of the individual probabilities of each occurring)

1 21

( ... ) ( )n

n ii

P A A A P A

Page 6: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

some basic properties of probability

For any event A

P(A) = 1-P(A)

Illustrate this with a Venn Diagram here

Page 7: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

some basic properties of probability

For any two events A and B

Illustrate this with a Venn Diagram here

P(A B) = P(A)+P(B)-P(A B)

Page 8: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

some basic properties of probability

Similarly

P(A B C) = P(A)+P(B)+P(C)

-P(A B)-P(A C)-P(B C)

+P(A B C)

Illustrate this with a Venn Diagram here

Page 9: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

some basic properties of probability

For any events A and B________

________

A B = A B de Morgan's Rule

P(A B) = P(A B)

Illustrate this with a Venn Diagram here

Page 10: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

conditional probability

For any two events A and B with P(B) > 0, the conditional probability of A given that B has occurred is defined by

( )( | )

( )

P A BP A B

P B

Note that the multiplication rule for P(A intersection B) follows directly

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

Page 11: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Example In a game show a contestant is asked to pick from one of three doors. Behind one of

the doors is a new car which he gets to keep if he selects that door.

1 21 2

2

1( ) 13

( | )2( ) 23

P D DP D D

P D

The contestant picks door number 1. One of the other two doors is selected at random and is opened (say door 2). The car is

not behind door 2. Now what are the chances that the car is behind door number 1?

1 2 3

1( ) ( ) ( )

3P D P D P D

Page 12: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

The “Monty Hall” Problem This is actually a well known problem. In a game show a contestant is asked to pick from one of three doors. Behind one of the doors is a new

car which he gets to keep if he selects that door.

The contestant picks door number 1. The host (Monty Hall), who knows where the prize is, opens a door behind which there is no prize.

The contestant is offered a chance to switch his choice. Should he switch?

1 2 3

1( ) ( ) ( )

3P D P D P D

Page 13: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Bayes’ Theorem The multiplication rule

leads directly to Bayes’ Theorem which is used to compute posterior probabilities from given prior probabilities. First we need the law of total probability...

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

Page 14: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Bayes’ Theorem Let A1, A2, ..., An be a collection of n mutually exclusive and collectively exhaustive events.

Then for any other event B for which P(B) > 0, The law of total probability states that

1 1 2 2

1

( ) ( | ) ( ) ( | ) ( ) ... ( | ) ( )

( | ) ( )

n n

n

i ii

P B P B A P A P B A P A P B A P A

P B A P A

Page 15: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Bayes’ Theorem

Remember the diagram associated with the law of total probability The rectangular region represents the universe which is divided into non-overlapping areas which together cover the whole region. The

probability that B occurs the sum of the probabilities that B occurs with any of the mutually exclusive and collectively exhaustive events.

BA1 A2 … An

Page 16: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Bayes’ Theorem

Let A1, A2, ..., An be a collection of n mutually exclusive and collectively exhaustive events with P(Ai) > 0 for i=1,...,n. Then for any other event B for which P(B) > 0

1

( ) ( | ) ( )( | ) 1, 2,...

( ) ( | ) ( )

k k kk n

i ii

P A B P B A P AP A B k n

P B P B A P A

The second form follows directly from the first by using the multiplication

rule in the numerator and the law of total probability in the denominator

Page 17: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Example (law of total probability)

Assume that 1 in 10,000 adults is inflicted with a rare disease. A diagnostic test is developed – the test is 99% accurate (1% false negatives and 1% false positives) If a person tests positive – what is the probability she has the disease? – Less than 10%?

09016.001098.0

00099.0

00999.000999.0

00099.0

)999.0)(01.0()001.0)(99.0(

)99.0)(001.0(

)()|()()|(

)(

)(

)()|(

DPDPPDPDPP

PDP

PP

PDPPDP

Page 18: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

independence

Two events A and B are independent if

They are dependent otherwise

( | ) ( )P A B P A

Page 19: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

independence

Remember that in general

However, if A and B are independent then

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

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

In fact, A and B are independent if and only if the above is true

Page 20: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

independence

Events A1, A2, ...., An are mutually independent if for every k (k = 2,3,...,n) and every subset of indices i1, i2, i3,...,in,

2 2( ... ) ( ) ( ) ( )

i n i ni i i i i iP A A A P A P A P A

Page 21: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

independence

Question: If two events are mutually exclusive can they also be independent?

Page 22: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Class Exercise A construction company has the opportunity to bid on three jobs (A,B and C). From historical data

the company believes its changes of winning each job is 0.20, 0.50 and 0.10. Its chances of winning all three jobs is 0.05. The probability that it will win both A and B is 0.10. For A and C and B and C the probabilities are 0.07 and 0.06.

Are the events that the construction company is awarded jobs A, B and C independent? Why or why not?

Page 23: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Class Exercise A construction company has the opportunity to bid on three jobs (A,B and C). From historical data

the company believes its changes of winning each job is 0.20, 0.50 and 0.10. Its chances of winning all three jobs is 0.05. The probability that it will win both A and B is 0.10. For A and C and B and C the probabilities are 0.07 and 0.06.

Calculate the following probabilities: The company wins none of the jobs The company wins only job A The company wins only one of the jobs

Hint -- draw and label a Venn Diagram

Page 24: Topic 2: Intro to probability CEE 11 Spring 2002 Dr. Amelia Regan These notes draw liberally from the class text, Probability and Statistics for Engineering

Class Exercise A construction company has the opportunity to bid on three jobs (A,B and C). From historical data

the company believes its changes of winning each job is 0.20, 0.50 and 0.10. Its chances of winning all three jobs is 0.05. The probability that it will win both A and B is 0.10. For A and C and B and C the probabilities are 0.07 and 0.06.

Calculate the following conditional probabilities: A given B C given A C given A and B