A different approach to a common question

One way to solve this is using geometric probability. Though it may involve some integrals, it is a very general approach!

First, we can note that we can express the space of stick pieces using two variables $x$ and $y$, for breaking point $1$ and breaking point $2$, respectively. Then we can note that this situation is symmetric so WLOG we can let $y>x$.

Then the three stick lengths will be

  1. $\min(x,y)=x$
  2. $\max(x,y)-\min(x,y)=y-x$
  3. $1-\max(x,y)=1-y$

Now, the middle stick will thus be the median $\text{median}(x,y-x, 1-y)$, and our probability would initially be defined by the triangle formed by the lines $y>x$, $y=1$, and $x=0$.

However, as we are given the lengths form a triangle, this must mean no two of the lengths can sum to less than the third length. Another way to see this is that each length must be less than $1/2$ (as the lengths must sum to $1$). Thus, we can define our probability space of triangle lengths via

  1. $x < 1/2$
  2. $y-x < 1/2$
  3. $1-y < 1/2$

To find the expected value we can now integrate the middle length over this region and divide by the area of the this region as follows: $$\mathbb{E}(M) = \frac{1}{1/8}\int_{1/2}^1\int_{y-1/2}^{1/2} \text{median}(x,y-x,1-y)\ dx\ dy$$ The bounds here are achieved by rewriting 3. as $y > 1/2$, 2. as $x > y-1/2$, and 1. as itself, or alternatively looking at the picture below (the purple region is where triangle inequality is satsified).probability space Now this is a bit of a strange integral, so we will need to separate it into a few regions based on when $x$ i the median, when $y-x$ is the median, and when $1-y$ is the median length. Hopefully this makes sense, and if you need more help with this process, just comment!