1、 Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 1Basic ProbabilityChapter 4 Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 2ObjectivesThe objectives for this chapter are:nTo understand basic probability concepts.nTo understand conditional probability nTo be able to us
2、e Bayes Theorem to revise probabilitiesnTo learn various counting rules Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 3Basic Probability ConceptsnProbability the chance that an uncertain event will occur(always between 0 and 1)nImpossible Event an event that has no chance of occurri
3、ng(probability=0)nCertain Event an event that is sure to occur(probability=1)Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 4Assessing ProbabilityThere are three approaches to assessing the probability of an uncertain event:1.a priori -based on prior knowledge of the process2.empiric
4、al probability3.subjective probabilityoutcomespossibleofnumbertotaloccurseventthein which waysofnumberTX based on a combination of an individuals past experience,personal opinion,and analysis of a particular situation outcomespossibleofnumbertotaloccurseventthein which waysofnumber Assuming all outc
5、omes are equally likelyprobability of occurrenceprobability of occurrence Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 5Example of a priori probabilityWhen randomly selecting a day from the year 2015 what is the probability the day is in January?2015in days ofnumber totalJanuaryin
6、days ofnumber January In Day ofy ProbabilitTX365312015in days 365Januaryin days 31 TX Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 6Example of empirical probabilityTaking StatsNot Taking StatsTotalMale 84145229Female 76134210Total160279439Find the probability of selecting a male ta
7、king statistics from the population described in the following table:191.043984people ofnumber totalstats takingmales ofnumber Probability of male taking stats Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 7Subjective probabilitynSubjective probability may differ from person to pers
8、onnA media development team assigns a 60%probability of success to its new ad campaign.nThe chief media officer of the company is less optimistic and assigns a 40%of success to the same campaignnThe assignment of a subjective probability is based on a persons experiences,opinions,and analysis of a p
9、articular situationnSubjective probability is useful in situations when an empirical or a priori probability cannot be computed Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 8EventsEach possible outcome of a variable is an event.nSimple eventnAn event described by a single character
10、isticne.g.,A day in January from all days in 2015nJoint eventnAn event described by two or more characteristicsne.g.A day in January that is also a Wednesday from all days in 2015nComplement of an event A (denoted A)nAll events that are not part of event Ane.g.,All days from 2015 that are not in Jan
11、uary Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 9Sample SpaceThe Sample Space is the collection of all possible eventse.g.All 6 faces of a die:e.g.All 52 cards of a bridge deck:Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 10Organizing&Visualizing EventsnVenn Dia
12、gram For All Days In 2015Sample Space(All Days In 2015)January DaysWednesdaysDays That Are In January and Are Wednesdays Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 11Organizing&Visualizing EventsnContingency Tables -For All Days in 2015nDecision TreesAll Days In 2015Not Jan.Jan.N
13、ot Wed.Wed.Wed.Not Wed.Sample SpaceTotalNumberOfSampleSpaceOutcomesNot Wed.27 286 313 Wed.4 48 52Total 31 334 365 Jan.Not Jan.Total 4 27 48286(continued)Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 12Definition:Simple ProbabilitynSimple Probability refers to the probability of a si
14、mple event.nex.P(Jan.)nex.P(Wed.)P(Jan.)=31/365P(Wed.)=52/365Not Wed.27 286 313 Wed.4 48 52Total 31 334 365 Jan.Not Jan.Total Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 13Definition:Joint ProbabilitynJoint Probability refers to the probability of an occurrence of two or more even
15、ts(joint event).nex.P(Jan.and Wed.)nex.P(Not Jan.and Not Wed.)P(Jan.and Wed.)=4/365P(Not Jan.and Not Wed.)=286/365Not Wed.27 286 313 Wed.4 48 52Total 31 334 365 Jan.Not Jan.Total Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 14nMutually exclusive eventsnEvents that cannot occur simu
16、ltaneouslyExample:Randomly choosing a day from 2015 A=day in January;B=day in FebruarynEvents A and B are mutually exclusiveMutually Exclusive Events Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 15Collectively Exhaustive EventsnCollectively exhaustive eventsnOne of the events must
17、occur nThe set of events covers the entire sample spaceExample:Randomly choose a day from 2015 A=Weekday;B=Weekend;C=January;D=Spring;nEvents A,B,C and D are collectively exhaustive(but not mutually exclusive a weekday can be in January or in Spring)nEvents A and B are collectively exhaustive and al
18、so mutually exclusive Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 16Computing Joint and Marginal ProbabilitiesnThe probability of a joint event,A and B:nComputing a marginal(or simple)probability:nWhere B1,B2,Bk are k mutually exclusive and collectively exhaustive eventsoutcomesel
19、ementaryofnumbertotalBandAsatisfyingoutcomesofnumber)BandA(P)BdanP(A)BandP(A)BandP(AP(A)k21 Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 17Joint Probability ExampleP(Jan.and Wed.)36542015in days ofnumber total Wed.are and Jan.in are that days ofnumber Not Wed.27 286 313 Wed.4 48 52
20、Total 31 334 365 Jan.Not Jan.Total Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 18Marginal Probability ExampleP(Wed.)36552365483654)Wed.andJan.P(Not Wed.)andJan.(PNot Wed.27 286 313 Wed.4 48 52Total 31 334 365 Jan.Not Jan.Total Copyright 2016,2013,2010 Pearson Education,Inc.Chapter
21、 4,Slide 19 P(A1 and B2)P(A1)TotalEventMarginal&Joint Probabilities In A Contingency TableP(A2 and B1)P(A1 and B1)EventTotal1Joint ProbabilitiesMarginal(Simple)Probabilities A1 A2B1B2 P(B1)P(B2)P(A2 and B2)P(A2)Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 20Probability Summary So F
22、arnProbability is the numerical measure of the likelihood that an event will occurnThe probability of any event must be between 0 and 1,inclusivelynThe sum of the probabilities of all mutually exclusive and collectively exhaustive events is 1CertainImpossible0.5100 P(A)1 For any event A1P(C)P(B)P(A)
23、If A,B,and C are mutually exclusive and collectively exhaustive Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 21General Addition RuleP(A or B)=P(A)+P(B)-P(A and B)General Addition Rule:If A and B are mutually exclusive,then P(A and B)=0,so the rule can be simplified:P(A or B)=P(A)+P
24、(B)For mutually exclusive events A and B Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 22General Addition Rule ExampleP(Jan.or Wed.)=P(Jan.)+P(Wed.)-P(Jan.and Wed.)=31/365+52/365-4/365 =79/365Dont count the four Wednesdays in January twice!Not Wed.27 286 313 Wed.4 48 52Total 31 334
25、365 Jan.Not Jan.Total Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 23Computing Conditional ProbabilitiesnA conditional probability is the probability of one event,given that another event has occurred:P(B)B)andP(AB)|P(AP(A)B)andP(AA)|P(BWhere P(A and B)=joint probability of A and B
26、 P(A)=marginal or simple probability of AP(B)=marginal or simple probability of BThe conditional probability of A given that B has occurredThe conditional probability of B given that A has occurred Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 24nWhat is the probability that a car h
27、as a GPS,given that it has AC?i.e.,we want to find P(GPS|AC)Conditional Probability ExamplenOf the cars on a used car lot,70%have air conditioning(AC)and 40%have a GPS.20%of the cars have both.Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 25Conditional Probability ExampleNo GPSGPSTo
28、talAC0.20.50.7No AC0.20.10.3Total0.40.6 1.0nOf the cars on a used car lot,70%have air conditioning(AC)and 40%have a GPS and 20%of the cars have both.0.28570.70.2P(AC)AC)andP(GPSAC)|P(GPS (continued)Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 26Conditional Probability ExampleNo GPS
29、GPSTotalAC0.20.50.7No AC0.20.10.3Total0.40.6 1.0nGiven AC,we only consider the top row(70%of the cars).Of these,20%have a GPS.20%of 70%is about 28.57%.0.28570.70.2P(AC)AC)andP(GPSAC)|P(GPS (continued)Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 27Using Decision TreesHas ACDoes not
30、have ACHas GPSDoes not have GPSHas GPSDoes not have GPSP(AC)=0.7P(AC)=0.3P(AC and GPS)=0.2P(AC and GPS)=0.5P(AC and GPS)=0.1P(AC and GPS)=0.27.5.3.2.3.1.AllCars7.2.Given AC or no AC:ConditionalProbabilities Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 28Using Decision TreesHas GPSD
31、oes not have GPSHas ACDoes not have ACHas ACDoes not have ACP(GPS)=0.4P(GPS)=0.6P(GPS and AC)=0.2P(GPS and AC)=0.2P(GPS and AC)=0.1P(GPS and AC)=0.54.2.6.5.6.1.AllCars4.2.Given GPS or no GPS:(continued)ConditionalProbabilities Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 29Independ
32、encenTwo events are independent if and only if:nEvents A and B are independent when the probability of one event is not affected by the fact that the other event has occurredP(A)B)|P(A Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 30Multiplication RulesnMultiplication rule for two e
33、vents A and B:P(B)B)|P(AB)andP(A P(A)B)|P(ANote:If A and B are independent,thenand the multiplication rule simplifies toP(B)P(A)B)andP(A Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 31Marginal ProbabilitynMarginal probability for event A:nWhere B1,B2,Bk are k mutually exclusive and
34、 collectively exhaustive events)P(B)B|P(A)P(B)B|P(A)P(B)B|P(A P(A)kk2211 Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 32Bayes TheoremnBayes Theorem is used to revise previously calculated probabilities based on new information.nDeveloped by Thomas Bayes in the 18th Century.nIt is a
35、n extension of conditional probability.Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 33Bayes Theoremnwhere:Bi=ith event of k mutually exclusive and collectively exhaustive eventsA=new event that might impact P(Bi)P(BB|P(A)P(BB|P(A)P(BB|P(A)P(BB|P(AA)|P(Bk k 2 2 1 1 i i i Copyright 2
36、016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 34Bayes Theorem ExamplenA drilling company has estimated a 40%chance of striking oil for their new well.nA detailed test has been scheduled for more information.Historically,60%of successful wells have had detailed tests,and 20%of unsuccessful well
37、s have had detailed tests.nGiven that this well has been scheduled for a detailed test,what is the probability that the well will be successful?Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 35nLet S=successful well U=unsuccessful wellnP(S)=0.4,P(U)=0.6 (prior probabilities)nDefine t
38、he detailed test event as DnConditional probabilities:P(D|S)=0.6 P(D|U)=0.2nGoal is to find P(S|D)Bayes Theorem Example(continued)Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 360.6670.120.240.24(0.2)(0.6)(0.6)(0.4)(0.6)(0.4)U)P(U)|P(DS)P(S)|P(DS)P(S)|P(DD)|P(SBayes Theorem Example(
39、continued)Apply Bayes Theorem:So the revised probability of success,given that this well has been scheduled for a detailed test,is 0.667 Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 37nGiven the detailed test,the revised probability of a successful well has risen to 0.667 from the
40、original estimate of 0.4Bayes Theorem ExampleEventPriorProb.Conditional Prob.JointProb.RevisedProb.S(successful)0.40.6(0.4)(0.6)=0.240.24/0.36=0.667U(unsuccessful)0.60.2(0.6)(0.2)=0.120.12/0.36=0.333Sum=0.36(continued)Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 38Counting Rules Ar
41、e Often Useful In Computing ProbabilitiesnIn many cases,there are a large number of possible outcomes.nCounting rules can be used in these cases to help compute probabilities.Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 39Counting RulesnRules for counting the number of possible out
42、comesnCounting Rule 1:nIf any one of k different mutually exclusive and collectively exhaustive events can occur on each of n trials,the number of possible outcomes is equal tonExamplenIf you roll a fair die 3 times then there are 63=216 possible outcomeskn Copyright 2016,2013,2010 Pearson Education
43、,Inc.Chapter 4,Slide 40Counting RulesnCounting Rule 2:nIf there are k1 events on the first trial,k2 events on the second trial,and kn events on the nth trial,the number of possible outcomes isnExample:nYou want to go to a park,eat at a restaurant,and see a movie.There are 3 parks,4 restaurants,and 6
44、 movie choices.How many different possible combinations are there?nAnswer:(3)(4)(6)=72 different possibilities(k1)(k2)(kn)(continued)Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 41Counting RulesnCounting Rule 3:nThe number of ways that n items can be arranged in order isnExample:nY
45、ou have five books to put on a bookshelf.How many different ways can these books be placed on the shelf?nAnswer:5!=(5)(4)(3)(2)(1)=120 different possibilitiesn!=(n)(n 1)(1)(continued)Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 42Counting RulesnCounting Rule 4:nPermutations:The num
46、ber of ways of arranging X objects selected from n objects in order isnExample:nYou have five books and are going to put three on a bookshelf.How many different ways can the books be ordered on the bookshelf?nAnswer:different possibilities(continued)X)!(nn!Pxn6021203)!(55!X)!(nn!Pxn Copyright 2016,2
47、013,2010 Pearson Education,Inc.Chapter 4,Slide 43Counting RulesnCounting Rule 5:nCombinations:The number of ways of selecting X objects from n objects,irrespective of order,isnExample:nYou have five books and are going to select three are to read.How many different combinations are there,ignoring th
48、e order in which they are selected?nAnswer:different possibilities(continued)X)!(nX!n!Cxn10(6)(2)1203)!(53!5!X)!(nX!n!Cxn Copyright 2016,2013,2010 Pearson Education,Inc.Chapter 4,Slide 44Chapter SummaryIn this chapter we covered:nUnderstanding basic probability concepts.nUnderstanding conditional probability nUsing Bayes Theorem to revise probabilitiesnVarious counting rules