[Math] Expected length of longest stick

probabilityproof-verification

The problem is the same as here.

A stick of 1m is divided into three pieces by two random points. Find the average length of the largest segment.

I tried solving it in a different way, and the logic seems fine, however I get a different result to $\frac{11}{18}$.

Here is my solution. Please let me know what I did wrong.

Let $X$ be the length of the stick from the beginning to the first cut. $Y$ be the length of the stick between the first and second cut and $1-X-Y$ the length between the second cut and the end of the stick.

We want to find the CDF of the following random variable: $Z=\max(X,Y,1-X-Y)$. (I believe that if anything is wrong, this might be it).

$$\begin{split}
F_Z(z) = P(Z\leq z) & = P(\max(X,Y,1-X-Y) \leq z)\\ & = P(X\leq z, Y\leq z, 1-X-Y\leq z)\\ &= P(1-Y-z\leq X \leq z, Y\leq z)
\end{split}
$$

Since we have $1-Y-z\leq z$ we deduce that $Y\geq 1-2z$. Hence:
$$\begin{split}
F_Z(z) &= \int_{1-2z}^z\int_{1-y-z}^z 1 dx dy = \int_{1-2z}^z (z-1+y+z) dy\\ &= (2z-1)(z-1+2z) + \left. \frac{y^2}{2}\right|_{y=1-2z}^{y=z} \\ &=(2z-1)(3z-1) + \frac{1}{2}(z^2- (2z-1)^2) \\ & = (2z-1)(3z-1) +\frac{1}{2}(-3z^2 + 4z -1) \\ & = \frac{1}{2}(3z-1)^2
\end{split}
$$
Now, the pdf of $Z$ is :
$$f_Z(z) = \frac{d}{dz}F_Z(z) = 9z-3
$$

And now, in order to find the expected value of the largest length, we need to integrate over $(\frac{1}{3},1)$ as the largest piece needs to be greater than $\frac{1}{3}$. Hence

$$\begin{split}
E[Z] = \int_{\frac{1}{3}}^{1} z f_Z(z) dz = \int_{\frac{1}{3}}^{1} z (9z-3) dz = \frac{14}{9}
\end{split}
$$
The result is obviously wrong as it needs to be something between $0$ and $1$, however after going over the solution multiple times, and checking the calculations with Wolfram, I cannot seem to figure out what went wrong.

Best Answer

Here is how I would do it.

Lets define $x$ to be the short stick, $y$ to be the medium stick and $z$ to be the long stick.

$x\le y\le z\\ z = 1-x-y\\ x\le y \le \frac {1-x}{2}\\ x\le \frac 13$

$$ \bar z = \frac {\displaystyle\int_0^\frac 13\int_x^{\frac {1-x}{2}} 1-x-y\ dy\ dx}{\displaystyle\int_0^\frac 13\int_x^{\frac {1-x}{2}} 1\ dy\ dx}$$

Related Question