I have a question and I know it is wrong. However I do not understand where I am messing up. If somebody could explain where I am going wrong, that would be great.
If we have a probability space $(X,\mathcal{F},\mu)$, and a sub-sigma-algebra $\mathcal{A}\subset \mathcal{F}$, the conditional expectation for $f\in L^1(X,\mathcal{F},\mu)$ is defined to be the (a.s) unique measurable $\mathbb{E}[f\mid \mathcal{A}]\in L^1(X,\mathcal{A},\mu)$ such that $\int_A f\,d\mu=\int_A \mathbb{E}[f\mid \mathcal{A}]\,d\mu$ for all $A\in \mathcal{A}$.
My question is does $\int_X f\,d\mu$ not satisfy this? Of course, it would be nonsensical to say that the conditional expectation wrt some arbitrary sub-sigma-algebra is equal to the expectation.
However, if we plug $\int_Xf\,d\mu$ into the above for $\mathbb{E}[f\mid \mathcal{A}]$, we have $\int_A(\int_Xf\,d\mu)\,d\mu=\int_X(\int_A fd\mu)d\mu=\int_Afd\mu$ where the first equality uses Fubini.
I think the use of Fubini is suspicious. Any further explanations are welcome!
(INFO: The reason I came across this was as follows. I was looking at a proof of Birkhoff's Ergodic theorem, and in it it claimed that the conditional expectation with respect to the sigma-algebra consisting of sets of measure $0$ or $1$ was equal to the expectation. I believe this uses Fubini?)
EDIT: Sorry if I did not explain it correctly. I basically am saying that the constant function $\int_X fd\mu$ is in $L^1(X,\mathcal{A},\mu)$ and satisfies $\int_A fd\mu=\int_A (\int_X fd\mu)d\mu$, and so does this not mean $\int_X fd\mu= \mathbb{E}[f\mid \mathcal{A}]$?
$E(f|\mathcal A)$ is an $\mathcal A$ measurable random variable $g$ such that $\int_A f d\mu =\int_A g d\mu$ for all $A \in \mathcal A$. You want to claim that the constant $g=\int_X f d\mu$ satisfies these two properties. The measurability part is fine but the equation $\int_A f d\mu =\int_A g d\mu$ is not satisfied: RHS $= \mu (A) \int_X f d \mu$ which is not the same as LHS. Your computation of RHS is wrong. If you apply Fubini's Theorem correctly to $\int f(x)I_{A\times X}(x,y)d(\mu \times \mu) (x,y)$ you will simply get $\int_A fd\mu=\int_A fd\mu$!