This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: 11 “mcsftl” — 2010/9/8 — 0:40 — page 313 — #319 Cardinality Rules 11.1 Counting One Thing by Counting Another How do you count the number of people in a crowded room? You could count heads, since for each person there is exactly one head. Alternatively, you could count ears and divide by two. Of course, you might have to adjust the calculation if someone lost an ear in a pirate raid or someone was born with three ears. The point here is that you can often count one thing by counting another , though some fudge factors may be required. This is a central theme of counting, from the easiest problems to the hardest. In more formal terms, every counting problem comes down to determining the size of some set. The size or cardinality of a finite set S is the number of elements in S and it is denoted by j S j . In these terms, we’re claiming that we can often find the size of one set by finding the size of a related set. We’ve already seen a general statement of this idea in the Mapping Rule of Theorem 7.2.1 . Of particular interest here is part 3 of Theorem 7.2.1 , where we state that if there is a bijection between two sets, then the sets have the same size. This important fact is commonly known as the Bijection Rule . 11.1.1 The Bijection Rule Rule 11.1.1 (Bijection Rule) . If there is a bijection f W A ! B between A and B , then j A jDj B j . The Bijection Rule acts as a magnifier of counting ability; if you figure out the size of one set, then you can immediately determine the sizes of many other sets via bijections. For example, consider the two sets mentioned at the beginning of Part III : A D all ways to select a dozen doughnuts when five varieties are available B D all 16bit sequences with exactly 4 ones Let’s consider a particular element of set A : 0 0 0 0 0 0 0 0 0 0 0 0 „ƒ‚… „ƒ‚… „ ƒ‚ … „ƒ‚… „ƒ‚… chocolate lemonfilled sugar glazed plain We’ve depicted each doughnut with a and left a gap between the different vari eties. Thus, the selection above contains two chocolate doughnuts, no lemonfilled, 314 “mcsftl” — 2010/9/8 — 0:40 — page 314 — #320 Chapter 11 Cardinality Rules six sugar, two glazed, and two plain. Now let’s put a 1 into each of the four gaps: 0 0 1 1 0 0 0 0 0 0 1 0 0 1 0 0 „ƒ‚… „ƒ‚… „ ƒ‚ … „ƒ‚… „ƒ‚… chocolate lemonfilled sugar glazed plain We’ve just formed a 16bit number with exactly 4 ones—an element of B ! This example suggests a bijection from set A to set B : map a dozen doughnuts consisting of: c chocolate, l lemonfilled, s sugar, g glazed, and p plain to the sequence: 0:::0 1 0:::0 1 0:::0 1 0:::0 1 0:::0 „ƒ‚… „ƒ‚… „ƒ‚… „ƒ‚… „ƒ‚… c l s g p The resulting sequence always has 16 bits and exactly 4 ones, and thus is an element of B . Moreover, the mapping is a bijection; every such bit sequence is mapped to by exactly one order of a dozen doughnuts. Therefore, j A jDj B j by the...
View
Full Document
 Fall '10
 TomLeighton,Dr.MartenvanDijk
 Computer Science, Product Rule, Quotient Rule, Natural number, Jay, Finite set

Click to edit the document details