Suppose we have an experiment of tossing a fair dice until the number $6$ results.
If $Y$ denotes the random variable of the number of throws until we get $6$, and $X$ denotes the random variable that counts the number of tosses which resulted in an even number, I need to calculate:
a. The conditional distribution of $X$ given $Y$.
b. The distribution of $X$.
my attempt:
a. If $Y=n$ then $X$ is a binomial distribution, $X \sim bin(n-1, 0.5)$
hence $P(X=k | Y=n) = \binom{n-1}{k-1} \frac{1}{2}^{k-1} \frac{1}{2}^{n-k}$.
b. $P(X=k) = \sum_{n=1}^{\infty}P(X=k | Y=n)P(Y=n)$
where $P(Y=n) = (\frac{5}{6}^{n-1})(\frac{1}{6})$
corrections please?