Conditional probability with Bernoulli and Normal

224 Views Asked by At

Let $X$ be a normal variable with mean $0$ and variance $1$. Let $Y$ be Bernoulli with $p = \frac{1}{2}$, and suppose that $X$ and $Y$ are independent. Let $Z = (Y + 1)X$. Find the conditional probability that $Y = 1$ given that $Z = 3$.

I know I need to find $P(Y = 1 | Z = 3) = \frac{P(Y = 1 \cap Z = 3)}{P(Z = 3)}$.

Attempt:

For the numerator, $P(Y = 1 \cap Z = 3) = P(Y = 1 \cap (Y + 1)X = 3) = P(2X = 3) = P(X = \frac{3}{2})$. Since $X$ is standard normal, $P(X = \frac{3}{2}) \approx 0.130$

As for the denominator, $P(Z = 3) = $?

I can't figure this out.

Any assistance is much appreciated.

2

There are 2 best solutions below

2
On

$$P(Z=3)=P(X=3,Y=0)+P(X=\frac 3 2, Y=1)$$ $$=P(X=3,P(Y=0)+P(X=\frac 3 2)P(Y=1)=0+0=0$$ since $X$ is a continuous random variable. [$P(X=a)=0$ for every real number $a$].

2
On

$\{Y=1\cap (Y+1)X=3\}=\{Y=1\cap X=3/2\}$ and $\{Y=0\cap (Y+1)X=3\}=\{Y=0\cap X=3\}$.

However these are null events, since $X$ is continuous. So the expression needs to use the appropriate probability density functions.

$$\mathsf P(Y=1\mid Z=3) =\dfrac{f_{X}(3/2)\,\mathsf P(Y=1)}{f_{X}(3/2)\,\mathsf P(Y=1)+f_{X}(3)\,\mathsf P(Y=0)}$$