Measurability of a specific binary function

here is my question: let $x$ denote its binary representation, $x = 0,a_1(x)a_2(x)a_3(x)\dots$ with $a_n(x) \in \{0,1\}$ such that $x = \sum_{n=1}^\infty\frac{a_n(x)}{2^n}$. Define the function $$f := 0,a_2(x)a_1(x)a_4(x)a_3(x)a_6(x)a_5(x)\dots.$$ Here we denote the Borel-$\sigma$-algebra on $[0,1]$. Show $f$ is measurable.

I cannot find a straight foreward proof. I suspect that any interval with boundaries that have a finite binary representation (that is, after a finite ammount of ones and zeros there only are zeros left), is mapped onto countably many other intervals of the same kind, which should imply measurability. Is this suspicion correct? If so, what would be the next step? If not, I would be very happy with just a hint in the right direction.

The measurability is closed by many operations. It's usually more convenient to use these properties instead of the definition. First let's formalize a bit what $a_i$ is.

$$b_0(x)=x$$

$$a_i(x)=\lfloor 2b_{i-1}(x) \rfloor$$ $$b_i(x)=2b_{i-1}(x)-a_i(x)$$

This is well-defined (if you have already computed $a_{i-1}$ and $b_{i-1}$, first compute $a_i$, and then $b_i$). If you want to get an intuition: if $x=0.01011101001111$, then:

$$b_0=0.01011101001111$$ $$2b_0=0.1011101001111$$ $$a_1=0$$ $$b_1=0.1011101001111$$ $$2b_1=1.011101001111$$ $$a_2=1$$ $$b_2=0.011101001111$$ $$2b_2=0.11101001111$$ $$a_3=0$$ $$b_3=0.11101001111$$

...

Moreover, you can prove by induction that $a_i$ and $b_i$ are measurable (using the measurability of the floor function). Then:

$$f=\sum_{k=1}^\infty \frac{c_k}{2^k}$$

where $c_k=a_{k+1}$ if $k$ is odd and $c_k=a_{k-1}$ otherwise. $f$ is measurable because all $c_k$ are measurable (and measurability is closed by sum and $\limsup$).

• Thank you for your answer! I am not (too) familiar with working with binary expressions, could you elaborate a bit on your definition of $b_i(x)$ and explain why that what you descibed is not a circular definition? and why do we need this to construct $f$ in your way? – Lou95 Feb 5 '17 at 13:28
• @Lou95: I added a small example. I recommend you to look at some tutorial about decimal representation on the Web (or more generally base $b$ representation). Actually this is the more natural way to define $f$ formally, ie. this is what the notation $f=0,a_1 a_3 ...$ means. – md5 Feb 5 '17 at 14:30