# CDF of Mixture of Two Random Variables

$$\mathbb{P}(Z=X)=\alpha$$ and $$\mathbb{P}(Z=Y)=1-\alpha$$, i.e. $$Z$$ is a mixture of two random variables $$X$$ and $$Y$$. I am stuck in the application of the law of total probability to show that $$F_Z(z)=\alpha F_X(z)+(1-\alpha)F_Y(z)$$:

$$F_Z(z)=\mathbb{P}(Z\leq z)=\mathbb{P}(Z\leq z|Z=X)\mathbb{P}(Z=X)+\mathbb{P}(Z\leq z|Z=Y)\mathbb{P}(Z=Y)=\alpha\mathbb{P}(Z\leq z|Z=X)+(1-\alpha)\mathbb{P}(Z\leq z|Z=Y)=\alpha\mathbb{P}(X\leq z|Z=X)+(1-\alpha)\mathbb{P}(Y\leq z|Z=Y)$$.

Dropping the conditioning is obviously not allowed, and writing the definition of conditional probability makes it look weirder. I feel using the "substitution law" is trickier than what I wrote here.

• Why it is not allowed $\mathbb{P}(X\leq z|Z=X)=\mathbb{P}(X\leq z)$. The relationship you give can be written as $Z|(X,Y) = \left\{ \begin{array}{ c l } X, & a \\ Y, & 1-a \end{array} \right..$ – papasmurfete Oct 17 '18 at 14:05
• But let us write the definition of conditional probability: $$\mathbb{P}(Z\leq z|Z=X)=\frac{\mathbb{P}(Z\leq z,Z=X)}{{P}(Z=X)}$$ Why can we say $$\mathbb{P}(Z\leq z,Z=X)=\alpha\mathbb{P}(X\leq z)$$ – MRR Oct 19 '18 at 4:11
• $Z$ is smaller or equal than z, when $Z=X$ is true , so that means that $X$ is smaller or equal than z.$\{Z\leq z|Z=X\}=\{X\leq z\}$. – papasmurfete Oct 19 '18 at 6:13