Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Lecture 2 Review β Conditional Probability, Independence, Bayeβs Rule Also, if the sample space is divided into mutually exclusive and exhaustive events, a new event in the sample space is given by the sum of the intersections of this new event with all the mutually exclusive and exhaustive events. Denoting the mutually exclusive and exhaustive events by Ai and the new event B, the above can be represented as, π π(π΅) = β π(π΅ β© π΄π ) π=1 This could then be stated in terms of conditional probabilities as, π π(π΅) = β π(π΅/π΄π ). π(π΄π ) π=1 This is the theorem of total probability. Figure Error! No text of specified style in document.-1 β Theorem of Total Probability Counting Techniques β Multiplication Rule, Permutations, and Combinations Counting techniques are important tools to count the number of outcomes in the sample space or an event. These computed number of outcomes may then be used to calculate the probability of an event. Multiplication Rule is the fundamental counting rule from which special cases such as permutations and combinations can be derived. The multiplication rule can be stated as, βIf there are n1 outcomes in experiment 1 and n2 outcomes in experiment 2, then there are n1 x n2 outcomes if the two experiments are done in seriesβ. A tree diagram is an easy way to understand the multiplicative rule. To this end, letβs consider two experiments. Experiment 1 β Toss a coin; Experiment 2 β Roll a die There are two outcomes when you toss a coin and six outcomes when you roll a die. By the multiplication rule, if you do the two experiments in series there would be 2 x 6 = 12 outcomes. This can be seen in the following tree diagram. Figure Error! No text of specified style in document.-2 β Tree Diagram for Coin Toss and Die Roll in Series The multiplication rule can be extended to any number of experiments, and can be stated for the general case as, βIf there are n1 outcomes in experiment 1, n2 outcomes in experiment 2, and so on up to nk outcomes for experiment k, then there are n1 x n2 x β¦ x nk outcomes if the k experiments are done in seriesβ. Example A restaurant menu has a choice of four appetizers, three soups, eleven main courses, five salad dressings, and six desserts. a. If a meal consists of an appetizer, a soup, a main course, a salad dressing, and a dessert, in how many ways can a meal be chosen? b. In how many ways can a meal be chosen if you can order only one appetizer or one soup, but not both? Solution Part a) Using the multiplicative rule, na x ns x nm x nl x nd = 4 x 3 x 11 x 5 x 6 = 1980 Part b) Since we can choose only one of soup or appetizer there are 7 ways completing the first step, (na + ns) x nm x nl x nd = 7 x 11 x 5 x 6 = 1155 The multiplication rule can be applied to all counting situations. For example, if we want to know the number of ways of arranging n objects, the situation can be thought of as a series of experiments where in each experiment you pick one object. The process is shown in Table 1. Table 1 β Number of ways of arranging n objects Trial No. of Choices 1 2 3 β¦ n n n-1 n-2 β¦ 1 By the multiplicative rule, we multiply n, n-1, n-2, β¦, and 1 resulting in, ππ. ππ π€ππ¦π ππ πππππππππ π ππππππ‘π = π! Now, if we want to compute the number of ways of selecting k objects from a total of n where the order of selection is important, the following situation results, Table 2 β Number of ways of arranging n objects Trial No. of Choices 1 2 3 β¦ k n n-1 n-2 β¦ n-k+1 The number of choices where the order of selection is important is called permutations. Based on Table 2 and the multiplication rule, the number of permutations of k objects chosen from n is given by, π ππ = π! (π β π)! The situation is slightly different if the order of selection is not important. That is, any group of k objects, whatever the order in which they are selected, are equivalent. Combinations are the number of ways of choosing k objects from n given that all orders of their choice are equivalent. To obtain this, recall that any selection of k objects have k! arrangements. So we have πππΆ selections, and each selection has k! arrangements. Therefore, a collection of k objects selected from n can be arranged in k! ways, a second collection of k objects selected from n can be arranged in k! ways and so on β¦ till, a πππΆ collection of k objects selected from n can be arranged in k! ways. But we already know the number of arrangements of k objects selected from n. They are the number of permutations. Putting these two together, we have, π ππΆ × π! = π! (π β π)! Therefore, the number of combinations of k objects selected from n is obtained by dividing the number of permutations by k!. π ππΆ = π! (π β π)! π! Example A group contains 6 individuals. Two members are randomly selected from this group and given a sandwich each. a. In how many ways can the two be selected, if both get the same kind of sandwich? b. In how many ways can the two be selected, if the first to be selected gets steak and the second gets chicken? Solution Part a) This is a combinations problem, because the order of choice does not matter. Both of them get the same kind of sandwich. Therefore, 6! 6 = 15 2πΆ = (6 β 2)! 2! Part b) This is a permutation problem, because the order of choice matters. The first selected gets steak, the second gets chicken. Therefore, 6! 6 = 30 2π = (6 β 2)! Example 1) Shell Oil Company is considering the possibility of opening an oil refinery in Louisiana or in Texas or in both states. The probability of opening a refinery in Louisiana is 0.70 and in Texas it is 0.40. The probability of opening a refinery in either state or in both is 0.80. Find the probability that Shell will open a refinery: a. In both states b. In neither state Solution Define: L β Event Shell opens refinery in Louisiana, T β Event Shell opens refinery in Texas Data: P (L) = 0.7, P(T) = 0.4, and P(LUT) = 0.80 Part a) P (Lβ©T) = P(L) + P(T) β P(LUT) = 0.7+0.4-0.8 = 0.3 Part b) P(LUT)c = 1 β P(LUT) = 1-0.8 =0.2