Let $X$ and $Y$ be exponential distributed. (Independent)
Find the joint pdf of $X$ and $\frac{Y}{X}$ . And find the pdf of $\frac{Y}{X}$.
Idea: I think that we can compute the cumulative probability function.
$ F(a,b) = P( X \le a, \frac{Y}{X} \le b) = P( X\le a, Y \le bX) =\int_0^a f(x) ( \int_0^{bx} g(y) dy) dx = \int_0^a f(x) ( 1- e^{-\lambda b x} ) dx $ but what can I do now?
Thank you for your help
Let's see... (I'll call $Z=\tfrac YX$) $$F_{XZ}(a,b)=\int_0^a \int_0^{bx} \lambda e^{-\lambda x} \mu e^{-\mu y} \, dy\, dx=\int_0^a \lambda e^{-\lambda x}(1-e^{-\mu b x}) \, dx=$$ $$= \lambda \int_0^a e^{-\lambda x}-e^{-(\lambda +\mu b) x}) \, dx=\lambda \left. \left(\frac{e^{-(\lambda+\mu b)x}}{\lambda+\mu b}-\frac{e^{-\lambda x}}{\lambda}\right)\right|_0^a=$$ $$=1-\frac{\lambda}{\lambda+\mu b}-e^{-\lambda a}+\frac{\lambda}{\lambda+\mu b}e^{-(\lambda + \mu b)a}.$$
So the joint CDF, lets call it $F_{XZ}(x,z)$ is $$F_{XZ}(x,z)=1-\frac{\lambda}{\lambda+\mu z}-e^{-\lambda x}+\frac{\lambda}{\lambda+\mu z}e^{-(\lambda + \mu z)x},\qquad x,z\ge 0,$$ and zero in other case.
Then you can find a joint density of $X$ and $Z$ taking partial derivatives, once with respect to each variable, that is $$f_{XZ}(x,z)=\frac{\partial^2}{\partial z \partial x}F_{XZ}(x,z)$$ (and in those specific points where derivatives don't exist—like the axes in this example—you can put whatever you want).
To find the PDF of $Z$ you can, as usual, integrate in $x$, that is $$f_Z(z)=\int_{-\infty}^{+\infty} f_{XZ}(x,z) \, dx.$$
Nevertheless, the path you chose gives an even better (I mean, more straightforward) option: first calculate the CDF of $Z$, then derive (in its only variable) to find its PDF. This is easier as only involves taking a limit: $$F_Z(z)=\lim_{x\to+\infty}F_{XZ}(x,z)$$ So for $z\ge0$ $$F_Z(z)=\lim_{x\to+\infty} \left(1-\frac{\lambda}{\lambda+\mu z}-e^{-\lambda x}+\frac{\lambda}{\lambda+\mu z}e^{-(\lambda + \mu z)x}\right)=1-\frac{\lambda}{\lambda+\mu z}$$ (since both exponentials tend to $0$), and $F_Z(z)=0$ if $z<0$.
And so $$f_Z(z)=\begin{cases} \frac{\lambda\mu}{(\lambda+\mu z)^2} & z\ge 0\\ 0& z<0. \\ \end{cases}$$