1 Permutations and Combinations CS/APMA 202 Rosen section 4.3 Aaron Bloomfield.

Slides:



Advertisements
Similar presentations
5.3 Permutations and Combinations
Advertisements

Permutations and Combinations Rosen 4.3. Permutations A permutation of a set of distinct objects is an ordered arrangement these objects. An ordered arrangement.
Counting Chapter 6 With Question/Answer Animations.
Chapter 13 sec. 3.  Def.  Is an ordering of distinct objects in a straight line. If we select r different objects from a set of n objects and arrange.
Permutations and Combinations
Math 221 Integrated Learning System Week 2, Lecture 1
Counting Techniques: Combinations
Chapter 3b Counting Rules. Permutations  How many ways can 5 students in a class of 30 be assigned to the front row in the seating chart?  There are.
CSE115/ENGR160 Discrete Mathematics 04/17/12
Permutations r-permutation (AKA “ordered r-selection”) An ordered arrangement of r elements of a set of n distinct elements. permutation of a set of n.
Chapter 5 Section 5 Permutations and Combinations.
Chapter 11 Counting Methods © 2008 Pearson Addison-Wesley. All rights reserved.
1 Permutations and Combinations CS/APMA 202 Epp section 6.4 Aaron Bloomfield.
Permutations and Combinations
COUNTING PRINCIPALS, PERMUTATIONS, AND COMBINATIONS.
Permutations and Combinations
WARM-UP 1.Given that P(A)=.35, P(B)=.85, P(AUB)=.8 a)Find P(AB) b)P(A|B) c)P(B|A) 2. Determine if the events A and B are independent.
College Algebra Fifth Edition
Section 4.3: Permutations and Combinations Def: A permutation of a set of distinct objects is an ordered arrangement of these objects. Ex: {a, b, c, d}
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Combinatorics.
1 Permutations and Combinations CS/APMA 202 Rosen section 4.3 Aaron Bloomfield.
1 Permutations and Combinations. 2 In this section, techniques will be introduced for counting the unordered selections of distinct objects and the ordered.
Counting. Why counting  Determine the complexity of algorithms To sort n numbers, how many instructions are executed ?  Count the number of objects.
1 Discrete Structures – CNS2300 Text Discrete Mathematics and Its Applications (5 th Edition) Kenneth H. Rosen Chapter 4 Counting.
Jessie Zhao Course page: 1.
3.8 Counting Techniques: Combinations. If you are dealt a hand in poker (5 cards), does it matter in which order the cards are dealt to you? A  K  J.
1 Melikyan/DM/Fall09 Discrete Mathematics Ch. 6 Counting and Probability Instructor: Hayk Melikyan Today we will review sections 6.4,
Generalized Permutations and Combinations
Chapter 6 With Question/Answer Animations 1. Chapter Summary The Basics of Counting The Pigeonhole Principle Permutations and Combinations Binomial Coefficients.
Permutations and Combinations
10.3 – Using Permutations and Combinations Permutation: The number of ways in which a subset of objects can be selected from a given set of objects, where.
Counting, Permutations, & Combinations. A counting problem asks “how many ways” some event can occur. Ex. 1: How many three-letter codes are there using.
Section 10-3 Using Permutations and Combinations.
2 Permutations and Combinations Lesson 8 HAND OUT REFERENCE SHEET AND GO OVER IT.
Permutations and Combinations
Unit 7 Permutation and Combination IT Disicipline ITD1111 Discrete Mathematics & Statistics STDTLP 1 Unit 7 Permutation and Combination.
Honors Precalculus Counting and Probability Section 12.2: Permutations and Combinations IBTWW: 10/23/2015.
Simple Arrangements & Selections. Combinations & Permutations A permutation of n distinct objects is an arrangement, or ordering, of the n objects. An.
Combinations A combination is an unordered collection of distinct elements. To find a combination, the general formula is: Where n is the number of objects.
2.2 Permutations (Textbook Section 4.6). Recall Factorial Notation  The number of ways to arrange n objects into n spots is n! (read “!” a “factorial”)
Permutations and Combinations Section 2.2 & 2.3 Finite Math.
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,
COUNTING PRINCIPALS, PERMUTATIONS, AND COMBINATIONS.
Counting Principles Multiplication rule Permutations Combinations.
Section 4.5-Counting Rules
6.7 Permutations & Combinations. Factorial: 4! = 4*3*2*1 On calculator: math ==> PRB ==> 4 7! = 5040 Try 12!
1 CS 140 Discrete Mathematics Combinatorics And Review Notes.
I CAN: Use Permutations and Combinations
Permutations and Combinations. 2 In this section, techniques will be introduced for counting the unordered selections of distinct objects and the ordered.
3.2 Combinations.
WARM-UP By yourselves, make a list of 4 things that you would bring on a desert island. Imagine that you could only bring 3 of the 4 things on your list.
5.5 Generalized Permutations and Combinations
Section The Pigeonhole Principle If a flock of 20 pigeons roosts in a set of 19 pigeonholes, one of the pigeonholes must have more than 1 pigeon.
Week 9 - Friday.  What did we talk about last time?  Partial orders  Total orders  Basic probability  Event  Sample space  Monty Hall  Multiplication.
11.1 CompSci 102© Michael Frank Today’s topics CountingCounting –Generalized Pigeonhole Principle –Permutations –Combinations –Binomial Coefficients –Writing.
COUNTING Discrete Math Team KS MATEMATIKA DISKRIT (DISCRETE MATHEMATICS ) 1.
Week 9 - Friday.  What did we talk about last time?  Permutations  Counting elements in sets  Brief introduction to combinations.
Section 6.3. Section Summary Permutations Combinations.
Permutations and Combinations. Permutations Definition –An ordered arrangement of objects is called a permutation. –Hence, a permutation of n distinct.
Chapter 10 Counting Methods.
Permutations and Combinations
CSE15 Discrete Mathematics 04/19/17
Permutations and Combinations
Permutations and Combinations
Counting, Permutations, & Combinations
Counting techniques Basic Counting Principles, Pigeonhole Principle, Permutations and Combinations.
Combinations.
Using Permutations and Combinations
PERMUTATIONS.
10.3 – Using Permutations and Combinations
Presentation transcript:

1 Permutations and Combinations CS/APMA 202 Rosen section 4.3 Aaron Bloomfield

2 Permutations vs. Combinations Both are ways to count the possibilities The difference between them is whether order matters or not Consider a poker hand: A♦, 5♥, 7♣, 10♠, K♠ A♦, 5♥, 7♣, 10♠, K♠ Is that the same hand as: K♠, 10♠, 7♣, 5♥, A♦ K♠, 10♠, 7♣, 5♥, A♦ Does the order the cards are handed out matter? If yes, then we are dealing with permutations If yes, then we are dealing with permutations If no, then we are dealing with combinations If no, then we are dealing with combinations

Factorial: (!) 3 "n" factorial = the product of all counting numbers from "n" down to 1 8! = 8*7*6*5*4*3*2*1 (= 40,320)

4 Permutations A permutation is an ordered arrangement of the elements of some set S Let S = {a, b, c} Let S = {a, b, c} c, b, a is a permutation of S c, b, a is a permutation of S b, c, a is a different permutation of S b, c, a is a different permutation of S An r-permutation is an ordered arrangement of r elements of the set A♦, 5♥, 7♣, 10♠, K♠ is a 5-permutation of the set of cards A♦, 5♥, 7♣, 10♠, K♠ is a 5-permutation of the set of cards The notation for the number of r-permutations: P(n,r) The poker hand is one of P(52,5) permutations The poker hand is one of P(52,5) permutations

5 Permutations Number of poker hands (5 cards): P(52,5) = 52*51*50*49*48 = 311,875,200 P(52,5) = 52*51*50*49*48 = 311,875,200 Number of (initial) blackjack hands (2 cards): P(52,2) = 52*51 = 2,652 P(52,2) = 52*51 = 2,652 r-permutation notation: P(n,r) The poker hand is one of P(52,5) permutations The poker hand is one of P(52,5) permutations

6 r-permutations example How many ways are there for 5 people in this class to give presentations? There are 27 students in the class P(27,5) = 27*26*25*24*23 = 9,687,600 P(27,5) = 27*26*25*24*23 = 9,687,600 Note that the order they go in does matter in this example! Note that the order they go in does matter in this example!

7 Permutations vs. r-permutations r-permutations: Choosing an ordered 5 card hand is P(52,5) When people say “permutations”, they almost always mean r-permutations When people say “permutations”, they almost always mean r-permutations But the name can refer to both Permutations: Choosing an order for all 52 cards is P(52,52) = 52! Thus, P(n,n) = n! Thus, P(n,n) = n!

8 Rosen, section 4.3, question 3 How many permutations of {a, b, c, d, e, f, g} end with a? Note that the set has 7 elements Note that the set has 7 elements The last character must be a The rest can be in any order The rest can be in any order Thus, we want a 6-permutation on the set {b, c, d, e, f, g} P(6,6) = 6! = 720 Why is it not P(7,6)?

9 Combinations What if order doesn’t matter? In poker, the following two hands are equivalent: A♦, 5♥, 7♣, 10♠, K♠ A♦, 5♥, 7♣, 10♠, K♠ K♠, 10♠, 7♣, 5♥, A♦ K♠, 10♠, 7♣, 5♥, A♦ The number of r-combinations of a set with n elements, where n is non-negative and 0≤r≤n is:

10 Combinations example How many different poker hands are there (5 cards)? How many different (initial) blackjack hands are there?

Which situations are a permutation and which are combinations? 11

12