Permutations & Combinations: Selected Exercises. Copyright © Peter Cappello2 Preliminaries Denote the # of arrangements of some k elements of a set of.

Slides:



Advertisements
Similar presentations
9.5 Counting Subsets of a Set: Combinations
Advertisements

Main Menu Main Menu (Click on the topics below) Combinations Example Theorem Click on the picture.
Permutations and Combinations Rosen 4.3. Permutations A permutation of a set of distinct objects is an ordered arrangement these objects. An ordered arrangement.
Recursively Defined Functions
Inclusion-Exclusion Formula
Fall 2002CMSC Discrete Structures1 Permutations How many ways are there to pick a set of 3 people from a group of 6? There are 6 choices for the.
Counting Techniques: Combinations
Counting and Probability The outcome of a random process is sure to occur, but impossible to predict. Examples: fair coin tossing, rolling a pair of dice,
Counting Tools ● Enumeration ● Multiplication ● Addition ● Negation.
CSE115/ENGR160 Discrete Mathematics 04/17/12
Lecture 14: Oct 28 Inclusion-Exclusion Principle.
Copyright © Zeph Grunschlag, Counting Techniques Zeph Grunschlag.
Lecture 5 Counting 4.3, Permutations r-permutation: An ordered arrangement of r elements of a set of n distinct elements. Example: S={1,2,3}:
More Counting Lecture 16: Nov 9 A B …… f. Counting Rule: Bijection If f is a bijection from A to B, then |A| = |B| A B …… f.
Discrete Mathematics Lecture 6 Alexander Bukharovich New York University.
Sequence A list of objects arranged in a particular order.
The Basics of Counting: Selected Exercises. Copyright © Peter Cappello2 Sum Rule Example There are 3 sizes of pink shirts & 7 sizes of blue shirts. How.
Proof Methods & Strategy
1 Permutations and Combinations CS/APMA 202 Epp section 6.4 Aaron Bloomfield.
Permutations and Combinations
Chapter 1 Fundamental principles of counting 陳彥良 中央大學資管系.
Chapter 7 Logic, Sets, and Counting Section 4 Permutations and Combinations.
More Counting Lecture 13 A B …… f. Counting Rule: Bijection If f is a bijection from A to B, then |A| = |B| A B …… f.
More Counting Lecture 16: Nov 9 A B …… f. This Lecture We will study how to define mappings to count. There will be many examples shown. Bijection rule.
Copyright © Cengage Learning. All rights reserved. CHAPTER 9 COUNTING AND PROBABILITY.
1 Permutations and Combinations CS/APMA 202 Rosen section 4.3 Aaron Bloomfield.
Basic Counting Lecture 12: Oct 28. This Lecture We will study some basic rules for counting. Sum rule, product rule, generalized product rule Permutations,
1 Melikyan/DM/Fall09 Discrete Mathematics Ch. 6 Counting and Probability Instructor: Hayk Melikyan Today we will review sections 6.4,
Basic Counting. This Lecture We will study some basic rules for counting. Sum rule, product rule, generalized product rule Permutations, combinations.
Fall 2002CMSC Discrete Structures1 One, two, three, we’re… Counting.
Mathematics. Permutation & Combination - 2 Session.
NO ONE CAN PREDICT TO WHAT HEIGHTS YOU CAN SOAR
2 Permutations and Combinations Lesson 8 HAND OUT REFERENCE SHEET AND GO OVER IT.
Recurrence Relations: Selected Exercises
Inclusion-Exclusion Selected Exercises Powerpoint Presentation taken from Peter Cappello’s webpage
Warm Up 1. Determine whether each situation involves permutations or combinations 2. Solve each problem (set up…if you can simplify…you’re great!) Arrangement.
Chapter 7 Logic, Sets, and Counting Section 4 Permutations and Combinations.
Lecture 5 Counting 4.3, Permutations r-permutation: An ordered arrangement of r elements of a set of n distinct elements. Example: S={1,2,3}:
1 Binomial Coefficients CS 202 Epp, section ??? Aaron Bloomfield.
Simple Arrangements & Selections. Combinations & Permutations A permutation of n distinct objects is an arrangement, or ordering, of the n objects. An.
1 Lecture 4 (part 2) Combinatorics Reading: Epp Chp 6.
Barnett/Ziegler/Byleen Finite Mathematics 11e1 Learning Objectives for Section 7.4 Permutations and Combinations The student will be able to set up and.
The Product Rule: Use & Misuse. Copyright © Peter Cappello The Product Rule If a procedure has 1.A 1 st stage with s 1 outcomes 2.A 2 nd stage with.
The Pigeonhole Principle. The pigeonhole principle Suppose a flock of pigeons fly into a set of pigeonholes to roost If there are more pigeons than pigeonholes,
Discrete Mathematics Lecture # 25 Permutation & Combination.
Discrete Mathematics, 1st Edition Kevin Ferland Chapter 6 Basic Counting 1.
Unit VI Discrete Structures Permutations and Combinations SE (Comp.Engg.)
Binomial Coefficients: Selected Exercises
2/24/20161 One, two, three, we’re… Counting. 2/24/20162 Basic Counting Principles Counting problems are of the following kind: “How many different 8-letter.
Copyright © Peter Cappello 2011 Simple Arrangements & Selections.
COUNTING Permutations and Combinations. 2Barnett/Ziegler/Byleen College Mathematics 12e Learning Objectives for Permutations and Combinations  The student.
Section Basic Counting Principles: The Product Rule The Product Rule: A procedure can be broken down into a sequence of two tasks. There are n 1.
Copyright © Cengage Learning. All rights reserved. Probability and Statistics.
COUNTING Discrete Math Team KS MATEMATIKA DISKRIT (DISCRETE MATHEMATICS ) 1.
Section 6.3. Section Summary Permutations Combinations.
Recurrence Relations: Selected Exercises. Copyright © Peter Cappello2 Exercise 10 (a) A person deposits $1,000 in an account that yields 9% interest compounded.
Permutations and Combinations
CSE15 Discrete Mathematics 04/19/17
COCS DISCRETE STRUCTURES
Generalized Permutations & Combinations: Selected Exercises
Copyright © Cengage Learning. All rights reserved.
Permutations and Combinations
Permutations and Combinations
Permutations and Combinations
CS100: Discrete structures
Chapter 7 Logic, Sets, and Counting
Permutations and Combinations
Basic Counting.
COUNTING AND PROBABILITY
Basic Counting Lecture 9: Nov 5, 6.
Presentation transcript:

Permutations & Combinations: Selected Exercises

Copyright © Peter Cappello2 Preliminaries Denote the # of arrangements of some k elements of a set of n elements as P( n, k ). Use the product rule to derive a formula for P( n, k ). Let C( n, k ) be the # of subsets of k elements drawn from a set of n elements. Use the product rule to derive a formula for C( n, k ) in terms of P( n, k ) & P( k, k ).

Copyright © Peter Cappello3 10 There are 6 different candidates for governor. In how many different orders can the names of the candidates be printed on a ballot?

Copyright © Peter Cappello4 10 Solution The # of different orders that the candidate names can be printed on a ballot is described by the following procedure: 1.Pick the candidate that appears on top (6) 2.Pick the candidate that appears below that (5) 3.Pick the candidate that appears below that (4) 4.Pick the candidate that appears below that (3) 5.Pick the candidate that appears below that (2) 6.Pick the candidate that appears below that (1) The composite number is 6! = = 720. This also is known as P(6,6).

Copyright © Peter Cappello5 20 (a) How many bit strings of length 10 have exactly 3 0s?

Copyright © Peter Cappello6 20 (a) Solution The bit strings have 10 positions: 1, 2, …, 10. A bit string with exactly 3 0s can be described as a 3-subset of the numbers 1, 2, …, 10. These are the bit positions where the 0s go. There are C(10, 3) such 3-subsets. For each such 3-subset, all other positions take 1s. There is 1 way to do that. The answer thus is C(10, 3) = / = 120.

Copyright © Peter Cappello7 20 (b) How many bit strings of length 10 have more 0s than 1s?

Copyright © Peter Cappello8 20 (b) Solution 1 Decompose this problem into disjoint sub-problems; count each sub-problem: 1.6 0s & 4 1s: C(10, 6) = C(10, 4) = / = s & 3 1s: C(10, 7) = C(10, 3) = / 3. 2 = s & 2 1s: C(10, 8) = C(10, 2) = / 2 = s & 1 1: C(10, 9) = C(10, 1) = s & 0 1s : C(10, 10) = C(10, 0) = 1 The answer thus is C(10, 4) + C(10, 3) + C(10, 2) + C(10, 1) + C(10, 0) = = 386.

Copyright © Peter Cappello9 20 (b) Solution 1 Is the following analysis right? 1.Pick the positions of 6 0s: C(10, 6) = C(10, 4) 2.Fill in the other 4 positions: 2 4 C(10, 4) 2 4 = 3,360  386. What is wrong?

Copyright © Peter Cappello10 20 (b) Solution 2 1.There is a 1-to-1 correspondence between strings with more 0s than 1s strings with more 1s than 0s 2.Strategy: 1.C(10, 5) = the # of strings with an equal # of 1s & 0s – C(10, 5) = the # with an unequal # of 1s & 0s. 3.(2 10 – C(10, 5) ) / 2 = the # with more 0s than 1s. C(10, 5) = / = 252 (1024 – 252)/2 = 386.

Copyright © Peter Cappello11 20 (c) How many bit strings of length 10 have ≥ 7 1s?

Copyright © Peter Cappello12 20 (c) Solution Decompose this problem into disjoint sub-problems, and count each sub-problem: 1.7 1s & 3 0s: C(10, 7) = C(10, 3) = / 3. 2 = s & 2 0s : C(10, 8) = C(10, 2) = / 2 = s & 1 0: C(10, 9) = C(10, 1) = s & 0 0s : C(10, 10) = C(10, 0) = 1 The answer thus is C(10, 3) + C(10, 2) + C(10, 1) + C(10, 0) = = 176.

Copyright © Peter Cappello13 20 (d) How many bit strings of length 10 have ≥ 3 1s?

Copyright © Peter Cappello14 20 (d) Solution Decompose this problem into disjoint sub-problems, & count each sub- problem. It is easier to: 1.count the number of 10-bit strings w/o the property 1.0 1s & 10 0s: C(10, 0) = & 9 0s: C(10, 1) = s & 8 0s: C(10, 2) = subtract from the # of 10-bit strings (2 10 ): The answer thus is 2 10 – ( ) = 1024 – 56 = 968.

Copyright © Peter Cappello15 30 (a) There are 7 women & 9 men. How many ways are there to select a committee of 5 members, with at least 1 woman? (In such problems, it is customary & implicit to take individuals as distinct.)

Copyright © Peter Cappello16 30 (a) Consider using the product rule: 1.Pick 1 woman: C(7,1). 2.Pick 4 members from the remaining 6 women & 9 men: C(15,4). Is the answer: C(7,1) C(15,4)? Given a committee of men & women, can you identify the stage at which each woman was chosen?

Copyright © Peter Cappello17 30 (a) Solution Decompose the problem into disjoint sub-problems: 1.The committee has 1 woman: 1.Pick the woman: C(7, 1) = 7 2.Pick the men: C(9, 4) = / = The committee has 2 women: 1.Pick the women: C(7, 2) = 7. 6 / 2 = 21 2.Pick the men: C(9, 3) = / 3. 2 = 84 3.The committee has 3 women: C(7, 3). C(9, 2) = The committee has 4 women: C(7, 4). C(9, 1) = The committee has 5 women: C(7, 5). C(9, 0) = The answer is C(7, 1)C(9, 4) + C(7, 2)C(9, 3) + C(7, 3)C(9, 2) + C(7, 4)C(9, 1) + C(7,5)C(9, 0) = = 4,242.

Copyright © Peter Cappello18 30 (a) More Elegant Solution The set of all committees with 5 members is the universe. Its size is C(7 + 9, 5). Subtract all committees w/o women: C(9, 5). The answer is C(16, 5) – C(9, 5) = 4,368 – 126 = 4,242.

Copyright © Peter Cappello19 30 (b) There are 7 women & 9 men. How many ways are there to select a committee of 5 members, with ≥ 1 woman & ≥ 1 man?

Copyright © Peter Cappello20 30 (b) Solution Subtract “bad” committees from all 5-committees: 1.The # of all 5-committees: C(16, 5) 2.The # of 5-committees w/o women: C(9, 5) 3.The # of 5-committees w/o men: C(7, 5) The answer: C(16, 5) – C(9, 5) – C(7, 5)

Copyright © Peter Cappello21 40 How many ways are there to seat 6 people around a circular table, where 2 seatings, A & B, are equivalent if A is a rotation of B? A B equivalent

Copyright © Peter Cappello22 40 Solution If the people sat in a line the answer is 6! If we drag the line seating into a circle, 6 rotations (permutations) of that “line seating” are equivalent. The answer is 6!/6 = 5! The equivalence relation has 5! equivalence classes, each with 6 elements. Alternatively: 1.Fix person 1 at the head of the table: 1 2.Arrange the other 5 people at the table: 5!

Copyright © Peter Cappello23 Computing C(n,k) How many ways are there to select a team of k players from a set of n players, with a particular player named as captain? 1.Pick the k players: C(n, k) 2.Pick the captain: C(k, 1) = k Equivalently, 1.Pick the captain: C(n, 1) = n 2.Pick the remainder of the team: C(n-1, k-1)

Copyright © Peter Cappello24 Computing C( n, k ) C( n, k )k = n C( n - 1,k - 1 )  C( n, k ) = (n / k) C( n - 1, k - 1 ), for for n ≥ k > 1 Note: n/k may not be an integer. Apply the above recursively: C( n, k ) = n(n - 1)... (n - k +1) / k!, for k ≥ 1. For example, C(1000, 4) = / Why does each factor in the denominator divide some factor in the numerator?