Computational Complexity of Motion Planning of a Robot through Simple Gadgets

Authors Erik D. Demaine, Isaac Grosof, Jayson Lynch, Mikhail Rudoy

Thumbnail PDF


  • Filesize: 0.54 MB
  • 21 pages

Document Identifiers

Author Details

Erik D. Demaine
  • MIT CSAIL, 32 Vassar Street, Cambridge, MA 02139, USA
Isaac Grosof
  • MIT CSAIL, 32 Vassar Street, Cambridge, MA 02139, USA
Jayson Lynch
  • MIT CSAIL, 32 Vassar Street, Cambridge, MA 02139, USA
Mikhail Rudoy
  • MIT CSAIL, 32 Vassar Street, Cambridge, MA 02139, USA

Cite AsGet BibTex

Erik D. Demaine, Isaac Grosof, Jayson Lynch, and Mikhail Rudoy. Computational Complexity of Motion Planning of a Robot through Simple Gadgets. In 9th International Conference on Fun with Algorithms (FUN 2018). Leibniz International Proceedings in Informatics (LIPIcs), Volume 100, pp. 18:1-18:21, Schloss Dagstuhl – Leibniz-Zentrum für Informatik (2018)


We initiate a general theory for analyzing the complexity of motion planning of a single robot through a graph of "gadgets", each with their own state, set of locations, and allowed traversals between locations that can depend on and change the state. This type of setup is common to many robot motion planning hardness proofs. We characterize the complexity for a natural simple case: each gadget connects up to four locations in a perfect matching (but each direction can be traversable or not in the current state), has one or two states, every gadget traversal is immediately undoable, and that gadget locations are connected by an always-traversable forest, possibly restricted to avoid crossings in the plane. Specifically, we show that any single nontrivial four-location two-state gadget type is enough for motion planning to become PSPACE-complete, while any set of simpler gadgets (effectively two-location or one-state) has a polynomial-time motion planning algorithm. As a sample application, our results show that motion planning games with "spinners" are PSPACE-complete, establishing a new hard aspect of Zelda: Oracle of Seasons.

Subject Classification

ACM Subject Classification
  • Theory of computation → Problems, reductions and completeness
  • hardness
  • motion planning
  • puzzles


  • Access Statistics
  • Total Accesses (updated on a weekly basis)
    PDF Downloads


  1. Greg Aloupis, Erik D. Demaine, Alan Guo, and Giovanni Viglietta. Classic Nintendo games are (computationally) hard. Theoretical Computer Science, 586:135-160, 2015. Originally at FUN 2014. Google Scholar
  2. Hubert de Fraysseix, János Pach, and Richard Pollack. How to draw a planar graph on a grid. Combinatorica, 10(1):41-51, 1990. URL:
  3. Erik D. Demaine, Martin L. Demaine, Michael Hoffmann, and Joseph O'Rourke. Pushing blocks is hard. Computational Geometry: Theory and Applications, 26(1):21-36, August 2003. Google Scholar
  4. Erik D. Demaine, Isaac Grosof, and Jayson Lynch. Push-pull block puzzles are hard. In Dimitris Fotakis, Aris Pagourtzis, and Vangelis Th. Paschos, editors, Algorithms and Complexity - 10th International Conference, CIAC 2017, Athens, Greece, May 24-26, 2017, Proceedings, volume 10236 of Lecture Notes in Computer Science, pages 177-195, 2017. URL:
  5. Erik D. Demaine, Robert A. Hearn, and Michael Hoffmann. Push-2-f is pspace-complete. In Proceedings of the 14th Canadian Conference on Computational Geometry, pages 31-35, Lethbridge, Alberta, Canada, August 12-14 2002. Google Scholar
  6. Erik D. Demaine, Giovanni Viglietta, and Aaron Williams. Super Mario Bros. is harder/easier than we thought. In Proceedings of the 8th International Conference on Fun with Algorithms, pages 13:1-13:14, La Maddalena, Italy, June 8-10 2016. Google Scholar
  7. Michael R. Garey and David S. Johnson. Computers and Intractability: A Guide to the Theory of NP-Completeness. W. H. Freeman &Co., New York, NY, USA, 1979. Google Scholar
  8. Robert A. Hearn and Erik D. Demaine. Games, Puzzles, and Computation. A. K. Peters, Ltd., Natick, MA, USA, 2009. Google Scholar
  9. André Grahl Pereira, Marcus Ritt, and Luciana S. Buriol. Pull and pushpull are pspace-complete. Theor. Comput. Sci., 628:50-61, 2016. URL:
  10. Walter J. Savitch. Relationships between nondeterministic and deterministic tape complexities. J. Comput. Syst. Sci., 4(2):177-192, 1970. URL:
  11. Thomas J. Schaefer. The complexity of satisfiability problems. In Proceedings of the 10th Annual ACM Symposium on Theory of Computing, pages 216-226, San Diego, California, May 1978. Google Scholar
Questions / Remarks / Feedback

Feedback for Dagstuhl Publishing

Thanks for your feedback!

Feedback submitted

Could not send message

Please try again later or send an E-mail