I am trying to prove that: Given an $f:\mathbb{R} \rightarrow \mathbb{R}$, if $f(f(x))=-x$ then $f$ is not continuous?

any help?

Thank you!

  • $\begingroup$ I have found that $f \circ f = f^{-1} \circ f^{-1}$ and that $f^{-1} \circ f (x) = f^{-1} (-x)$. Also tried to check weather this is something about $f$ being odd or even. also found out that $f \circ f \circ f \circ f = id$. nothing helps $\endgroup$
    – user83081
    Nov 29, 2013 at 17:33
  • 1
    $\begingroup$ I suspect that a contradiction is to be found in reasoning about where $f$ is positive, negative, and where it crosses $0$. $\endgroup$ Nov 29, 2013 at 17:36
  • $\begingroup$ See math.stackexchange.com/questions/312385/… $\endgroup$ Dec 11, 2013 at 20:09

2 Answers 2


First, $f$ is a bijection, since otherwise we would have for $x \neq y$, $f(x)=f(y)$ then $-x=f(f(x))=f(f(y))=-y$, contradiction.

Now, a continuous bijection from $\mathbb{R}$ to $\mathbb{R}$ is monotone.

Let's pretend it's increasing, and $x<y$. Then $f(x)<f(y)$, and $f(f(x))<f(f(y))$ thus $-x<-y$ and $x>y$, contradiction.

Thus it must be decreasing, but then, for $x<y$, $f(x)>f(y)$, then $f(f(x))<f(f(y))$, thus $-x<-y$, and $x>y$. Again a contradiction.

Therefore, your function cannot be continuous.

  • 2
    $\begingroup$ +1, but where did you use continuity? $\endgroup$
    – hhsaffar
    Nov 29, 2013 at 17:42
  • $\begingroup$ is there a non-continuous function with this property? $\endgroup$
    – hhsaffar
    Nov 29, 2013 at 17:43
  • 1
    $\begingroup$ Sorry, a continuous bijection from R to R is monotone. Thanks Mark to have corrected, I typed a bit too fast. ;-) $\endgroup$ Nov 29, 2013 at 17:44
  • $\begingroup$ Got it, Thanks a lot!! $\endgroup$
    – user83081
    Nov 29, 2013 at 19:02

The general argument goes like this.

[assertion 1] Given any two functions $\varphi : U \to V, \psi : V \to W$, we know:

  • If $\psi \circ \varphi$ is injective, then $\varphi$ is injective.
  • If $\psi \circ \varphi$ is surjective, then $\psi$ is surjective.

    So for any $f : \mathbb{R} \to \mathbb{R}$ such that $f(f(x)) = -x$, $f \circ f$ bijective implies $f$ bijective.

[assertion 2] If $f$ is continuous and bijective, then it will either be a strictly monotonic increasing or a strictly monotonic decreasing function.

[assertion 3] In both cases, $f\circ f$ will be strictly monotonic increasing.

[conclusion] Since the function $x \mapsto -x$ isn't, $f$ cannot be continuous.

The same argument shows that for any $g : \mathbb{R} \to \mathbb{R}$, if $g \circ g$ is strictly montonic decreasing and bijective, then $g$ cannot be continuous.

Can you convince yourselves why assertions 1, 2, 3 are true?

  • $\begingroup$ The only part that needs some work is [2], but it's rather easy with Intermediate value theorem: suppose $f$ is not monotone nor constant, then there are values $a<b<c$ s.t. $f(a)<f(b)$ and $f(b)>f(c)$ (or the other way around), so with $u=\max(f(a),f(c))$ and $v=f(b)$, any value in $]u,v[$ is the image of (at least) two numbers, $x_1 \in ]a,b[$ and $x_2 \in ]b,c[$, thus it can't be a bijection, contradiction. $\endgroup$ Nov 29, 2013 at 17:52
  • $\begingroup$ Yes, if $\phi$ is not injective, this will contradict $\psi \circ \phi$ injectivness and if if $psi$ is not surjective, this will contradict $\psi \circ \phi$ surjectivness. monotine is indeed from intermidiate theorem, 3 we get from submitting $f$ as $\phi$ or $\psi$. Than you!! $\endgroup$
    – user83081
    Nov 29, 2013 at 19:09

Not the answer you're looking for? Browse other questions tagged or ask your own question.