The Product Rule: Use & Misuse The Product Rule If a procedure has 1. A 1st stage with s1 outcomes 2. A 2nd stage with s2 outcomes and the composite outcomes are distinct then The procedure has s1 x s2 composite outcomes. Copyright © Peter Cappello 2011 2 Visualizing the Procedure – The procedure for constructing a composite outcome requires a selection at each stage. – Visualize all invocations of the procedure as a tree. • Each level in the tree corresponds to a stage. • Each leaf in the tree corresponds to a composite outcome: Each leaf must be distinct. Copyright © Peter Cappello 2011 3 Example 1 Let B = { 0, 1 } and V = { a, e, i, o, u }. How many 1-to-1 functions, f, are there from B to V? Solution: 1. Select the vowel for f( 0 ) (5 choices). 2. Select the vowel for f( 1 ) (4 choices). Thus, there are 5x4 1-to-1 functions from B to V. Copyright © Peter Cappello 2011 4 Example 1 continued Visualize the selection process as a tree. 1. Pick f(0) a e i o u 2. Pick f(1) (a,e) (e,a) (i,a) Copyright © Peter Cappello 2011 (o,a) (u,a) (u,o) 5 Misuse of the Product Rule The set of 5 vowels has how many subsets of 2 letters? Erroneous solution: 1. Pick the 1st letter (5 choices). 2. Pick the 2nd letter (4 choices). There are 5 x 4 subsets of 2 letters. Not! – Visualize the selection process above as a tree. – The composite outcomes are not distinct. • Each leaf appears twice (e.g., ae, ea) • The same set of 2 vowels is counted twice. To use the product rule properly, it is necessary that: Each component of the composite outcome is associated with 1 stage of the selection process. If it cannot be so associated, the product rule is used incorrectly. Copyright © Peter Cappello 2011 6 Subset Example continued Visualize the selection process as a tree. 1. Pick “1st” vowel a e i o u 2. Pick “2nd” {a,e} {e,a} {i,a} Copyright © Peter Cappello 2011 {o,a} {u,a} {u,o} 7 Proper Use of the Sum Rule • The subsets are pairwise disjoint. • The union of the subsets includes every element that you want to count. Sound familiar? Copyright © Peter Cappello 2011 8 Proper Use of the Sum Rule Let S1, S2, …, Sn be subsets of S. |S| = |S1| + |S2| + …+ |Sn | S1, S2, …, Sn partition S. Copyright © Peter Cappello 2013 9