n21 - CS 70 Fall 2010 Discrete Mathematics and Probability...

• Notes
• 7

This preview shows pages 1–3. Sign up to view the full content.

CS 70 Discrete Mathematics and Probability Theory Fall 2010 Tse/Wagner Note 21 Infinity and Countability Bijections Consider a function (or mapping) f that maps elements of a set A (called the domain of f ) to elements of set B (called the range of f ). For each element x A (“input”), f must specify one element f ( x ) B (“output”). Recall that we write this as f : A B . We say that f is a bijection if every element a A has a unique image b = f ( a ) B , and every element b B has a unique pre-image a A such that f ( a ) = b . f is a one-to-one function (or an injection ) if f maps distinct inputs to distinct outputs. More rigorously, f is one-to-one if the following holds: x , y . x 6 = y f ( x ) 6 = f ( y ) . The next property we are interested in is functions that are onto (or surjective ). A function that is onto essentially “hits” every element in the range (i.e., each element in the range has at least one pre-image). More precisely, a function f is onto if the following holds: y x . f ( x ) = y . Here are some examples to help visualize one-to-one and onto functions: One-to-one Onto Note that according to our definition a function is a bijection iff it is both one-to-one and onto. Cardinality How can we determine whether two sets have the same cardinality (or “size”)? The answer to this question, reassuringly, lies in early grade school memories: by demonstrating a pairing between elements of the two sets. More formally, we need to demonstrate a bijection f between the two sets. The bijection sets up a one-to-one correspondence, or pairing, between elements of the two sets. We know how this works for finite sets. In this lecture, we will see what it tells us about infinite sets. Are there more natural numbers N than there are positive integers Z + ? It is tempting to answer yes, since every positive integer is also a natural number, but the natural numbers have one extra element 0, which is not an element of Z + . Upon more careful observation, though, we see that we can generate a mapping between the natural numbers and the positive integers as follows: CS 70, Fall 2010, Note 21 1

This preview has intentionally blurred sections. Sign up to view the full version.

N 0 1 2 3 4 5 . . . & & & & & & Z + 1 2 3 4 5 6 . . . Why is this mapping a bijection? Clearly, the function f : N Z + is onto because every positive integer is hit. And it is also one-to-one because no two natural numbers have the same image. (The image of n is f ( n ) = n + 1, so if f ( n ) = f ( m ) then we must have n = m .) Since we have shown a bijection between N and Z + , this tells us that there are as many natural numbers as there are positive integers! Informally, we have proved that “ + 1 = .” What about the set of even natural numbers 2 N = { 0 , 2 , 4 , 6 ,... } ? In the previous example the difference was just one element. But in this example, there seem to be twice as many natural numbers as there are even natural numbers. Surely, the cardinality of N must be larger than that of 2 N since N contains all of the odd natural numbers as well. Though it might seem to be a more difficult task, let us attempt to find a bijection between the two sets using the following mapping: N 0 1 2 3 4 5 . . .
This is the end of the preview. Sign up to access the rest of the document.
• Spring '08
• Natural number, Cantor

{[ snackBarMessage ]}

What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern