Riddler

# What If Robots Cut Your Pizza?

A solution to this week's riddle by fivethirtyeight.com.

Here is this week’s ridde from fivethirtyeight.com:

At RoboPizza™, pies are cut by robots. When making each cut, a robot will randomly (and independently) pick two points on a pizza’s circumference, and then cut along the chord connecting them. If you order a pizza and specify that you want the robot to make exactly three cuts, what is the expected number of pieces your pie will have?

How the robots choose the chord to slice is an important part of this puzzle; see Bertrand’s Problem. In this case, the chord is selected by randomly choosing six points on the pizzas circumfrance. Therefore, it is easy to see that for any two chords randomly selected in this way, there is a $\frac{1}{3}$ probability that the two chords will intersect and a $\frac{2}{3}$ probability that they do not.

To see this, pick any four random points on the pizza’s circumfrance. There are only six different ways ($3! = 6$) to connect these points. In two cases, the chords intersect, and in four cases they do not. This is an argument by symetry. We could reach the same results, with far more math, by integration. Now that we know that the probability of two independet chords intersecting, we can consider possible pizza-slice configurations. If no chords intersect, then we have a pizza with four slices, and if all three chords intersect, then we have a pizza with siven slices. Note how the number of slices is equal to four plus the number of intersections. Just for illustration, I’ve used Paper by 53 to draw out some possible configurations of pizza slices, given the number of intersections. Now, let’s denote the number of cuts in the order they are made as $A$, $B$, and $C$. Skipping to the third cut $C$, let’s calculate the four different possibilities for $C$ intersecting with $A$ only, $B$ only, both $A$ and $B$, or neither $A$ nor $B$.

Possible Intersections with $C$Probability of Configuration
$AC$, $\neg BC$$\frac{1}{3} \times \frac{2}{3} \approx 0.22$
$BC$, $\neg AC$$\frac{1}{3} \times \frac{2}{3} \approx 0.22$
$AC$, $AB$$\frac{1}{3} \times \frac{1}{3} \approx 0.11$
$\neg AC$, $\neg AB$$\frac{2}{3} \times \frac{3}{3} \approx 0.44$

By the linearity of expectation, and because cuts are independent, we can then mutiply each probability in the above table by the probability of an $AB$ intersection ($\frac{1}{3}$), or non-intersection ($\frac{2}{3}$), to obtain the $2^3 = 8$ possible combinations of cuts and intersections.

Third Chord$AB$$\neg AB$
$AC$, $\neg BC$$\frac{1}{3} \times \frac{2}{3} \times \frac{1}{3} \approx 0.07$$\frac{1}{3} \times \frac{2}{3} \times \frac{2}{3} \approx 0.15$
$BC$, $\neg AC$$\frac{1}{3} \times \frac{2}{3} \times \frac{1}{3}\approx 0.07$$\frac{1}{3} \times \frac{2}{3} \times \frac{2}{3}\approx 0.15$
$AC$, $AB$$\frac{1}{3} \times \frac{1}{3}\times \frac{1}{3} \approx 0.04$$\frac{1}{3} \times \frac{1}{3}\times \frac{2}{3} \approx 0.07$
$\neg AC$, $\neg AB$$\frac{2}{3} \times \frac{3}{3}\times \frac{1}{3} \approx 0.15$$\frac{2}{3} \times \frac{3}{3}\times \frac{2}{3} \approx 0.30$

From here we can see that there is 1 way to obtain 0 intersections and 4 slices with probability 0.30; 3 ways to to obtain 1 intersection and 5 slices with probability 0.15 each; 3 ways to obtain 2 intersections and 6 slices with probability 0.07 each; and 1 way to obtain 3 intersections with 7 slices with probability 0.04.

In conclustion, and again by the linearity of expectation, we can then expect 5 slices:

Over repeated pizzas, we would therefore expect about 30% to have 4 slices; 44% to have 5 slices; 22% to have 6 slices; and 4% to have 7 slices.

PROBABILITY · EXPECTATION · ROBOTS
riddler