Prove this function cannot be continuous

105 Views Asked by At

Let $f:[0,1] \to \Bbb R$ such that for every $y$ either there is no $x$ such that $f(x)=y$ or there are exactly two such $x$. We are required to show that $f$ cannot be continuous. I have no idea how to prove this. Also is there a function which satisfies this?

3

There are 3 best solutions below

0
On

Because $f$ can have at most one turning point on $[0,\,1]$, it cannot achieve its supremum twice. But by the extreme value theorem, it achieves it at least once.

0
On

Assume that $f$ is continuous. There are 3 cases:

  • either $f$ is constant on some interval. It is not possible because only 2 x are such that $f(x)=y$
  • or $f$ change direction at least twice. It is not possible because there would be some $y$ for which there are at least 3 x such that $f(x)=y$
  • or $f$ is increasing then decreasing (resp. decreasing then increasing) and the maximum value (resp. minimum) is obtained only for one $x$.

Thus f cannot be continuous.

0
On

EDIT: The following should work if $f$ isn't too "pathological".

Assume such an $f$ exists and is continuous. Then the graph of $f$ is connected. Since $f$ cannot be monotonic (then it would be injective), $f$ must change direction in some point $x_0$. But then $f$ has to change direction at least once more: If not, then $y_0=f(x_0)$ is a global extremum, so there is no other $x \neq x_0$ with $f(x)=y_0$, contradicting the assumptions. So $f$ changes directions in some point $x_1 > x_0$ as well, and there is some $x_2 > x_1$ with $f(x_2)=f(x_0)$. But then for some $y \in (f(x_0), f(x_1))$, the equation $f(x) = y$ will have three solutions $x$, which is a contradiction. So no such continuous $f$ can exist.