Lec 07 Counting2
Lec 07 Counting2
LECTURE 7: COUNTING-2
Rosen 5th ed., §4.4 - 4.6
BINOMIAL COEFFICIENTS
(a + b)2 = a2 + 2ab + b2
(a + b)3 = a3 + 3ab2 + 3a2b + b3
(a + b)4 = a4 + 4ab3 + 6a2b2 + 4a3b + b4
Why am I showing
this to you? 1. Beautiful patterns
2. Recursive defn
3. New type of proof
4. Applications in more
complex counting
techniques
2
BINOMIAL COEFFICIENTS
(a + b)2 = a2 + 2ab + b2
(a + b)3 = a3 + 3a2b + 3ab2 + b3
(a + b)4 = a4 + 4a3b + 6a2b2 + 4ab3 + b4
What is coefficient
of a9b3 in (a + b)12?
A. 36
B. 220
C. 15
D. 6
E. No clue 3
BINOMIAL COEFFICIENTS
æn ö n
(x + y ) = åç ÷x y
n n- j j
j
j =0 è ø
4
BINOMIAL COEFFICIENTS
æn ö n - j j
n
(x + y ) = åç ÷x y
n
j
j =0 è ø
What is n? 17
æ17ö æ17ö 8 9 8 9
What is j? 9 ç ÷(3a) (2b) = ç ÷3 2 a b
8 9
è9ø è9ø
What is x? 3a 5
What is y? 2b
BINOMIAL COEFFICIENTS
A. 10C6
B. 9C4
C. 9C5
D. 8C4 + 8C5
E. No clue
6
næn ö n - j j
BINOMIAL COEFFICIENTS (x + y ) = åç ÷x y
n
j
j =0 è ø
n æn ö n - j j
åç j ÷1 1 = (1 + 1)n
j =0 è ø
næn ö n
åç j ÷ = 2 8
j =0 è ø
PASCAL’S IDENTITY
n-1Cj
9
This is an
VANDERMONDE’S IDENTITY example of a
combinatorial
proof. We
describe the
Let m, n, and r be nonnegative integers with r notset counted by
exceeding either m or n. Then the LHS and
RHS of the eqn,
and argue that
æm+ nö r æ m öænö they count the
ç ÷ = åç ÷ç ÷ same thing.
è r ø j=0 èr - jøè jø Look in Rosen.
A B
m items n items To choose r items,
take some from A
and some from B.
All possible ways
of doing this gives
the result. 10
COMBINATIONS WITH REPETITION
Out of 7 items, we
are choosing 2 to
be bars.
From that, and our
understanding of
the model, we can
report the answer.
æ 7ö æ 7ö 11
ç ÷=ç ÷
è 2 ø è5 ø
COMBINATIONS WITH REPETITION
x1 + x 2 + x 3 + x 4 = 10
When the variables are nonnegative integers?
13C3
12
1 + 3 + 6 + 0 = 10
PERMUTATIONS WITH INDISTINGUISHABLE
OBJECTS
13
PERMUTATIONS WITH INDISTINGUISHABLE
OBJECTS
æ 8 öæ 4öæ2ö 8! 4! 2! 8!
ç ÷ç ÷ç ÷ = × × =
è 4 øè 2øè2ø 4!4! 2!2! 2!0! 4!2!2!
14
PERMUTATIONS WITH INDISTINGUISHABLE
OBJECTS
Hint: how can you combine your soln for the CS books with
your soln for the Psych books?
18
A LITTLE PRACTICE
|A| = 18!/(3!5!6!4!) 19
¢ P.324 5, 15, 21.b, 31,
¢ P.342 3, 5, 7, 15, 31,
20