Conditional expectation of Borel function of two independent variables I am trying to solve the following problem:
Let $X$, $Y$ be two independent random variables, and let $f$ be a Borel function. Show that
$$
\mathbb{E}[f(X,Y)|Y=t]=\mathbb{E}[f(X,t)].
$$
I have no clear idea where to start. By the definition of conditional expectation, we should have that
$$
\int_{\{Y=t\}}f(X,Y)dP=\int_{\{Y=t\}}\mathbb{E}[f(X,Y)|Y].
$$
On the LHS I have what I wanted, i.e. $\mathbb{E}[f(X,t)]$. But how do I proceed from here? Also, why is independence of variables important?

We want to show $\mathbb E[f(X,Y) | Y] = h(Y)$, where $h(t) = \mathbb E[f(X,t)]$ (Assume that $\mathbb E[|f(X,Y)|] < \infty $)
So we need to show that $h(Y)$ is $\sigma(Y)$ measurable, but $$h(Y) = \int_{\Omega_{1}}f(X(\omega_1),Y)d\mathbb P(\omega_1),$$ so it follows from Fubini-Theorem (Y is $\sigma(Y)$ measurable, and $h$ as a integral from measurable function, too.)
Next, take any $A \in \sigma(Y)$
We have to show $\mathbb E[h(Y)\chi_A] = \mathbb E[f(X,Y)\chi_A] $
We know that $(Y,\chi_A)$ is independent of $X$, let's form vector $(X,Y,\chi_A)$ with distribution $\mu_{X} \otimes \mu_{(Y,A)}$ (due to independence).
Then, we have:
$$\mathbb E[f(X,Y)\chi_A] = \int_{R^3}f(x,y)z \cdot d(\mu_X \otimes \mu_{(Y,A)})(x,y,z) = \int_{R^2}\int_R f(x,y)z \cdot d\mu_X(x)d\mu_{(Y,A)}(y,z) = \int_{R} \mathbb E[f(x,Y) \chi_A] d\mu_X(x) = \mathbb E[\int_{R} f(x,Y) d\mu_X(x) \chi_A] = \mathbb E[ H(Y) \chi_A]$$
All steps with interchanging due to Fubini
