# Choose a number X at random from the set of numbers \{1,\ 2,\ 3,\ 4

Choose a number X at random from the set of numbers . Now choose a number at random from the subset no larger than X, that is, from . Call this second number Y.
a) Find the joint mass function of X and Y.
b) Find the conditional mass function of X given that Y=i. Do it for i=1, 2, 3, 4, 5.
с) Are X and Y independent? Why?
You can still ask an expert for help

• Questions are typically answered in as fast as 30 minutes

Solve your problem for the price of one coffee

• Math expert for every subject
• Pay only if we can solve it

twineg4
We are given that . Observe that $Y\le X$ almost certainly and that also
(a)
For $k\le l$ we have that
$\mid P\left(Y=k,X=l\right)=P\left(Y=h\mid X=I\right)P\left(X=I\right)=\frac{1}{l}\cdot \frac{1}{5}$.
I $tk>l$, we have that $P\left(Y=k,X=l\right)=0$
(b)
Using the law of the total probability, we have that
$P\left(Y=i\right)=\sum _{l=i}^{5}P\left(y=i,x=i\right)=\sum _{l=i}^{5}\frac{1}{5l}$
Now,for $i\le$ we have that
$P\left(X=i\mid Y=i\right)=\frac{P\left(Y=i,X=i\right)}{P\left(Y=i\right)}=\frac{\frac{1}{5l}}{\sum _{\left\{i=1\right\}}^{5}\frac{1}{5l}}$
(c)
No, these random variables are not independent Since $Y\le X$, take any $k>l$, for example take .
Hence $P\left(Y=k,X=1\right)=0$. On the other hand, it is pretty obvious that $P\left(Y=k\right)>O$ and $P\left(X=1\right)>0.$
Thus
$P\left(Y=k,X=1\right)\ne P\left(Y=k\right)P\left(X=I\right)$
so they can not be independent.

Thomas White
For X, we have 1 chance out of five to get any of the five numbers, so
$Px\left(k\right)=\frac{1}{5}=0.4$ for any integer k between 1 and 5.
For Y,we can use the theorem of total probability, because we can divide Y
in five different cases depending on how it went with the value of X. We can
remove impossible cases (of probability 0), those cases happen when X is
smaller than the value we want to get with Y.
$Py\left(1\right)=P\left(Y=1\right)=P\left(Y=1\mid X=1\right)×P\left(X=1\right)+$
$P\left(Y=1\mid X=2\right)×P\left(X=2\right)+P\left(Y=1\mid X=3\right)×P\left(X=3\right)+$
$P\left(Y=1\mid X=4\right)×P\left(X=4\right)+P\left(Y=1\mid X=5\right)\cdot P\left(X=5\right)=$
$0.1×0.2+0.5×0.2+\frac{1}{3}×0.2+0.25×0.2+0.2×0.2=0.45666$
$Py\left(2\right)=P\left(Y=2\right)=P\left(Y=2\mid X=2\right)×P\left(X=2\right)+$
$P\left(Y=2\mid X=3\right)×P\left(X=3\right)+P\left(Y=2\mid X=4\right)×P\left(X=4\right)+$
$P\left(Y=2\mid X=5\right)×P\left(X=5\right)=0.5×0.2+\frac{1}{3}×0.2\mp 0.25×0.2×0.2×0.2=0.25666$
$Py\left(3\right)=P\left(Y=3\right)=P\left(Y=3\mid X=3\right)×P\left(X=3\right)+$
$P\left(Y=3\mid X=4\right)×P\left(X=4\right)+P\left(Y=3\mid X=5\right)×P\left(X=5\right)$
$=\frac{1}{3}×0.2+0.25×0.2+0.2×0.2=0.15666$
$Py\left(4\right)=P\left(Y=4\right)=P\left(Y=4\mid X=4\right)×P\left(X=4\right)+$
$P\left(Y=4\mid X=5\right)×P\left(X=5\right)=0.25×0.2+0.2×0.2=0.09$