# Show bijection from (0,1) to R

I have to show that the following function $f: (0,1) \rightarrow \mathbb{R}$. I will use this function: $f(x)=\frac{1}{x}+\frac{1}{x-1}$.

To show 1-1, I am using $f(x_1)=f(x_2) \Rightarrow x_1=x_2$, where $x_1,x_2 \in (0,1)$.

To start off: $\frac{1}{x_1}+\frac{1}{x_1-1}=\frac{1}{x_2}+\frac{1}{x_2-1}$.

Then, I get: $\frac{(x_1-1)+x_1}{x_1(x_1-1)}=\frac{(x_2-1)+x_2}{x_2(x_2-1)}$.

This leads to: $\frac{2x_1-1}{x_1(x_1-1)}=\frac{2x_2-1}{x_2(x_2-1)}$.

Even after I cross-multiply after this step, I don't see where I can conclude that $x_1=x_2$.

Now,to show surjective, I'm a little confused as well, since rearranging the function to solve for $x$ like in simple cases is not working. Any hints/clues/examples will be appreciated. Thanks!

• If you continue down your current route, you will get quadratics, typically with two apparent solutions of which one will be in $(0,1)$ Nov 18, 2014 at 0:41

Calculus methods as suggested in other answers are good. If you want to do it without calculus, here is a possibility.

Continuing your working leads easily to $$2x_1x_2^2-2x_1^2x_2-x_2^2+x_1^2+x_2-x_1=0\ .$$ Now factorise the LHS. This might sound difficult, but remember that you want to show $x_1=x_2$, so you would hope that $x_1-x_2$ is a factor. And then you should notice that indeed if you take the first two terms, the next two and the last two, $x_1-x_2$ is a factor in every case. So we get $$(x_1-x_2)(-2x_2x_1)+(x_1-x_2)(x_1+x_2)-(x_1-x_2)=0$$ which then becomes $$(x_1-x_2)(-2x_1x_2+x_1+x_2-1)=0\ .$$ To conclude for certain that $x_1=x_2$ you need to explain why the second factor is not zero. Hint. We have $$-2x_1x_2+x_1+x_2-1=-\frac12\bigl((2x_1-1)(2x_2-1)+1\bigr)\ ,$$ and both $x_1$ and $x_2$ are in $(0,1)$.

To prove the function is surjective, try to solve $f(x)=a$ for any given real $a$. This simplifies to $$ax^2-(a+2)x+1=0\ .$$ Now call the LHS $q(x)$ and imagine the graph of $y=q(x)$. This is a continuous curve; since $q(0)=1$ it is above the $x$-axis when $x=0$; since $q(1)=-1$ it is below the axis when $x=1$; so it must cross the axis somewhere between $0$ and $1$, which gives the solution you need.

• The last part uses calculus, doesn't it?
– lhf
Nov 18, 2014 at 1:50
• Is this factoring $(x_1−x_2)(2x_2−2x_1)$ correct? I thought it should be $-2x_1x_2(x_1-x_2)$. Nov 18, 2014 at 1:53
• @HCruz ooops, thanks, fixed. Nov 18, 2014 at 2:35

Well, let us prove that $f(x)=\frac{1}{x}+\frac{1}{x-1}$ is 1-1. Assume that there exist two numbers $x_{1}$ and $x_{2}$ in $(0,1)$ such that $% f(x_{1})=f(x_{2}),$ then $$\frac{2x_{1}-1}{x_{1}^{2}-x_{1}}=\frac{2x_{2}-1}{x_{2}^{2}-x_{2}}$$ and cross-multiplying yields $$(2x_{1}-1)(x_{2}^{2}-x_{2})=(2x_{2}-1)(x_{1}^{2}-x_{1})$$ Expanding both sides, we obtain $$2x_{1}x_{2}^{2}-(2x_{1}x_{2})-x_{2}^{2}+x_{2}=2x_{2}x_{1}^{2}-(2x_{2}x_{1})-x_{1}^{2}+x_{1}$$ canceling term between parentheses, and moving all the others to the left yields $$2x_{1}x_{2}^{2}-x_{2}^{2}+x_{2}-2x_{2}x_{1}^{2}+x_{1}^{2}-x_{1}=0$$ Factoring this expression, we obtain \begin{eqnarray*} 2x_{1}x_{2}(x_{2}-x_{1})-(x_{2}-x_{1})(x_{2}+x_{1})+(x_{2}-x_{1}) &=&0 \\ (x_{2}-x_{1})(2x_{1}x_{2}-(x_{2}+x_{1})+1) &=&0 \end{eqnarray*} So now we have to show that for any $x_{1}$ and $x_{2}$ in $(0,1),$ $(2x_{1}x_{2}-(x_{2}+x_{1})+1)\neq 0$ and then necessarly ($x_{2}-x_{1})=0,$ that is $x_{1}=x_{2}$ which completes the 1-1 proof.

Assume that there exist $x_{1}$ and $x_{2}$ both in $(0,1),$ such that $% (2x_{1}x_{2}-(x_{2}+x_{1})+1)=0,$ and let us prove that there is a contradiction.

Express $x_{2}$ in terms of $x_{1}:$ \begin{eqnarray*} 2x_{1}x_{2}-x_{2}-x_{1}+1 &=&0 \\ 2x_{1}x_{2}-x_{2} &=&1-x_{1} \\ x_{2}(2x_{1}-1) &=&1-x_{1}. \end{eqnarray*} If $x_{1}=\frac{1}{2},$ then $(x_{2})(0)=1-\frac{1}{2}=\frac{1}{2},$ so $0= \frac{1}{2}$ which is impossible. It follows that $x_{1}$ cannot be $\frac{1% }{2}.$ So for some $x_{1}\in \left( 0,\frac{1}{2}\right) \cup (\frac{1}{2},1)$ we have $$x_{2}=\frac{1-x_{1}}{2x_{1}-1}.$$ If $x_{1}\in \left( \frac{1}{2},1\right) ,$ then $1-x_{1}>0$ and $1<2x_{1}<2$ which implies $1-2x_{1}<0.$ So, $x_{2}=\frac{1-x_{1}}{2x_{1}-1}=\frac{\oplus }{\ominus }<0.$ Then $x_{2}\in \left( -\infty ,0\right)$ and do not belong to $(0,1).$ Therefore, we should have $x_{1}\in \left( 0,\frac{1}{2}\right)$ (last chance!)

Assume that $x_1\in \left( 0,\frac{1}{2}\right) ,$ in this case, $0<2x_1<1$ and thus $1-2x_1>0.$ On the other hand $0<x_1<2x_1$, so $-x_1>-2x_1$ and $1-x_{1}>1-2x_{1}.$ And this last number is $>0.$ So, we can divide by $1-2x_{1}$ and get $\frac{1-x_{1}}{1-2x_{1}}>1,$ that is $% -x_{2}=\frac{1-x_{1}}{1-2x_{1}}>1,$ so $x_{2}<-1<0.$ In this case too, $x_{2}$ does not belong to $\left( 0,1\right)$, which is impossible. It follows that if $x_{1}$ and $x_{2}$ are both in $(0,1)$, then it is impossible to have $x_{2}(2x_{1}-1)=1-x_{1}.$

There is another proof: Since the derivative is negative then the function is decreasing strictly, and since the limits at the boundary points (0 and 1) are +infinity and -infinity, then the function f is one-to-one and onto from (0,1) to R.

• Thanks, that makes sense. Is there a name to this type of method? Nov 18, 2014 at 0:16
• this is based on the intermediate values theorem. Nov 18, 2014 at 0:20
• Sorry I do not know a name for this method. But I can precise the method: Look, because it is strictly decreasing on (0,1) then it is one-to-one, (no continuity is requered here) and because it is continuous over (0,1) AND the limits are +infinity and -infinity, then the range of the function is the whole R, so it is onto. Nov 18, 2014 at 0:20
• The intermediate value thm serves for the proof of the ONTO part only, not the 1-1 part. Nov 18, 2014 at 0:22

All you have to show is that, given $a \in \mathbb R$, the equation $f(x) = a$ has exactly one solution for $x \in (0,1)$.

This equation can be rearranged as $ax^2-(a+2)x+1 = 0$.

• If $a = 0$, then it becomes $-2x+1 = 0$, which has the unique root $x=\frac12$ in $(0,1)$.
• If $a \ne 0$, we have a quadratic equation that takes the value $1$ at $x=0$, and the value $-1$ at $x=1$. So again it has exactly one root in $(0,1)$.