X,Y are independent exponentially distributed then what is the distribution of X/(X+Y) Been crushing my head with this exercise. I know how to get the distribution of a ratio of exponential variables and of the sum of them, but i can't piece everything together.
The exercise goes as this:
If X,Y are independent exponentially distributed with beta = 1 (parameter of the exponential distribution = 1) then what is the distribution of X/(X+Y)
Any ideas?
Thanks a lot.
 A: Obviously $X/(X+Y)$ is between $0$ and $1$.  Let (lower-case) $w$ be a number between $0$ and $1$.
$$
\frac{X}{X+Y} \le w \text{ if and only if } (1-w)X \le wY.
$$
We will find this probability.
The conditional probability that $Y\ge\dfrac{(1-w)}{w}X$, given the value of $X$, is
$$
e^{-(1-w)X/w}.
$$
The probability we seek is then the expected value of that:
\begin{align}
\operatorname{E} e^{-(1-w)X/w} & = \int_0^\infty e^{-(1-w)x/w} \Big(e^{-x}\,dx\Big) \\[10pt]
& = \int_0^\infty e^{-x/w} \, dx \\[10pt]
& = w.
\end{align}
In other words, this random variable is uniformly distributed between $0$ and $1$.
Second method:  The equality $Y=\frac{1-w}{w}X$ is a straight line through the $(X,Y)$-plane, passing through $(0,0)$ and having positive slope.
We can let $y$ go from $0$ to $\infty$ and then for any fixed value of $y$, let $x$ go from $0$ to $\frac{w}{1-w}y$
\begin{align}
& \int_0^\infty \left(\int_0^{wy/(1-w)} e^{-y} e^{-x} \,dx \right) \, dy \\[10pt]
= {} & \int_0^\infty e^{-y}\left(1-e^{-wy/(1-w)}\right) \, dy \\[10pt]
= {} & \int_0^\infty e^{-y} - e^{-y/(1-w)} \, dy  \\[10pt]
= {} & 1 - (1-w) \\[10pt]
= {} & w.
\end{align}
A: Another way is to do it is to perform the following transformation. Let \begin{align*} U&=\frac{X}{X+Y} \\ V&=X+Y.\end{align*} Then \begin{align*} x(u,v)&=uv\\y(u,v)&=v-uv. \end{align*}
The determinant of the Jacobian of the transformation is
$$\left| \begin{matrix} v & u\\ -v & 1-u \end{matrix} \right|=v.
$$
Then, the joint pdf of $U$ and $V$ is
$$f_{U,V}(u,v)=f_{X,Y}(uv,v-uv)|v|=ve^{-v}, \hspace{2mm} \text{for } v\geq0, 0\leq u\leq1.
$$
Finally, "integrate out" the $v$ to obtain the marginal pdf of $U=X/(X+Y)$ as
$$f_U(u)=\int_0^{\infty}f_{U,V}(u,v)dv=\int_0^{\infty}ve^{-v}dv=1, \hspace{2mm} \text{for } 0\leq u\leq 1.$$
Hence, as Michael Hardy showed, $X/(X+Y)$ is uniformly distributed on $[0,1].$
A: In other words, for each $a > 0$, you want to compute $P\left(\frac{X}{X+Y} < a \right)$.
Outline: Find the joint density of $(X,Y)$, and integrate it over the subset of the plane $\left\{ (x,y) : \frac{x}{x+y} < a \right\}$.
