# Conditional Expectation of function of two RVs, one measurable, one independent

Let $\mathcal{A}$ be a $\sigma$-sub-algebra in the probability space $(\Omega, \mathcal{F}, P)$. Let $X$ be a $\mathcal{A}$-measurable function and $Z$ independent on $\mathcal{A}$. Why can I write $$E(f(X,Z) \mid \mathcal{A})=\int_{\Omega} f(X,Z(\omega)) P(d\omega) \text{?}$$ (Note that $X$ does not depend on is not a function of $\omega$. The background was that I want to have $E(f(X,Z) \mid \mathcal{A})=E(f(X,Z))$)

EDIT Like @Did said, the question should be formulated a bit differently: Why is $$E(f(X,Z) \mid \mathcal{A}) = g(X)$$ with $g(x)=E(f(x,Z))$?

(The integral in the original expression would be more $U(\omega)=\int f(X(\omega),z)\,\mathrm dP_Z(z)$ and I asked myself why $X$ in the integrand is not integrated as well, which I expressed as "is not a function of")

• The plot thickens: $X:\Omega\to\mathbb R$ is an $\mathcal A$-measurable function while $X$ would not be a random variable? Recall that random variable is a synonym of $\mathcal F$-measurable function and that, if $\mathcal A\subseteq\mathcal F$, then every $\mathcal A$-measurable function is $\mathcal F$-measurable.
– Did
Oct 17, 2011 at 17:45
• @Didier No worries, then maybe I should withdraw it, and the other expression is the right way to express what I mean, this came up from a discussion with Gortaur and I think you already gave the answer that's making me understand, I still have to look into the details. Oct 18, 2011 at 7:02
• You will do as you want, I simply do not know what your question is, yet.
– Did
Oct 18, 2011 at 7:17
• @Didier: I think I had to see that $U(\omega)=∫f(X(\omega),z)dP_Z (z).$ because I thought that after putting $g(X)$ meant $∫f(X(\omega),Z(\omega)) dP (\omega)$ to understand $E(f(X,Z)\mid \mathcal{A}) = g(X)$ (<- so this would be my question) and your answer helped me, I somehow wasn't aware that distributions could help (which is now so obvious) Oct 18, 2011 at 7:33

As often with conditional expectations, to come back to the definition yields the solution. To check that $U=\mathrm E(f(X,Z)\mid \mathcal A)$ is to check that two conditions hold simultaneously: (1) $U$ is $\mathcal A$-measurable; (2) for every bounded and $\mathcal A$-measurable $Y$, one has $\mathrm E(UY)=\mathrm E(f(X,Z)Y)$.

Let us check (1) and (2) for $U=g(X)$ where $g$ is defined by $g(x)=\mathrm E(f(x,Z))$.

Since $U=g(X)$ is a measurable function of $X$ and $X$ is $\mathcal A$-measurable, $U$ is $\mathcal A$-measurable.

Now, $X$ and $Y$ are $\mathcal A$-measurable and $Z$ is independent on $\mathcal A$ hence $(X,Y)$ and $Z$ are independent. Calling $\mu$ the distribution of $(X,Y)$ and $\nu$ the distribution of $Z$, one gets $$\mathrm E(f(X,Z)Y)=\iint f(x,z)\,y\,\mathrm d\mu(x,y)\,\mathrm d\nu(z).$$ On the other hand, $$g(x)=\int f(x,z)\,\mathrm d\nu(z),$$ hence $$\mathrm E(UY)=\mathrm E(g(X)Y)=\int g(x)\,y\,\mathrm d\mu(x,y)=\iint f(x,z)\,y\,\mathrm d\nu(z)\,\mathrm d\mu(x,y),$$ hence $\mathrm E(UY)=\mathrm E(f(X,Z)Y)$ by Fubini theorem. Finally, (1) and (2) hold for $U=g(X)$ hence $$\mathrm E(f(X,Z)\mid \mathcal A)=g(X)=\int f(X,z)\,\mathrm dP_Z(z).$$ This means that $\mathrm E(f(X,Z)\mid \mathcal A)=U$ almost surely, where, for every $\omega$ in $\Omega$, $$U(\omega)=\int f(X(\omega),z)\,\mathrm dP_Z(z).$$ Note: All this, and much more, is explained in a gem of a small book, highly accessible, titled Probability with martingales.

• In your question, the mention that $X$ does not depend on $\omega$ is quite strange. You might want to explain what you mean. Likewise, note that I did not reproduce your displayed formula, because I find it prone to misinterpretations.
– Did
Oct 17, 2011 at 15:17
• I had $X$ in mind as a function and wanted to say that $X$ is not actually a function of$\omega$, and yes, that's unfortunate expression in this context. Thanks for your answer Oct 17, 2011 at 16:03
• In which part of the book you mentioned can I find the proof? I searched for it and wasn't able to find it. Dec 23, 2020 at 10:03