In this writeup, I hope to give an intuitive introduction to some important topological concepts. The central question we will answer is the following: what differentiates a circle from a line?

We will discover that this problem reduces to the following: why is it impossible to define a continuous, bijective function from a circle to a line?

Recall that “bijective” essentially means that we must “pair up” points on the circle and line such that each point belongs to exactly one pair.

To get a sense for why this task is impossible, feel free to try some examples! For instance, if we define the following function between the circle and the interval [0,2𝜋) where every point on the circle is mapped to its angle in radians:

The section highlighted in red is discontinuous because it jumps from 2𝜋 to 0 i.e. it jumps from the tail of the line to its head.

Exercise

Note that the bijective condition is important. What are some simple continuous, non-bijective functions from a circle to a line?

You’ll see that the problem essentially becomes the following:

How can I prove that it’s impossible to “continuously deform” a circle into a line?

We’ll make this notion of continuous deformation rigorous later with the idea of a homeomorphism, but we need to define continuity first!


As an aside, you may be used to visualizing functions like this:

A typical illustration of the function 𝑓(𝑥)=𝑥2.

However, when considering functions in topology, it’s often more helpful to draw the input and output spaces separately, like so:

How I prefer to visualize 𝑓(𝑥)=𝑥2. You can also illustrate the input and output spaces in more creative ways to highlight certain relationships: for instance, by bending the input line at 0, we highlight the symmetry between 𝑥 and 𝑥.

Now, we can move on to give a more proper definition of what it means for a function to be continuous.

Continuity and open sets

If we have a continuous function 𝑓:𝑀𝑁 and both 𝑀 and 𝑁 are metric spaces, we have the following notion of continuity:

For all 𝑥𝑀, if we allow 𝑓(𝑥) to vary a little in all directions, 𝑥 should be allowed to vary a little in all directions as well.

For instance, taking 𝑓(𝑥)=𝑥2 and 𝑥=2:

If we allow 𝑓(𝑥)=4 to either increase a little or decrease a little, the input 𝑥=2 should be allowed to increase or decrease a little as well.

Now, consider the discontinuous function 𝑓(𝑥)=𝑥.

For the input-output pair (0,0), varying the output around 0 only allows the input to vary around 0 in one direction. Therefore, the floor function is discontinuous.

We now introduce the notion of an open set as a set of points such that each point within the set can vary a little in all directions while still staying in the set. For instance, the interval (0,1) on the real line is an open set, but [0,1) and [0,1] are not.

Then, we can rewrite our continuity condition as the following:

If 𝑓:𝑀𝑁 is continuous, the pre-image of any open set in 𝑁 under 𝑓 must be an open set in 𝑀.

Recall that the pre-image of a set 𝑆 in the output space is the set of input points that map to some element in 𝑆. For instance, taking 𝑓(𝑥)=𝑥2, the pre-image of (0,1)(4,9) is (3,2)(1,0)(0,1)(2,3). Both sets are open, so this satisfies our continuity condition.

A fun way I like to think about this condition:

If we specify an output space where every point has some “room to breathe”, every point in the input space must have some “room to breathe” as well.

Exercise

Prove that this is equivalent to the epsilon-delta definition of continuity.

Exercise

Why can’t we instead define a continuous function as a function that maps open sets to open sets? To see why not, find a function (or multiple) that is really continuous, but wouldn’t be under this modified definition.

For some more fun, also find a function that is continuous under this definition but really isn’t. You may have to get a bit creative with choosing input and output spaces!

Discarding the metric

Importantly, note that our new definition of continuity depends only on the open sets in each metric space, not the underlying distances. Therefore, instead of defining a topological space as (𝑋,𝑑), we define it as (𝑋,𝜏), where 𝜏 is the set of open sets on 𝑋. Note that and 𝑋 must both be open by definition. Additionally, we can show that open sets must satisfy two additional properties:

  1. The union of several (potentially infinite) open sets is still an open set.
  2. The intersection of finitely many open sets is also an open set.

Exercise

Can you find an infinite collection of open sets on whose intersection is {0}, and therefore not an open set?

A fun topological space to think about is the discrete space, in which every subset of 𝑋 is an open set.

Exercise

Can you construct a metric consistent with this topological space?

Homeomorphisms

With this definition of topological spaces, we can now speak about one of the most important concepts in topology: homeomorphisms. An intuitive definition of homeomorphism:

Two topological spaces are homeomorphic if they can be “continuously deformed” into one another.

Some classic examples: a circle is homeomorphic to a square, the real line is homeomorphic to (0,1), and a coffee mug is homeomorphic to a donut. Here’s a fun visual from Wikipedia: 500

More rigorously:

Two topological spaces 𝑋 and 𝑌 are homeomorphic if there exists a continuous bijection between them.

Exercise

Using this definition, how can we show that the real line is homeomorphic to (0,1)?

Finally, using our open set definition of continuity, we can say:

Two topological spaces are homeomorphic iff there exists a bijection between their open sets.

Compactness

Compactness is a way to capture some aspects of finiteness when dealing with continuous spaces. For instance, a finite set of real numbers always has a maximum; this is not true for an infinite set. Similarly, a continuous function from a compact space to always has a maximum; this is not true in general.

A prototypical example of this is the fact that [0,1] is compact, while (0,1) is not.

Exercise

Find a function on (0,1) that has no maximum.