# showing $\mathbb{R}\sim{(0,1)}$

Using the function $f:\mathbb{R}\rightarrow\mathbb{R}$ defined by $$f(x)=\frac{1}{2}\left(1+\frac{x}{1+|x|}\right)$$ Show that $\mathbb{R}\sim(0,1)$

I think this an exercise to show the uncountablility of both sets above, although the chapter I'm reding is on cardinality, so it cleary fits. So I need to show a bijection. so for injection I must show that $$f(x_1)=f(x_2)\Rightarrow{x_1}=x_2$$ So $$\frac{1}{2}\left(1+\frac{x_1}{1+|x_1|}\right)=\frac{1}{2}\left(1+\frac{x_2}{1+|x_2|}\right)$$ $$\frac{x_1}{1+|x_1|}=\frac{x_2}{1+|x_2|}$$ $$x_1(1+|x_2|)=x_2(1+|x_1|)$$ $$x_1+x_1|x_2|=x_2+x_2|x_1|$$ So now the key is to show the equality of this last statement's second second argument, $x_1|x_2|=x_2|x_1|$. SO I was thinking, $$\frac{|x_2|}{x_2}=\frac{|x_1|}{x_1}\Rightarrow{x_1}|x_2|=x_2|x_1|$$ Is this valid? I was thinking it was since $$\frac{|x|}{x}= \begin{cases} -1, & \text{if x\lt0} \\ 1, & \text{if x\gt0} \\ 0, & \text{if x=0} \\ \end{cases}$$

• Why should you have that $\frac{|x_2|}{x_2}=\frac{|x_1|}{x_1}$? – detnvvp Aug 24 '13 at 20:27
• because of the argument underneath it where it's a piecewise defined function. It shouln't matter what the values are since it will always be -1 when $x\lt0$, 1 when $x\gt0$ and defined as 0 when $x=0$. It mad intuitive sense when I formulated the argument... – Irish M Powers Aug 24 '13 at 20:29
• But, if $x_1=1$ and $x_2=-1$, this is not true. You have to show that this is not the case here. – detnvvp Aug 24 '13 at 20:30
• i see where you are guys are going with this. Seeing Peter's answer was enlightening. Thanks very much – Irish M Powers Aug 24 '13 at 20:37
• Alternatively, you could show that the function $g:x\mapsto\dfrac x{1+|x|}$ is anti-symmetric, i.e. $g(-x)=-g(x)$, and strictly increasing on $[0,\infty)$, and then use the fact that anti-symmetric functions are strictly increasing if it's strictly increasing on $[0,\infty).$ – Stefan Hamcke Aug 24 '13 at 20:53

You can distinguish cases. Suppose $x_1,x_2>0$. Then $$x_1+x_1x_2=x_2+x_2x_1$$ gives $x_1=x_2$. The same happens if $x_1,x_2<0$. Now supose $x_1>0,x_2<0$. Then $$x_1-x_1x_2=x_2+x_2x_1$$ $$x_1-x_2=2x_2x_1$$

Note that the left hand side is $>0$, and the right hand side is $<0$, so this cannot happen. Thus $x_2<0<x_1\implies f(x_1)\neq f(x_2)$. Thus, having considered all possible cases we conclude $f$ is one-one.

• Oh, they both yield negative values regardless and by basic algebraic properties they should equal? – Irish M Powers Aug 24 '13 at 20:31
• said in a nonrigorous way :) – Irish M Powers Aug 24 '13 at 20:31
• @IrishMPowers You will always have to consider cases when dealing with the absolute value, since it is a piecewise defined function. – Pedro Tamaroff Aug 24 '13 at 20:39
• What's with the downvote? – Pedro Tamaroff Aug 24 '13 at 20:41
• oh. And now I have that!! I'm new to this myself but my friend isn't so I know of the site features, but I wasn't able to vote but nw I can because I got enough points! – Irish M Powers Aug 24 '13 at 20:52

You can rewrite $f$ as

$$f(x) = \left\{\begin{array}{ll} \frac12 \left(1+\frac{x}{1-x}\right) = \frac12 \frac{1}{1-x} , & x\le0 , \\ \frac12 \left(1+\frac{x}{1+x}\right) = \frac12 \left(2-\frac{1}{1+x}\right) , & x\ge0 . \end{array}\right.$$

Purely elementary considerations can now be used to establish monotonicity of $f$ in both semi-infinite intervals: e.g.,

$$x<x'<0 \Rightarrow -x>-x'>0 \Rightarrow 1-x>1-x'>1 \Rightarrow \frac{1}{1-x}<\frac{1}{1-x'}<1 \Rightarrow f(x)<f(x')<\frac12 .$$

Similarly,

$$0<x<x' \Rightarrow \frac12<f(x)<f(x').$$ That $f$ is strictly increasing over the entire $\mathbb{R}$ now follows form these estimates (including the upper/lower bounds).

• Do not forget the answer you downvoted. A correction has been made. – Mhenni Benghorbal Aug 29 '13 at 6:24
• @ Mhenni - please stay on subject; this is borderline trolling, IMO. Thanks. – automaton 3 Aug 29 '13 at 6:38

This might be simpler.

Suppose that $f(x_1)=f(x_2)$, then $$\frac{x_1}{1+|x_1|}=\frac{x_2}{1+|x_2|}\tag{1}$$ Therefore, since $1+|x_1|\gt0$ and $1+|x_2|\gt0$, $$\mathrm{sgn}(x_1)=\mathrm{sgn}\left(\frac{x_1}{1+|x_1|}\right)=\mathrm{sgn}\left(\frac{x_2}{1+|x_2|}\right)=\mathrm{sgn}(x_2)\tag{2}$$ Furthermore, $$\frac{|x_1|}{1+|x_1|}=\left|\,\frac{x_1}{1+|x_1|}\,\right|=\left|\,\frac{x_2}{1+|x_2|}\,\right|=\frac{|x_2|}{1+|x_2|}\tag{3}$$ Thus, multiplying both sides of $(3)$ by $(1+|x_1|)(1+|x_2|)$, \begin{align} |x_1|(1+|x_2|)&=|x_2|(1+|x_1|)\\[6pt] |x_1|+|x_1||x_2|&=|x_2|+|x_2||x_1|\\[6pt] |x_1|&=|x_2|\tag{4} \end{align} $(2)$ and $(4)$ show that $x_1=x_2$, and therefore, $f$ is injective.

• A similar proof (using $\arg$ instead of $\mathrm{sgn}$) will work to show that $f$ is injective from $\mathbb{C}$ to $\mathbf{B}_{\frac12,\frac12}$. – robjohn Aug 26 '13 at 20:34

First we note that if one of $x_1,x_2$ is zero, them so must be the other one. Elsewhere, writing $|x| = x\, s(x)$ where $s(x)$ is the sign function, we have :

$x_1+x_1|x_2|=x_2+x_2|x_1| \implies x_1-x_2 = x_1 \, x_2 \, [s(x_1)-s(x_2)]$

• If $x_1$ and $x_2$ are both positive (or negative), then $x_1=x_2$.

• If they have opposite signs, the term $[s(x_1)-s(x_2)]$ must have the same sign as $x_1 - x_2$; but $x_1 x_2 < 0$, thus we have a contradiction, and this cannot happen.

Hence $x_1=x_2$