pdf of a quotient of uniform random variables
Solution 1:
Because $X_2$ is positive with almost surely, cumulative distribution function for $Z=X_1/X_2$ is $$ F_Z(z) = \mathbb{P}(Z \leqslant z) = \mathbb{P}(X_1 \leqslant z X_2) = \mathbb{E}_{X_2}\left( \mathbb{P}(X_1 \leqslant z X_2 | X_2)\right) = \mathbb{E}_{X_2}\left( F_{X_1}(z X_2)\right) $$ Clearly $F_Z(z)=0$ for $z\leqslant 0$, so assume $z > 0$ $$ F_Z(z) = \int_0^1 \left\{ \begin{array}{cl} z x_2 & 0 < x_2 <1/z \\ 1 & x_2 > 1/z \end{array} \right. \mathrm{d} x_2 = \frac{z}{2} \left(\frac{1}{\max(z,1)}\right)^2 + \left(1 - \frac{1}{\max(z,1)}\right) = \left\{\begin{array}{cl} \frac{z}{2} & 0< z\leqslant 1 \\ 1-\frac{1}{2z} & z > 1 \end{array} \right. $$ The probability density is obtained by differentiation.