Harvard Counting
Harvard Counting
Harvard Counting
Discrete Mathematics
Counting
Discrete Mathematics
Discrete Mathematics
Theorem
Let x and y be variables, and let n be a nonnegative integer. Then:
n
X
n nj j
(x + y ) =
x y
j
j=0
n n
n n1
n
n n
n1
=
x +
x
y + +
xy
+
y .
0
1
n1
n
n
Discrete Mathematics
Corollary
Let n 0 be a nonnegative integer. Then
n
X
n
k=0
= 2n .
Discrete Mathematics
Corollary
Let n 0 be a nonnegative integer. Then
n
X
n
k=0
= 2n .
n
(1)
= 0.
k
Discrete Mathematics
Discrete Mathematics
Discrete Mathematics
Discrete Mathematics
Theorem
Let n and r be nonnegative integers with r n. Then
X
n
n+1
j
=
.
r +1
r
j=r
Discrete Mathematics
Discrete Mathematics
Theorem
The number of r -permutations of a set of n objects with repetition
allowed is nr .
Discrete Mathematics
Theorem
The number of r -permutations of a set of n objects with repetition
allowed is nr .
Theorem
There are C (n + r 1, r ) = C (n + r 1, n 1) r -combinations
from a set with n elements when repetition of elements is allowed.
Discrete Mathematics
Example
How many solutions does the equation
x1 + x2 + x3 = 11
have, where x1 , x2 , and x3 are nonnegative integers?
Discrete Mathematics
Summary
Type
r -permutations
r -combinations
r -permutations
r -combinations
Repetition allowed?
No
No
Yes
Yes
Discrete Mathematics
Formula
n!
(nr )! ,
n!
r !(nr )! ,
nr ,
(n+r 1)!
r !(n1)! .
Theorem
The number of different permutations of n objects, where there are
n1 indistinguishable objects of type 1, n2 indistinguishable objects
of type 2, . . . , and nk indistinguishable objects of type k, is given
by
n!
.
n1 !n2 ! nk !
Discrete Mathematics
Discrete Mathematics
Discrete Mathematics
Discrete Mathematics
Discrete Mathematics
j1
k
X
1X
i j
S(n, j) =
(1)
(j i)n .
j!
i
j=1
i=0
Discrete Mathematics
Discrete Mathematics