TITLE: Are functions of uncorrelated random variables still uncorrelated?
QUESTION [9 upvotes]: Suppose $X$ and $Y$ are real-valued random variables, and $f$ and $g$ are Borel measurable real-valued functions defined on $\mathbb{R}$.
If $X$ and $Y$ are independent, then I know that $f(X)$ and $g(Y)$ are also independent.
If $X$ and $Y$ are uncorrelated, are $f(X)$ and $g(Y)$ also uncorrelated?
Thanks and regards!

REPLY [4 votes]: Asking myself the same question I actually got the following implication:
$$\text{cov}(f(X),g(Y))=0 \quad \forall f,g \text{ meassurable and bounded} \Rightarrow X,Y \text{are independent} $$
A proof would be:
$$ 0=\text{cov}(f(X),g(Y))=\mathbb{E}[f(X)g(Y)]-\mathbb{E}[f(X)]\mathbb{E}[g(Y)]\quad \forall f,g \\
\Rightarrow \mathbb{E}[f(X)g(Y)]=\mathbb{E}[f(X)]\mathbb{E}[g(Y)]\quad \forall f,g $$
Which results in:
\begin{align}
\mathbb{P}(X\in B_1,Y\in B_2)&=\mathbb{E}[1_{B_1}(X)1_{B_2}(Y)]\\
&=\mathbb{E}[1_{B_1}(X)]\mathbb{E}[1_{B_2}(Y)]\\
&=\mathbb{P}(X\in B_1)\mathbb{P}(Y\in B_2) \quad \forall B_1,B_2 \in B(\mathbb{R})
\end{align}
Which is the definition of independence. I guess the intuition is, that Correlation is only "independence at first glance" (integration over the entire integral). Focusing on certain parts with (indicator-)functions shows you if they are actually independent or not.