Metric Spaces, Cantor Set

Cantor Set

The cantor set C is a subset of the unit interval, with the subspace topology. Delete (1/3,2/3), then (1/9,2/9) and (7/9,8/9), and so on, removing the middle third of segments forever.

Notice that the section of C from 0 to 1/3, when magnified, looks exactly like C. This is an early example of a fractal, although fractal geometry was not known at the time. Cantor simply thought it was a beautiful set, and indeed it is.

If x is in the complement of C, then it was removed at some point, as part of an open interval. The complement is open, and C is closed.

Being a closed subspace of [0,1], C is compact.

Since C is a closed subspace of a complete metric space, it too is a complete metric space.

Let s be a sequence of zeros and ones. If s1 = 0, select the interval [0,1/3]. If s1 = 1, select the interval [2/3,1]. If s2 = 0, select the first third of the interval previously selected, and if s2 = 1, select the last third of the interval previously selected. This continues forever, building a chain of descending closed intervals whose lengths approach 0. This chain always converges to a point, which we will call x. Furthermore, x does not lie in the middle third of any segment, hence x has never been deleted, and x belongs to C. We have a map from binary sequences into C.

Different sequences will diverge at some point, living in disjoint intervals thereafter. Thus the map is 1-1.

Finally, let x be a point in the cantor set C. At each step, x lies in the first or last third of the prior interval. If it were in the middle third it would not lie in C. Thus, at each step, sn can be set to 0 or 1. The resulting sequence converges to some y in C, and if y is not equal to x, then sn goes down the wrong path at some point, moving towards y instead of x. This contradicts the construction of s, hence s defines x. The map is onto, and the points of C correspond 1-1 with the infinite binary sequences, which are sometimes written 2ω.

As a corollary, the points of C are uncountable.

The binary sequences can be given an order topology. This is based on lexicographic order, where 10101… is greater than 10100…, and so on. Verify that the map from sequences into C respects order. Thus 2ω and C are homeomorphic.

Now that we have a topology, the infinite binary sequences are called the cantor space. This is homeomorphic to the cantor set embedded in the reals.

Sequences of Nonnegative Integers

It's a bit off topic, but a similar construction shows ωω is homeomorphic to the nonnegative reals. You can skip this if you wish.

Let s be a sequence of nonnegative integers. If s1 = n then restrict attention to the interval [n,n+1). If the next integer s2 = 0, select, from the prior interval, the range [0,1/2). If s2 = 1 then select [1/2,3/4). If s2 = 2 select [3/4,7/8), and so on. with this interval established, move to s3, and select a slice of this interval in exactly the same way. Continue this process forever, homing in on x. Technically, each step establishes a half open interval, but you can think of them as closed intervals, giving a descending chain of closed intervals that converges to a point. As before, this point has to be x. The map is 1-1 and onto, and it respects order - lexicographic order in the infinite sequences and linear order in the reals. The two spaces are homeomorphic.

Onto the Reals

Most binary sequences in the cantor space are limit points, with points approaching from below and above. However, a sequence that ends in all zeros has a predecessor, and a sequence that ends in all ones has a successor. In other words, 101011111… is just below 101100000…, with nothing in between. This reflects the fact that C is highly disconnected, fragmenting into an infinite number of components. The ultimate in swiss cheese. In contrast, the closed interval [0,1] is connected. Still, we can map C onto [0,1] by reading each binary sequence as a real number in base 2. This preserves order, and squashes predecessor and successor together wherever they appear. In the above example, both binary sequences map to 11/16. The holes have been squeezed out of the swiss cheese. So the map is not a homeomorphism, but it is continuous, and onto.

Product of Cantor Sets

Oddly enough, the topological product of C cross C is homeomorphic to C. Let's build a map from the latter into the former.

Given a sequence of zeros and ones, extract the bits in the odd positions and call that x, then extract the bits in the even positions and call that y. The ordered pair x,y becomes a point in C cross C.

Take a moment to show this map is injective and surjective.

Since C is hausdorff, C cross C is also hausdorff. Thus the domain is compact and the range is hausdorff. If we can prove continuity, we have demonstrated the homeomorphism.

Select a point a,b in the range, with w as preimage in the domain, and restrict to ε. Ratchet ε down to 2-m. If x and a start with the same m bits, and similarly for b and y, then we are within ε of our target.

Assume there is a 01, or a 10, in position k in w, where k > 2m. Set δ = 2-k-1, and the first 2m bits are preserved from w-δ to w+δ. The first m bits of x and y are preserved, and continuity is assured.

Assume all the bits beyond 2m are zeros. Setl δ = 2-m-1. The open interval in the preimage is bounded by w+δ above, and by the predecessor of w below. Remember that w has a predecessor, as shown earlier. Sure enough, our open set preserves the first 2m bits, and maps into the target area. A similar result holds when the sequence ends in all ones. Therefore, the map is continuous, and a homeomorphism.

The cantor space is "idempotent"; C*C = C. The only finite idempotent space is a single point. The study of idempotent spaces is interesting, but beyond the scope of this article.

This result extends, by induction or direct construction, to a finite product of cantor sets. In other words, Cn = C.