# how to find expected value?

The random variables X and Y have joint probability function $p(x,y)$ for $x = 0,1$ and $y = 0,1,2$. Suppose $3p(1,1) = p(1,2)$, and $p(1,1)$ maximizes the variance of $XY$. Calculate the probability that $X$ or $Y$ is $0$.

Solution: Let $Z = XY$. Let $a, b$, and $c$ be the probabilities that $Z$ takes on the values $0, 1$, and $2$, respectively. We have $b = p(1,1)$ and $c = p(1,2)$ and thus $3b = c$. And because the probabilities sum to $1, a = 1 – b – c = 1 – 4b$.

Then, $$E(Z) = b + 2c = 7b,$$$$E(Z\cdot Z) = b + 4c = 13b.$$ Then, $$Var (Z) = 13b-19b^2.$$$$\frac{dVar(Z)}{db}=13-98b=0 \implies b =\frac{ 13}{98}.$$ The probability that either $X$ or $Y$ is zero is the same as the probability that $Z$ is $0$ which is as $a = 1 – 4b = \frac{46}{98} = \frac{23}{49}$.

I am not sure how they got: $E(Z) = b + 2c = 7b$. Can someone explain this step where $b$ and $2c$ come from?

• I don't think it's a good idea to delete the questions. Even if they no longer interest you, they should still exist for the purpose of the community. I've flagged a number of these "deleted" questions for attention. Thanks. Mar 15, 2018 at 0:17