Presentation is loading. Please wait.

Presentation is loading. Please wait.

12 April 2009Instructor: Tasneem Darwish1 University of Palestine Faculty of Applied Engineering and Urban Planning Software Engineering Department Introduction.

Similar presentations


Presentation on theme: "12 April 2009Instructor: Tasneem Darwish1 University of Palestine Faculty of Applied Engineering and Urban Planning Software Engineering Department Introduction."— Presentation transcript:

1 12 April 2009Instructor: Tasneem Darwish1 University of Palestine Faculty of Applied Engineering and Urban Planning Software Engineering Department Introduction to Discrete Mathematics More About Counting Techniques

2 12 April 2009Instructor: Tasneem Darwish2 Outlines The three fundamental principles. Permutations and Combinations. Probability

3 12 April 2009Instructor: Tasneem Darwish3 Theorem 1.1 The Pigeonhole Principle If a set of pigeons is placed into pigeonholes and there are more pigeons than pigeonholes, then some pigeonholes must contain at least two pigeons. Example 1.1 Among any group of 367 people, there must be at least two with the same birthday, because there are only 366 possible birthday. The three fundamental principles

4 12 April 2009Instructor: Tasneem Darwish4 Example 1.3 How many students must be in a class to guarantee that at least two students receive the same score on the final exam, if the exam score is graded on a scale from 0 to 100 points? There are 101 possible scores on the final. The pigeonhole principle shows that among any 102 students there must be at least 2 students with the same score. Example 1.4 What is the minimum number of students required in a discrete mathematics class to be sure that at least six will receive the same grade, if there are five possible grades, A, B, C, D and F? The smallest number is 26, 26= 5*5 +1 The three fundamental principles

5 12 April 2009Instructor: Tasneem Darwish5 Theorem 1.2The Multiplication Principle Consider a procedure that is composed of a sequence of k steps. Suppose that the first step can be preformed in n1 ways, the second step can be performed in n2 ways and each step can be performed in ni ways where i= 1,2,3…..k. Procedure {Step 1 can be performed in n1 ways Step 2 can be performed in n2 ways. Step k can be performed in nk ways} The number of different ways in which the entire procedure can be performed is n1*n2*…..*nk The three fundamental principles

6 12 April 2009Instructor: Tasneem Darwish6 Example 1.5 How many different license plates are available if each plate contains a sequence of three letters followed by three digits? There are 26 choices for each of the three letters and 10 choices for each of the digits. By the product rule there are a total of 26*26*26*10*10*10= possible license plates. The three fundamental principles

7 12 April 2009Instructor: Tasneem Darwish7 Example 1.6 Consider an Id card number of the form (ID: XYZ) Where  X can be any letter except D and F,  Y can be any number except 3 and 5,  and Z can be any of the symbols (µ,α,β,ω), what is the number of the possible Id cards? There are 24 choices for X, eight choices for Y and four choices for Z. hence, the possible number of Id cards is: 24*8*4=768 card. The three fundamental principles

8 12 April 2009Instructor: Tasneem Darwish8 Theorem 1.3 The Addition Principle Suppose that there are k sets of elements with n1 elements in the first set, n2 elements in the second set, etc. if all of the elements are distinct, then the number of elements in the union of the sets is n1+n2+…..+nk Example 1.7 A student can choose a computer project from one of three lists. The three project lists contain 23, 15, 19 possible projects, respectively. How many possible projects are there to choose from?? There are: = 57. The three fundamental principles

9 12 April 2009Instructor: Tasneem Darwish9 Example 1.8 How many 8 bit strings begin with 1011 or 01?  The 8 bit strings that begin with 1011 has the form of 1011_ _ _ _,  The number of eight bit strings that begin with 1011 is equal to the number of ways that the four unknown bits can be chosen.  By the product rule we have 2*2*2*2= 16 ways.  Likewise, the number of 8 bit strings that begin with 01 is 2*2*2*2*2*2= 64.  Since the set of strings beginning with 01 is disjoint from the set of strings beginning with 1011, the addition principle shows that the number of strings beginning with 1011 or 01 is : 16+64=80. The three fundamental principles

10 12 April 2009Instructor: Tasneem Darwish10 Two types of counting problems occur so frequently These problems are: 1) How many arrangements (ordered lists) of r objects can be formed from a set of n distinct objects? 2) How many different selections (unordered lists) of r objects can be made from a set of n distinct objects? Permutations and Combinations

11 12 April 2009Instructor: Tasneem Darwish11 An arrangement of n distinct objects is called a permutation of the objects. If r ≤ n, then an arrangement using r of the n distinct objects is called an r-permutation is a permutation of the digits 1,2,3 and 4, and 412 is a 3-permutation of these digits. The number of different r-permutations of a set of n distinct elements is denoted by P(n,r), this number can be found using the formula: Permutations

12 12 April 2009Instructor: Tasneem Darwish12 Example 2.1 How many different three-digit numbers can be formed using the digits 5,6,7,8 and 9 without repetition? We need to find the number of 3-permutation from a set of 5 digits. This number is P(5,3) Example 2.2 In how many different orders can 4 persons be seated in a row of 4 chairs?? The answer is the number of permutations of a set of 4 elements. Permutations

13 12 April 2009Instructor: Tasneem Darwish13 if r ≤ n, then an unordered selection of r objects chosen from of a set of n distinct objects is called r-combination of the objects. Thus {1,4}and{2,3} are both 2-combinations of the digits 1,2,3 and 4. Note that since the combinations are unordered selections, the 2- combination {1,4} and {4,1} are the same. The number of different r-combinations of a set of n distinct elements is C(n.r): Combination

14 12 April 2009Instructor: Tasneem Darwish14 Example 2.3 How many different 4-member committees can be formed from a delegation of 7 member? Since a 4-member committee is just a selection of 4 members from the delegation of 7, the answer is: Combination

15 12 April 2009Instructor: Tasneem Darwish15 Example 2.4 An investor is going to invest $16000 in four stocks chosen from a list of twelve prepared by her secretary. How many different investments are possible if: (a) $4000 is to be invested in each stock? (b) $6000 is to be invested in one stock, $5000 in another, $3000 in the third, and $2000 in the fourth? (a) Since each stock is to be treated the same, we need an unordered list of four stocks. Hence the number of investments in this case is (b) Since each stock is to be treated differently, we need an ordered list of four stocks. Hence the number of investments in this case is Combination

16 12 April 2009Instructor: Tasneem Darwish16 Probability is the ratio of the number of favourable cases to the total number of cases, assuming that all the various cases are equally possible. An experiment: is any procedure that results in an observable outcome. Thus, we may speak of the experiment of flipping a coin or the experiment of tossing a die. A sample space: is a set containing all the possible outcome of an experiment. An event: is any subset of a sample space. Thus, in the die- tossing experiment with sample space {1, 2, 3, 4, 5, 6}, the following sets are events: A= {1, 2, 4, 6} B= {n: n is an even positive integer less than 7} Probability

17 12 April 2009Instructor: Tasneem Darwish17 The probability of E: where E is any event in a finite sample space S consisting of equally likely outcomes Example 3.1 In the experiment of flipping a probably balanced coin what is the probability of obtaining a head? Since there is only two possible results head (H) or tail (T) The sample space is S= {H, T} The event of obtaining a head E= {H} The probability of obtaining head is Probability

18 12 April 2009Instructor: Tasneem Darwish18 Example 3.2 In the experiment of flipping a probably balanced coin three times, what is the probability of obtaining exactly two heads? The sample space is S= {HHH, HHT, HTH, THH, TTH, THT, HTT, TTT} The event of obtaining exactly two heads E= {HHT, HTH, THH} The probability of obtaining exactly two heads is Probability

19 12 April 2009Instructor: Tasneem Darwish19 Example 3.3 Suppose that there are six applicants for a particular job, four men and two women, who are to be interviewed in a random order. What is the probability that the four men are interviewed before any of the women?  Since the ordering of the interviews is important, the set S of all possible arrangements of the six interviews is P(6,6).  Let E denote the subset of S in which the men are interviewed before women.  The six interviews is going to be a procedure of interviewing the four men and then the two women which can be found out by using the multiplication principle Probability

20 12 April 2009Instructor: Tasneem Darwish20 Example 3.4 Suppose that there are two defective pens in a box of 12 pens. If we choose three pens at random, what is the probability that we do not select a defective pen? In this problem the set of selections of three pens chosen from among the 12 in the box will be our sample space S. The set of all selections of three pens chosen from among the 10 nondefective pens is the event E in which we are interested. Thus, the probability is: Probability

21 12 April 2009Instructor: Tasneem Darwish21


Download ppt "12 April 2009Instructor: Tasneem Darwish1 University of Palestine Faculty of Applied Engineering and Urban Planning Software Engineering Department Introduction."

Similar presentations


Ads by Google