Here's a small problem I tried to solve. 2 dice are thrown, let $X$ denote the result of the first dice and let $Y$ denote the result of the second dice. I'm asked to describe the law of $Z=X+Y$.
I tried to solve this problem using the law of total probabilities using the partition given by the events $\{ X=i \}$, for $i=1,2,...,6$. Now let $j \in \{ 1,2,3,...,11,12 \}$, then
\begin{align*} P(Z=j) &=\sum_{i=1}^6 P(Z=j\mid X=i)P(X=i)\\ &=\frac{1}{6}\sum_{i=1}^6 P(X+Y=j\mid X=i)\\ &=\frac{1}{6}\sum_{i=1}^6 P(Y=j-i\mid X=i)\\ &=\frac{1}{6}\sum_{i=1}^6 P(Y=j-i). \end{align*}
I cannot justify the last step. I just found out that it leads to the correct answer. I guess that it has something to do with the fact that the variables $X$ and $Y$ are independant.
In my book the definition of independant variables is the following : $X$ and $Y$ are said to be independant iff for all $i,j$ the events $\{X=i\}$ and $\{Y=j\}$ are independant, i.e. $$ P(X=i,Y=j)=P(X=i)P(Y=j). $$
Also I guess that $P(X=i,Y=j)$ means $P(\{X=i\} \cap \{Y=j\})$. Can anyone explain why I am allowed to write :
$$ P(Y=j-i\mid X=i)=P(Y=j-i). $$
Are the two events $\{ Y=j-i\}$ and $\{ X=i \}$ independant ?
Thanks for your help.
If $X,Y$ are independent random variables then: $$P(X\in A,Y\in B)=P(X\in A)P(X\in B)$$ for all Borel measurable sets $A,B$.
Using that we find:
$$P(Y=j-i\mid X=i)=\frac{P(Y=j-i,X=i)}{P(X=i)}=\frac{P(Y=j-i)P(X=i)}{P(X=i)}=$$$$P(Y=j-i)$$
where the second equality rests on independence.