Sei sulla pagina 1di 2

DISCRETE MATHEMATICS AND ITS APPLICATIONS

by Kenneth H. Rosen
Chapter 4 -- Counting
Enumeration, the counting of objects with certain properties, is an important concept involved
in solving a large number of problems. For example, counting is used to determine whether
there are enough telephone numbers, IP addresses, or automobile license plate numbers to meet
demand. It is also used in studying the complexity of algorithms as well as the probability of
events.
Basic Counting Principles
The sum rule: If a first task can be done in n1 ways and a second task in n2 ways, and if only
one of these tasks can be done but not both, then there are n1 + n2 ways to do either task.
Phrased in terms of sets: If a first task is to choose an element from set S and a second task is
to choose an element from set T, and S and T are two disjoint finite sets, then the number of
ways to choose an element from either set is | S T | = | S | + | T |.
The product rule: Suppose that a procedure can be broken down into two tasks. If there are
n1 ways to do the first task and n2 ways to do the second after the first task has been done,
then there are n1n2 ways to complete the procedure. Phrased in terms of sets: If a task to
choose an element from set S is followed by a second task to choose an element from set and
T, where both S and T are finite sets, then the number of ways to choose the pair of elements
is | S T | = | S | | T |.
The inclusion-exclusion principle: Suppose there are two tasks that can be done in n1 and n2
ways, respectively, and the two tasks can be done at the same time in n3 ways. Then the
number of ways to do one of the two tasks is n1 + n2 - n3. Phrased in terms of sets: If a first
task is to choose an element from set S and a second task is to choose an element from set T,
and S and T are two finite sets that may not be disjoint, then the number of ways to choose
an element from either set is | S T | = | S | + | T | - | S T |.

4.2

The Pigeonhole Principle

The pigeonhole principle: If k + 1 or more objects are placed into k boxes, then there is at
least one box containing two or more of the objects.
The generalized pigeonhole principle: If N objects are placed into k boxes, then there is at
least one box containing at least N/k objects.
Exercises in 4.2
4.3

Permutation and Combinations

A permutation of a set of distinct objects is an ordered arrangement of these objects.


An r-permutation is an ordered arrangement of r elements of a set.
The number of r-permutations of a set with n distinct elements is P(n,r) = n (n-1) (n-2)
(n-r+1).
An r-combination of elements of a set is an unordered selection of r elements from the set.
Thus, an r-combination is simply a subset of a set with r elements.
The number of r-combinations of a set with n elements, where n is a positive integer and r an
integer with 0 r n, is C(n, r) = n! / r!(n-r)!
Three well-known identities for r-combinations:
Let n and r be nonnegative integers with r n. Then C(n, r) = C(n, n-r).
Let n and r be positive integers with r n. Then C(n+1,r) = C(n,r-1) + C(n,r). This
identity is known as the Pascal's identity, and is the basis of Pascal's triangle.
Let n be a positive integer. Then r[0,n] C(n, r) = 2n.
The binomial theorem: Let x and y be variables, and let n be a positive integer. Then
(x + y)n = r[0,n] C(n, j) xn-j yj.
Exercises in 4.3

Potrebbero piacerti anche