Existence of a continuous function with pre-image of each point uncountable

Does there exist a continuous function $f : [0, 1] → [0, 1]$ such that the pre-image $f^{−1}(y)$ of any point $y \in [0, 1]$ is uncountable?


Solution 1:

Yes.

One nice way to see that is to take a Peano curve $c: [0,1] \to [0,1]^{2}$ (that is, a continuous surjection) and to compose it with the projection $p(x,y) = x$. Then $f = p \circ c$ will have the desired property.

Added. This is a folklore construction illustrating how far from the graphs we can actually draw (or imagine) a continuous function can be. As mentioned by Jonas in the comments this construction appears in at least two MO threads, namely here and here. I don't know where this example appeared first, I suspect that it can be found in Hausdorff's Mengenlehre, but Peano or Hilbert may have noticed it before that. They're not mentioning it in their original papers, though: Hilbert's paper and Peano's paper, links taken from the Wikipedia page on space-filling curves.