English

Bouncing Towers move faster than Hanoi Towers, but still require exponential time

General Literature 2016-03-14 v2

Abstract

The problem of the Hanoi Tower is a classic exercise in recursive programming: the solution has a simple recursive definition, and its complexity and the matching lower bound are the solution of a simple recursive function (the solution is so easy that most students memorize it and regurgitate it at exams without truly understanding it). We describe how some very minor changes in the rules of the Hanoi Tower yield various increases of complexity in the solution, so that they require a deeper analysis than the classical Hanoi Tower problem while still yielding exponential solutions. In particular, we analyze the problem fo the Bouncing Tower, where just changing the insertion and extraction position from the top to the middle of the tower results in a surprising increase of complexity in the solution: such a tower of nn disks can be optimally moved in 3n\sqrt{3}^n moves for nn even (i.e. less than a Hanoi Tower of same height), via 55 recursive functions (or, equivalently, one recursion function with 55 states).

Keywords

Cite

@article{arxiv.1602.03934,
  title  = {Bouncing Towers move faster than Hanoi Towers, but still require exponential time},
  author = {Jérémy Barbay},
  journal= {arXiv preprint arXiv:1602.03934},
  year   = {2016}
}

Comments

18 pages and many figures, one appendix with the disk pile problem, code in Python