Real Analysis – Bijection from (0,1) to [0,1)

functionsreal-analysis

I'm trying to solve the following question:

Let $f:(0,1)\to [0,1)$ and $g:[0,1)\to (0,1)$ be maps defined as

$f(x)=x$ and $g(x)=\frac{x+1}{2}$. Use these maps to build a bijection
$h:(0,1)\to [0,1)$

I've already proved that these maps are injectives, and following the others questions on the site such as

Continuous bijection from $(0,1)$ to $[0,1]$

How to define a bijection between $(0,1)$ and $(0,1]$?

I think I can found such $h$, but the problem is that we have to use only $f$ and $g$ to build $h$.

I need help.

Thanks a lot.

Best Answer

If $x$ has shape $1-\frac{1}{2^n}$, where $n$ is a non-negative integer, let $H(x)=g(x)$. Otherwise, let $H(x)=f(x)$.

This gives a bijection in the "wrong" direction. Take the inverse.