Skip to main content

Solving Rubik’s Cube Using Graph Theory

  • Conference paper
  • First Online:
  • 1059 Accesses

Part of the book series: Advances in Intelligent Systems and Computing ((AISC,volume 798))

Abstract

The most common application of graph theory is search problems. Using graph theory, this project aims to solve one such NP-hard problem, i.e., finding a path for a Rubik’s cube to reach the solved state from a scrambled one. Rubik’s cube is among one of the fascinating puzzles and solving them has been a challenge given its vast search space of 43 quintillion. This paper aims at demonstrating the application and performance of traditional search algorithms like breadth-first search, depth-limited search, and bidirectional search, and proposes a new approach to find the solution by integrating them. The proposed algorithm makes use of the fact that the God’s number for a 3\(\times \)3\(\times \)3 Rubik’s cube is 20, i.e., the fact that any cube scramble within the 43 quintillion states can be solved within a max of 20 moves.

This is a preview of subscription content, log in via an institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   169.00
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   219.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

References

  1. Van Grol, R.: The quest for gods number. Math Horiz. 18(2), 10–13 (2010)

    Article  Google Scholar 

  2. Rokicki, T.: Twenty-two moves suffice for rubik’s cube. Mathem. Intelligencer 32(1), 33–40 (2010)

    Article  MathSciNet  Google Scholar 

  3. Gymrek, M., Li, J.: The mathematics of the Rubiks cube. http://web.mit.edu/sp.268/www/rubik.pdf (2009)

  4. Rokicki, T.: Twenty-five moves suffice for Rubik’s cube. arXiv preprint arXiv:0803.3435 (2008)

  5. Rokicki, T., Kociemba, H., Davidson, M., Dethridge, J.: The diameter of the Rubik’s cube group is twenty. SIAM Rev. 56(4), 645–670 (2014)

    Article  MathSciNet  Google Scholar 

  6. Betsch, G.: Adventures in group theory: Rubiks cube, Merlins machine, & other mathematical toys. Mathem. Intelligencer 27(2), 92–92 (2005)

    Article  Google Scholar 

  7. Amdahl, G.M.: Validity of the single processor approach to achieving large scale computing capabilities. In: Proceedings of the April 18–20, 1967, Spring Joint Computer Conference. AFIPS ’67 (Spring), pp. 483–485. ACM (1967)

    Google Scholar 

  8. Korf, R.E.: Finding optimal solutions to Rubik’s cube using pattern databases. In: Proceedings of the Fourteenth National Conference on Artificial Intelligence and Ninth Conference on Innovative Applications of Artificial Intelligence. AAAI’97/IAAI’97, pp. 700–705 (1997)

    Google Scholar 

  9. Rokicki, T., Kociemba, H., Davidson, M., Dethridge, J.: God’s number is 20. http://www.cube20.org

  10. Russel, S., Norvig, P.: Artificial Intelligence: A Modern Approach. Prentice Hall (2002)

    Google Scholar 

  11. Cormen, T.H., Leiserson, C.E., Rivest, R.L., Stein, C.: Introduction to Algorithms. Tata McGraw-Hill (2002)

    Google Scholar 

  12. Martin, M., Roth, A.: Performance and Benchmarking. https://www.cis.upenn.edu/~milom/cis501-Fall12/lectures/04_performance.pdf (2012)

Download references

Author information

Authors and Affiliations

Authors

Corresponding authors

Correspondence to Chanchal Khemani or Krapi Shah .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2019 Springer Nature Singapore Pte Ltd.

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Khemani, C., Doshi, J., Duseja, J., Shah, K., Udmale, S., Sambhe, V. (2019). Solving Rubik’s Cube Using Graph Theory. In: Verma, N., Ghosh, A. (eds) Computational Intelligence: Theories, Applications and Future Directions - Volume I. Advances in Intelligent Systems and Computing, vol 798. Springer, Singapore. https://doi.org/10.1007/978-981-13-1132-1_24

Download citation

Publish with us

Policies and ethics