# lect_29 - Counting II Margaret M. Fleck 9 April 2010 This...

This preview shows pages 1–3. Sign up to view the full content.

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Counting II Margaret M. Fleck 9 April 2010 This lecture covers more examples of permutations and combinations, from section 5.3 of Rosen plus part of section 5.4. It also introduces combi- natorial proofs. 1 Recap: basic counting methods Last class, we covered several basic counting rules. The product rule : if you have p choices for one part of a task, then q choices for a second part, and your options for the second part dont depend on what you chose for the first part, then you have pq options for the whole task. The sum rule : suppose your task can be done in one of two ways, which are mutually exclusive. If the first way has p choices and the second way has q choices, then you have p + q choices for how to do the task. Inclusion-exclusion principle : if the two sets of choices do overlap, you have to subtract the overlap amount so you dont double-count those options. Permutations : if S is a set of n objects (all different), then a k-permutation of S is a way to put k of the objects from S into an ordered list. There are P ( n, k ) = n ( n 1) . . . ( n k + 1) = n ! ( n- k )! different k-permutations. For example, suppose I own ten differently-decorated coffee mugs but I only want to put six of them out on the table. Then I have 10 choices for 1 which to put at the first place, 9 for what to put at the second, and so on down to 5 choices for the last mug to put out. That is, P (10 , 6) = 10! 4! . Notice that these formulas only work if all items in the set are distin- guishable and we dont get to pick duplicates of the same item. When those assumptions fail, we have to restructure the problem or use a more complex formula. 2 Combinations The permutations formula applies when we care about the order in which we are selecting the objects, e.g. we are putting them into an arrangement or choosing them for a series of different roles. If we simply want to select a subset of the objects, we need a different formula. An unordered set of k elements is called a k-combination. Example: How many ways can I select a 7-card hand from a 60-card deck of Magic cards (assuming no two cards are identical)? 1 One way to analyze this problem is to figure out how many ways we can select an ordered list of 7 cards, which is P (60 , 7). This over-counts the number of possibilities, so we have to divide by the number of different orders in which the same 7-cards might appear. Thats just 7!. So our total number of hands is P (60 , 7) 7!...
View Full Document

## This note was uploaded on 12/24/2010 for the course CS CS 173 taught by Professor Fleck during the Spring '10 term at University of Illinois, Urbana Champaign.

### Page1 / 7

lect_29 - Counting II Margaret M. Fleck 9 April 2010 This...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online