Levmore–Cook moving-knives procedure

The Levmore–Cook moving-knives procedure is a procedure for envy-free cake-cutting among three partners. It is named after Saul X. Levmore and Elizabeth Early Cook who presented it in 1981. It assumes that the cake is two-dimensional. It requires a referee, two knives and four cuts, so some partners may receive disconnected pieces.

Procedure
We name the partners Alice, Bob and Carl.

Initially, Alice cuts the cake to three pieces equal in her eyes. Bob and Carl each point to their favorite piece.

Easy case: Bob and Carl point to different pieces. Each receives his favorite piece and Alice the remaining piece.

Hard case: Bob and Carl point to the same piece. Say this is piece X and the other pieces are Y and Z. Now the referee (ideally it could be Alice) takes one knife and moves it horizontally over piece X, and Alice takes the other knife and moves it vertically over piece X:
 * Knife #1 is moved horizontally and continuously by the referee from the left of piece X to its right. It divides piece X to two pieces: the left piece XL and the right piece XR.
 * Knife #2 is moved vertically and simultaneously by Alice, to the left of Knife #1, such that XL is divided to two equal pieces in her eyes: the left-top XLT and the left-bottom XLB.

Initially XR=X, so for Bob and Carl it is bigger than Y and Z. Moreover, Initially XLT and XLB are empty so XR is bigger than the two pairs: Y+XLT and Z+XLB.

As Knife #1 moves rightwards, XR shrinks while XLT and XLB grows. At some point, either Bob or Carl thinks that XR equals one of the two pairs. The first one that thinks there is equality, shouts "stop!" and receives his chosen pair, either Y+XLT or Z+XLB. Alice receives the other pair, and the non-shouter receives XR.

Analysis
We analyze the case when Bob shouted "stop!" and picked the pair Y+XLT. Alice gets Z+XLB and Carl gets XR. The division is envy-free because:
 * For Alice, Z>X>XR so Alice does not envy Carl. Moreover, Z=Y and XLB=XLT so Alice does not envy Bob.
 * For Bob, Y+XLT=XR>Z+XLB, so Bob does not envy.
 * For Carl, XR is larger than both pairs (since he did not shout) so he does not envy.

The other cases are analogous.

Variants
It is possible to let the shouter choose one of the four pairs: Y+XLT, Y+XLB, Z+XLT, Z+XLB. This modification favors the non-shouter, since the shouter will typically shout "stop" sooner.

Levmore and Cook presented a generalization of their procedure for 4 partners. However, it was later shown that this generalization does not work in all cases.