This preview shows pages 1–16. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: CS70: Satish Rao: Lecture 16. 1. Review. 2. Stars/Bars. 3. Balls in Bins. 4. Combinatorial Proofs. 5. Inclusion/Exclusion First rule: n 1 × n 2 ···× n 3 . Product Rule. First rule: n 1 × n 2 ···× n 3 . Product Rule. k Samples with replacement from n items: n k . First rule: n 1 × n 2 ···× n 3 . Product Rule. k Samples with replacement from n items: n k . Sample without replacement: n ! ( n k )! First rule: n 1 × n 2 ···× n 3 . Product Rule. k Samples with replacement from n items: n k . Sample without replacement: n ! ( n k )! Second rule: when order doesn’t matter divide..when possible. First rule: n 1 × n 2 ···× n 3 . Product Rule. k Samples with replacement from n items: n k . Sample without replacement: n ! ( n k )! Second rule: when order doesn’t matter divide..when possible. Sample without replacement and order doesn’t matter: ( n k ) = n ! ( n k )! k ! . “ n choose k ” Stars and bars.... How many ways can Bob and Alice split 5 dollars? Stars and bars.... How many ways can Bob and Alice split 5 dollars? For each of 5 dollars pick Bob or Alice(2 5 ), divide out order Stars and bars.... How many ways can Bob and Alice split 5 dollars? For each of 5 dollars pick Bob or Alice(2 5 ), divide out order ??? Stars and bars.... How many ways can Bob and Alice split 5 dollars? For each of 5 dollars pick Bob or Alice(2 5 ), divide out order ??? 5 dollars for Bob and 0 for Alice: Stars and bars.... How many ways can Bob and Alice split 5 dollars? For each of 5 dollars pick Bob or Alice(2 5 ), divide out order ??? 5 dollars for Bob and 0 for Alice: one unordered set: ( B , B , B , B , B ). Stars and bars.... How many ways can Bob and Alice split 5 dollars? For each of 5 dollars pick Bob or Alice(2 5 ), divide out order ??? 5 dollars for Bob and 0 for Alice: one unordered set: ( B , B , B , B , B ). 4 for Bob and 1 for Alice: Stars and bars.... How many ways can Bob and Alice split 5 dollars? For each of 5 dollars pick Bob or Alice(2 5 ), divide out order ??? 5 dollars for Bob and 0 for Alice: one unordered set: ( B , B , B , B , B ). 4 for Bob and 1 for Alice: 5 unordered sets: ( A , B , B , B , B ) ; ( B , A , B , B , B ); ... Stars and bars.... How many ways can Bob and Alice split 5 dollars? For each of 5 dollars pick Bob or Alice(2 5 ), divide out order ??? 5 dollars for Bob and 0 for Alice: one unordered set: ( B , B , B , B , B ). 4 for Bob and 1 for Alice: 5 unordered sets: ( A , B , B , B , B ) ; ( B , A , B , B , B ); ... Single way to specify, first Alice’s dollars, then Bob’s. ( B , B , B , B , B ) ( A , B , B , B , B ) ( A , A , B , B , B ) and so on. Stars and bars.... How many ways can Bob and Alice split 5 dollars?...
View
Full
Document
This note was uploaded on 02/29/2012 for the course COMPSCI 70 taught by Professor Rau during the Fall '11 term at University of California, Berkeley.
 Fall '11
 Rau

Click to edit the document details