X is some random variable and f is a continuous function. Is f[E(X)] = E[f(X)]? I am curious about at what conditions the expectation and a mapping could exchange their operation.
Say, X is some random variable, and $f:R\rightarrow R$ is a continuous function. Does
$$f[E(X)] = E[f(X)]$$
hold?
What if X is absolutely continuous (i.e., the density function g(x) of X exists)? Does it make any difference?
I'm just feel it's interesting. Thanks for discussion!:)

No it doesn't. In fact, if $f$ is strictly convex (e.g. $f(x)=x^2$), and $X$ is not a constant with probability 1, then Jensen's inequality tells us that $$E[f(X)] > f(E(X))$$
One important class of functions where equality does hold is linear functions (e.g. $f(x)=ax+b$)
