In September 16, 2011, an anime fan posted a math question to the online bulletin board 4chan about the cult classic television series The Melancholy of Haruhi Suzumiya. Season one of the show, which involves time travel, had originally aired in nonchronological order, and a re-broadcast and a DVD version had each further rearranged the episodes. Fans were arguing online about the best order to watch the episodes, and the 4chan poster wondered: If viewers wanted to see the series in every possible order, what is the shortest list of episodes they’d have to watch?

In less than an hour, an anonymous person offered an answer — not a complete solution, but a lower bound on the number of episodes required. The argument, which covered series with any number of episodes, showed that for the 14-episode first season of Haruhi, viewers would have to watch at least 93,884,313,611 episodes to see all possible orderings. “Please look over [the proof] for any loopholes I might have missed,” the anonymous poster wrote.

The proof slipped under the radar of the mathematics community for seven years — apparently only one professional mathematician spotted it at the time, and he didn’t check it carefully. But in a plot twist last month, the Australian science fiction novelist Greg Egan proved a new upper bound on the number of episodes required. Egan’s discovery renewed interest in the problem and drew attention to the lower bound posted anonymously in 2011. Both proofs are now being hailed as significant advances on a puzzle mathematicians have been studying for at least 25 years.

Mathematicians quickly verified Egan’s upper bound, which, like the lower bound, applies to series of any length. Then Robin Houston, a mathematician at the data visualization firm Kiln, and Jay Pantone of Marquette University in Milwaukee independently verified the work of the anonymous 4chan poster. “It took a lot of work to try to figure out whether or not it was correct,” Pantone said, since the key ideas hadn’t been expressed particularly clearly.

Now, Houston and Pantone, joined by Vince Vatter of the University of Florida in Gainesville, have written up the formal argument. In their paper, they list the first author as “Anonymous 4chan Poster.”

Permutation Cities

If a television series has just three episodes, there are six possible orders in which to view them: 123, 132, 213, 231, 312 and 321. You could string these six sequences together to give a list of 18 episodes that includes every ordering, but there’s a much more efficient way to do it: 123121321. A sequence like this one that contains every possible rearrangement (or permutation) of a collection of n symbols is called a “superpermutation.”

In 1993, Daniel Ashlock and Jenett Tillotson observed that if you look at the shortest superpermutations for different values of n, a pattern quickly seems to emerge involving factorials — those numbers, written in the form n!, that involve multiplying together all the numbers up to n (for example, 4! = 4 × 3 × 2 × 1).

If your series has just one episode, the shortest superpermutation has length 1! (also known as plain old 1). For a two-episode series, the shortest superpermutation (121) has length 2! + 1!. For three episodes (the example we looked at above), the length works out to 3! + 2! + 1!, and for four episodes (123412314231243121342132413214321), it is 4! + 3! + 2! + 1!. The factorial rule for superpermutations became conventional wisdom (even though no one could prove it was true for every value of n), and mathematicians later confirmed it for n = 5.