**Reference**:- MIT Hardness Group, Josh Brunner, Lily Chung, Erik D. Demaine, Della Hendrickson, and Andy Tockman, “ASP-Completeness of Hamiltonicity in Grid Graphs, with Applications to Loop Puzzles”, in
*Proceedings of the 12th International Conference on Fun with Algorithms (FUN 2024)*, edited by Andrei Z. Broder and Tami Tamir, LIPIcs, volume 291, La Maddalena, Italy, June 4–8, 2024, 23:1–23:20. **Abstract**:-
We prove that Hamiltonicity in maximum-degree-3 grid graphs (directed or
undirected) is ASP-complete, i.e., it has a parsimonious reduction from every
NP search problem (including a polynomial-time bijection between solutions).
As a consequence, given
*k*Hamiltonian cycles, it is NP-complete to find another; and counting Hamiltonian cycles is #P-complete. If we require the grid graph's vertices to form a full*m*×*n*rectangle, then we show that Hamiltonicity remains ASP-complete if the edges are directed or if we allow removing some edges (whereas including all undirected edges is known to be easy). These results enable us to develop a stronger “T-metacell” framework for proving ASP-completeness of rectangular puzzles, which requires building just a single gadget representing a degree-3 grid-graph vertex. We apply this general theory to prove ASP-completeness of 37 pencil-and-paper puzzles where the goal is to draw a loop subject to given constraints: Slalom, Onsen-meguri, Mejilink, Detour, Tapa-Like Loop, Kouchoku, Icelom; Masyu, Yajilin, Nagareru, Castle Wall, Moon or Sun, Country Road, Geradeweg, Maxi Loop, Mid-loop, Balance Loop, Simple Loop, Haisu, Reflect Link, Linesweeper; Vertex/Touch Slitherlink, Dotchi-Loop, Ovotovata, Building Walk, Rail Pool, Disorderly Loop, Ant Mill, Koburin, Mukkonn Enn, Rassi Silai, (Crossing) Ichimaga, Tapa, Canal View, and Aqre. The last 13 of these puzzles were not even known to be NP-hard. Along the way, we prove ASP-completeness of some simple forms of Tree-Residue Vertex-Breaking (TRVB), including planar multigraphs with degree-6 breakable vertices, or with degree-4 breakable and degree-1 unbreakable vertices. **Comments**:- This paper is also available from LIPIcs and as arXiv:2405.08377.
**Length**:- The paper is 20 pages.
**Availability**:- The paper is available in PDF (897k).
- See information on file formats.
- [Google Scholar search]

See also other papers by Erik Demaine.

Last updated July 23, 2024 by Erik Demaine.