Standard Normal Distribution with Conditional Expectation

conditional probabilityconditional-expectationnormal distribution

Consider the random variable $Z$ that has a Normal distribution with mean $0$ and variance $1$, i.e $Z\sim{N(0,1)}$. I have to show that the expectation of $Z$ given that $a<Z<b$ is given by
\begin{equation}
\frac{\phi(a)-\phi(b)}{\Phi(b)-\Phi(a)}
\end{equation}

where $\Phi$ denotes the cumulative distribution function for $Z$.


I attempted to compute first $P(Z|a<Z<b)$ by writing it as a fraction, i.e $$\frac{P(Z=z \cap a<Z<b)}{P(a<Z<b)}$$
The denominator is pretty straight forward but I cannot really get anywhere with the numerator.

Best Answer

Use $\mathbb E[Z|A]=\frac{\mathbb E[Z\mathbb 1_{A}]}{\mathbb P(A)}$. Here $$ \mathbb E[Z|a<Z<b] =\frac{\mathbb E[Z\mathbb 1_{a<Z<b}]}{\mathbb P(a<Z<b)} = \frac{\int\limits_{-\infty}^\infty z\mathbb 1_{a<z<b} \phi(z)\,dz}{\Phi(b)-\Phi(a)}=\frac{\int\limits_a^b z\phi(z)\,dz}{\Phi(b)-\Phi(a)}. $$ The numerator can be found directly: $$ \int\limits_a^b z\phi(z)\,dz = \int\limits_a^b z\frac{1}{\sqrt{2\pi}}e^{-z^2/2}\,dz = \frac{1}{\sqrt{2\pi}}\int\limits_a^b e^{-z^2/2}\,d(z^2/2) = -\frac{1}{\sqrt{2\pi}}e^{-z^2/2}\biggm|_a^b $$ $$ = \phi(a)-\phi(b). $$