# Show that function is injective and surjective using given condition on $f$

Consider $$f$$ a continuous function from $$\mathbb{R}$$ to $$\mathbb{R}$$

It is given that $$|f(x)-f(y)|\geq \frac{1}{2}|x-y|\tag{1}$$ for all $$x,y$$ in $$\mathbb{R}$$

I want to show that $$f$$ is one-one and onto

My efforts

Injectivity

Suppose $$a,b\in \mathbb{R}\text{ and } a\neq b$$ such that $$f(a)=f(b).$$

Then consider the following fraction $$\frac{f(b)-f(a)}{b-a}$$ which is equal to zero as $$f(b)=f(a)$$ and $$b\neq a$$

But that is a contradiction as given condition on $$f$$ says that $$|f(b)-f(a)|\geq \frac{1}{2}|b-a|$$ and that would actually show that $$0\geq \frac{1}{2}|b-a|$$ and right hand side is strictly greater than zero.

Therefore function is one one.

Surjectivity

Let $$x_0\in \mathbb{R}$$ be any arbitrary point and WLOG assume $$x_0\geq 0$$.

If I put $$y=0$$ condition (1) says $$f(x)\geq \frac{1}{2}x+f(0)$$ if $$x\geq 0$$ (also using the fact that WLOG that function is increasing).

Take $$x=2x_0$$,

we have $$f(2x_0)\geq x_0 +f(0)$$

Take $$x=-2x_0$$ and then we have $$f(-2x_0)\leq x_0-f(0)$$

So we have $$f(-2x_0)\leq x_0-f(0)\leq x_0\leq x_0+f(0)\leq f(2x_0)$$

Now Intermediate Value theorem works like a magic and we are done!!!!

Am I correct?

Edit: If people are confused, why I can assume that function is increasing in surjectivity part, here is the answer A continuous, injective function $$f:\mathbb{R}\rightarrow \mathbb{R}$$ is either strictly increasing or strictly decreasing.

• logic is impeccable – James Sep 29 '18 at 1:34
• Injectivity should be simpler: $f(a)=f(b)$ implies $0=|f(a) - f(b)| \geq \frac{1}{2}|a-b|$ forces $a=b$. – Randall Sep 29 '18 at 2:21
• I think I have used the same logic but in a slightly different way. @Randall – StammeringMathematician Sep 29 '18 at 2:22
• I agree: it's pretty close. – Randall Sep 29 '18 at 2:23