# What is E[X|X+Y < z] with X, Y independent Normals?

Let $$X\sim N(\mu_X,\sigma_X^2)$$ and $$Y\sim N(\mu_Y,\sigma_Y^2)$$ and $$Cov(X,Y)=\sigma_{XY}$$. Define $$Z=X+Y$$.

I know that $$E[X|Z=z]=\mu_X + \frac{\sigma_X^2+\sigma_{XY}}{\sigma_X^2+2\sigma_{XY}+\sigma_Y^2}(z-\mu_X-\mu_Y)$$.

But what is $$E[X|Z\leq z]$$?

Can I just integrate over all possible realizations of $$Z\leq z$$ and use linearity to do the following?

\begin{align*}E[X|Z\leq z] & = \mu_X + \frac{\sigma_X^2+\sigma_{XY}}{\sigma_X^2+2\sigma_{XY}+\sigma_Y^2}(E[Z|Z\leq z]-\mu_Z)\\ & = \mu_X + \frac{\sigma_X^2+\sigma_{XY}}{\sqrt{\sigma_X^2+2\sigma_{XY}+\sigma_Y^2}}\frac{\phi(\frac{z-\mu_Z}{\sigma_Z})}{\Phi(\frac{z-\mu_Z}{\sigma_Z})} \end{align*}

Yes, using the law of total expectation, \begin{align} E(X|Z\le z) &=E(E(X|Z)|Z\le z) \\&=E(a + bZ|Z\le z) \\&=a + bE(Z|Z\le z). \end{align}