Interchanging Expectation and Derivative

974 Views Asked by At

Suppose I have a random function, $f(x)(\omega)$. And that for fixed $\omega$, we have the derivative $g(x)(\omega)=\frac{d}{dx}f(x)(\omega)$. For a fixed $x$, I can find the expectation $E(f(x))$. Suppose I want to find the derivative of this expectation with respect to $x$, i.e., $\frac{d}{dx}E(f(x))$? When can I say that $$\frac{d}{dx}E(f(x))=E(g(x))?$$ Does it suffice to assume that $$E(g(x))<\infty?$$ Or can I assume less or do I need to assume more? Of course, I could use dominated convergence if I had an appropriate function. But lets assume I don't actually know what $f$ is so I can't find a specific function to use dominated convergence with.

1

There are 1 best solutions below

0
On

What about this (counter) example: Let $Z$ be a random variable that is never $0$, and that has PDF: $$ f_Z(z) = \frac{1}{2}e^{-|z|} \quad \forall z \in \mathbb{R} $$ In particular, $|Z|$ is a positive and exponentially distributed random variable with rate $\lambda =1$. Define: $$ r(x) = \left\{ \begin{array}{ll} 0 &\mbox{ if $|x| \leq 1/|Z|$} \\ xe^{1/|x|} & \mbox{ if $|x|> 1/|Z|$} \end{array} \right.$$ Then for all realizations of $Z$ we have $r(0)=r'(0)=0$, and so $E[r(0)]=E[r'(0)]=0$. However, for all $x\neq 0$ we have $$ E[r(x)] = xe^{1/|x|}P[|Z|>1/|x|] = xe^{1/|x|}e^{-1/|x|} = x $$ Since $E[r(0)]=0$, it follows that $E[r(x)]=x$ for all $x \in \mathbb{R}$. Thus:
$$ \frac{d}{dx} E[r(x)] = 1 \quad \forall x \in \mathbb{R} $$ In particular, $$\frac{d}{dx} E[r(x)]|_{x=0} = 1 \neq 0 = E[r'(0)] $$