Shortest Reconfiguration of Colorings Under Kempe Changes

Authors Marthe Bonamy, Marc Heinrich, Takehiro Ito , Yusuke Kobayashi, Haruka Mizuta, Moritz Mühlenthaler, Akira Suzuki , Kunihiro Wasa

Thumbnail PDF


  • Filesize: 0.68 MB
  • 14 pages

Document Identifiers

Author Details

Marthe Bonamy
  • CNRS, LaBRI, Université de Bordeaux, Talence, France
Marc Heinrich
  • Université Lyon 1, LIRIS, UMR5205, France
Takehiro Ito
  • Graduate School of Information Sciences, Tohoku University, Japan
Yusuke Kobayashi
  • Research Institute for Mathematical Sciences, Kyoto University, Japan
Haruka Mizuta
  • Graduate School of Information Sciences, Tohoku University, Japan
Moritz Mühlenthaler
  • Laboratoire G-SCOP, Grenoble INP, Université Grenoble Alpes, France
Akira Suzuki
  • Graduate School of Information Sciences, Tohoku University, Japan
Kunihiro Wasa
  • National Institute of Informatics, Tokyo, Japan


This work is partially supported by JSPS and MEAE-MESRI under the Japan-France Integrated Action Program (SAKURA).

Cite AsGet BibTex

Marthe Bonamy, Marc Heinrich, Takehiro Ito, Yusuke Kobayashi, Haruka Mizuta, Moritz Mühlenthaler, Akira Suzuki, and Kunihiro Wasa. Shortest Reconfiguration of Colorings Under Kempe Changes. In 37th International Symposium on Theoretical Aspects of Computer Science (STACS 2020). Leibniz International Proceedings in Informatics (LIPIcs), Volume 154, pp. 35:1-35:14, Schloss Dagstuhl – Leibniz-Zentrum für Informatik (2020)


A k-coloring of a graph maps each vertex of the graph to a color in {1, 2, …, k}, such that no two adjacent vertices receive the same color. Given a k-coloring of a graph, a Kempe change produces a new k-coloring by swapping the colors in a bicolored connected component. We investigate the complexity of finding the smallest number of Kempe changes needed to transform a given k-coloring into another given k-coloring. We show that this problem admits a polynomial-time dynamic programming algorithm on path graphs, which turns out to be highly non-trivial. Furthermore, the problem is NP-hard even on star graphs and we show that on such graphs it admits a constant-factor approximation algorithm and is fixed-parameter tractable when parameterized by the number k of colors. The hardness result as well as the algorithmic results are based on the notion of a canonical transformation.

Subject Classification

ACM Subject Classification
  • Mathematics of computing → Graph algorithms
  • Combinatorial Reconfiguration
  • Graph Algorithms
  • Graph Coloring
  • Kempe Equivalence


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


  1. Oswin Aichholzer, Wolfgang Mulzer, and Alexander Pilz. Flip distance between triangulations of a simple polygon is NP-complete. Discrete & computational geometry, 54(2):368-389, 2015. Google Scholar
  2. Marthe Bonamy, Nicolas Bousquet, Carl Feghali, and Matthew Johnson. On a conjecture of mohar concerning Kempe equivalence of regular graphs. Journal of Combinatorial Theory, Series B, 135:179-199, 2019. URL:
  3. Marthe Bonamy, Marc Heinrich, Takehiro Ito, Yusuke Kobayashi, Haruka Mizuta, Moritz Mühlenthaler, Akira Suzuki, and Kunihiro Wasa. Diameter of colorings under kempe changes. In Computing and Combinatorics - 25th International Conference, COCOON 2019, Proceedings, pages 52-64, 2019. URL:
  4. douard Bonnet, Tillmann Miltzow, and Paweł Rzążewski. Complexity of token swapping and its variants. Algorithmica, 80(9):2656-2682, 2018. Google Scholar
  5. Paul Bonsma and Luis Cereceda. Finding Paths Between Graph Colourings: PSPACE-Completeness and Superpolynomial Distances. In MFCS, volume 4708 of Lecture Notes in Computer Science, pages 738-749, 2007. Google Scholar
  6. Nicolas Bousquet and Marc Heinrich. A polynomial version of cereceda’s conjecture, 2019. URL:
  7. Luis Cereceda, Jan van den Heuvel, and Matthew Johnson. Finding paths between 3-colorings. Journal of Graph Theory, 67(1):69-82, 2011. Google Scholar
  8. Sitan Chen, Michelle Delcourt, Ankur Moitra, Guillem Perarnau, and Luke Postle. Improved bounds for randomly sampling colorings via linear programming. In Proceedings of the Thirtieth Annual ACM-SIAM Symposium on Discrete Algorithms, pages 2216-2234. SIAM, 2019. Google Scholar
  9. Erik D Demaine, Sarah Eisenstat, and Mikhail Rudoy. Solving the rubik’s cube optimally is NP-complete. In 35th Symposium on Theoretical Aspects of Computer Science, 2018. Google Scholar
  10. Carl Feghali, Matthew Johnson, and Daniël Paulusma. Kempe equivalence of colourings of cubic graphs. European Journal of Combinatorics, 59:1-10, 2017. Google Scholar
  11. M. Garey, D. Johnson, and R. Tarjan. The planar Hamiltonian circuit problem is NP-complete. SIAM Journal on Computing, 5(4):704-714, 1976. URL:
  12. Oded Goldreich. Finding the shortest move-sequence in the graph-generalized 15-puzzle is NP-hard. In Studies in Complexity and Cryptography. Miscellanea on the Interplay between Randomness and Computation, pages 1-5. Springer, 2011. Google Scholar
  13. Jan van den Heuvel. The complexity of change. In Simon R. Blackburn, Stefanie Gerke, and Mark Wildon, editors, Surveys in Combinatorics 2013, pages 127-160. Cambridge University Press, 2013. Google Scholar
  14. Matthew Johnson, Dieter Kratsch, Stefan Kratsch, Viresh Patel, and Daniël Paulusma. Finding shortest paths between graph colourings. Algorithmica, 75(2):295-321, 2016. Google Scholar
  15. Michel Las Vergnas and Henri Meyniel. Kempe classes and the Hadwiger Conjecture. Journal of Combinatorial Theory, Series B, 31(1):95-104, 1981. URL:
  16. Anna Lubiw and Vinayak Pathak. Flip distance between two triangulations of a point set is NP-complete. Computational Geometry, 49:17-23, 2015. Google Scholar
  17. Henry Meyniel. Les 5-colorations d'un graphe planaire forment une classe de commutation unique. Journal of Combinatorial Theory, Series B, 24(3):251-257, 1978. URL:
  18. Tillmann Miltzow, Lothar Narins, Yoshio Okamoto, Günter Rote, Antonis Thomas, and Takeaki Uno. Approximation and Hardness of Token Swapping. In Piotr Sankowski and Christos Zaroliagis, editors, 24th Annual European Symposium on Algorithms (ESA 2016), volume 57 of Leibniz International Proceedings in Informatics (LIPIcs), pages 66:1-66:15. Schloss Dagstuhl-Leibniz-Zentrum fuer Informatik, 2016. URL:
  19. Bojan Mohar. Kempe equivalence of colorings. In Adrian Bondy, Jean Fonlupt, Jean-Luc Fouquet, Jean-Claude Fournier, and Jorge L. Ramírez Alfonsín, editors, Graph Theory in Paris, Trends in Mathematics, pages 287-297. Birkhäuser Basel, 2007. URL:
  20. Bojan Mohar and Jesús Salas. A new Kempe invariant and the (non)-ergodicity of the Wang-Swendsen-Koteckỳ algorithm. Journal of Physics A: Mathematical and Theoretical, 42(22):225204, 2009. Google Scholar
  21. Bojan Mohar and Jesús Salas. On the non-ergodicity of the swendsen-wang-koteckỳ algorithm on the kagomé lattice. Journal of Statistical Mechanics: Theory and Experiment, 2010(05):P05016, 2010. Google Scholar
  22. Amer E Mouawad, Naomi Nishimura, Vinayak Pathak, and Venkatesh Raman. Shortest reconfiguration paths in the solution space of boolean formulas. SIAM Journal on Discrete Mathematics, 31(3):2185-2200, 2017. Google Scholar
  23. Naomi Nishimura. Introduction to reconfiguration. Algorithms, 11(4:52), 2018. Google Scholar
  24. Daniel Ratner and Manfred K Warmuth. Finding a shortest solution for the n× n extension of the 15-puzzle is intractable. In AAAI, pages 168-172, 1986. Google Scholar
  25. Eric Vigoda. Improved bounds for sampling colorings. Journal of Mathematical Physics, 41(3):1555-1569, 2000. Google Scholar
  26. Katsuhisa Yamanaka, Erik D. Demaine, Takashi Horiyama, Akitoshi Kawamura, Shin-ichi Nakano, Yoshio Okamoto, Toshiki Saitoh, Akira Suzuki, Ryuhei Uehara, and Takeaki Uno. Sequentially swapping colored tokens on graphs. Journal of Graph Algorithms and Applications, 23(1):3-27, 2019. URL:
  27. Katsuhisa Yamanaka, Takashi Horiyama, David Kirkpatrick, Yota Otachi, Toshiki Saitoh, Ryuhei Uehara, and Yushi Uno. Swapping colored tokens on graphs. In Workshop on Algorithms and Data Structures, pages 619-628. Springer, 2015. Google Scholar