(See also related question here)
Let $\omega\in (0,1]$ be represented in binary as $\omega=0.d_1(\omega)d_2(\omega)\cdots$ where each $d_i(\omega)$ is either $0$ or $1$ (a tail of zeros is prohibited). We define $r_n(\omega)=2d_n(\omega)-1$.
We may use $(r_n)$ to model a simple random walk: Pick a $\omega\in(0,1]$. There is a particle initially at the origin. At the $i$th stage, where $i=1,2,3,\cdots$ the particle moves a unit to the right or left depending on whether $r_i(\omega)$ is $1$ or $-1$ respectively.
It is proved in my book that $\int_0^{1}r_i(\omega)r_j(\omega)d\omega=0$ for $i\ne j$. I understand that proof. After that they say that:
(This equation) corresponds to the fact that independent random variables are uncorrelated.
I don't understand this line.
To show $X=r_i(\omega)$ and $Y=r_j(\omega)$ to be uncorrelated (note that $\omega$ is uniform in $(0,1]$), I would prefer showing $E(XY)=E(X)E(Y)$. Now, I can prove that $E(X)=\int_0^1 (r_i(t)\times 1) dt=0$ and similarly $E(Y)=0$. So, it remains to prove that $E(XY)=0$. I don't know the PDF of $XY$ or $(X,Y)$ however. Moreover somewhere the equation $\int_0^{1}r_i(\omega)r_j(\omega)d\omega=0$ has to be used. Can someone explain how to find $E(XY)$?
Underlying is probability space $(\Omega=(0,1],\mathcal B(0,1],P)$ where $\mathcal B(0,1]$ denotes the collection of Borel subsets of $(0,1]$ and $P$ is the restriction of Lebesguemeasure $\lambda$ on $(0,1]$.
In that situation the expectation of a random variable $Z:\Omega\to\mathbb R$ is defined as:$$\int Z(\omega)P(d\omega)=\int_0^1Z(\omega)d\omega$$ where on RHS there is integration wrt the Lebesgue measure.
If $X$ is prescribed by $\omega\mapsto r_i(\omega)$ and $Y$ is prescribed by $\omega\mapsto r_j(\omega)$ then by definition: $$\mathbb EXY=\int_0^1r_i(\omega)r_j(\omega)d\omega$$ Since moreover $\mathbb EX=0=\mathbb EY$ here we also have:$$\mathsf{Cov}(X,Y)=\int_0^1r_i(\omega)r_j(\omega)d\omega$$ So the fact that it takes value $0$ tells us exactly that $X$ and $Y$ are uncorrelated.