Conditional expectation as Borel function Let $X,Y$ be random variables with $E|X|< \infty$. Prove that there is a Borel function $h:\mathbb{R}\rightarrow \mathbb{R}$ such that $E[X|\sigma(Y)]=h(Y)$ almost surely. (Here $\sigma(Y)$ is Borel sigma-algebra generated by $Y$). Thank you. 
 A: Note that $E[X \mid \sigma(Y)]$ is $\sigma(Y)$-measurable. We will prove the existience of a measurable $h$ for any $\sigma(Y)$-measurable random variable $Z$. First let $Z = 1_A$ be a characteristic function of some $A \in \sigma(Y)$. Then $A = Y^{-1}[B]$ for some Borel set $B$. Let $h = 1_B$, then for any $\omega \in \Omega$: $$ 1_B\circ Y(\omega) = 1 \iff Y(\omega) \in B \iff \omega \in Y^{-1}[B] = A $$
Hence $Z = 1_B(Y)$.
If $Z$ is a linear combination of charactestic functions, say $Z = \sum_i a_i 1_{A_i}$, let $h_i$ such that $h_i(Y) = 1_{A_i}$ by the above, and set $h = \sum_i a_i h_i$. Then $h$ is measurable as a linear combination of the $h_i$ and 
$$ h(Y) = \sum_i a_i h_i(Y) = \sum_i a_i 1_{A_i} = Z. $$
If $Z$ is non-negative, then there are $Z_n$ of the form considered in the last paragraph such that $Z_n \nearrow Z$. Choose measurable $h_n$ such that $h_n(Y) = Z_n$. We may assume that $h_n$ is a monotone sequence, by changing outside of $Y(\Omega)$. Then $h = \lim h_n$ exists an is measurable, moreover, by construction $h(Y) = Z$.
If $Z$ is any random variable, write $Z = Z^+ - Z^-$ where $Z^\pm \ge 0$, choose $h^\pm$ with $h^\pm(Y) = Z^\pm$. Now let $h = h^+ - h^-$.
A: martini's answer is missing one point: $Y(\Omega)$ can well be not measurable. A workaround is to consider $h(x) = \lim_{n \to \infty} h_n(x)$ whenever the limit exists, and $h(x) = 0$ otherwise. (The set of points at which the limit exists is easily shown to be measurable).
A: You can use the monotone class theorem to show that, whenever $Z$ is $\sigma(Y)$–measurable (like $E[X|\sigma(Y)]$ in your case), then $Z=h(Y)$ for some Borel function $h$.
First, suppose that $Z$ is bounded.
Sticking to the notation in Wikipedia, choose $\mathcal H$ to be the collection of all the bounded functions $B$ such that $B=h(Y)$ for some bounded borel function $h$. $\mathcal A$ will simply be $\sigma(Y)$. If one can check the hypotheses of the theorem, then the conclusion will be that $\mathcal H$ contains all bounded $\sigma(Y)$–measurable functions, so that any of those will have the form $h(Y)$ for some Borel $h$.
That $\mathcal H$ is a vector space is obvious, so check $(2)$. 
If $A$ is in $\sigma(Y)$, then $A=\{Y\in F\}$ for some borel set $F\subset \mathbb R$, so that $1_A (\omega)=1_F(Y(\omega))$, i.e. the indicator functions are of the form $h(Y)$, so check $(1).$ 
The last part is trickier: suppose that the sequence of functions $B_n=h_n(Y)\uparrow B$ for a bounded $B$. You can define $h=\limsup h_n$, so that $h$ is Borel, bounded and $B(\omega)=h(Y(\omega))$ for each $\omega$, i.e. $B$ is of the required form: check $(3)$.
Now, if $Z$ is unbounded, you can consider $W=\arctan Z$, conclude that $W=f(Y)$ for some bounded Borel function $f$, and $h:=\tan \circ f$ is the one you are looking for.
