Skip to main content
Log in

The density function of the number of moves to complete the Towers of Hanoi puzzle

  • Published:
Annals of Operations Research Aims and scope Submit manuscript

Abstract

Any sequence of legal moves leads the Towers of Hanoi puzzle to an arrangement from which the final configuration must be built up. A recursive algorithm which finishes off the puzzle is considered and, assuming a uniform distribution on the possible unfinished situations, the density function of the number of moves it takes is derived.

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

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

References

  1. M.D. Atkinson, The cyclic towers of Hanoi, Inf. Proc. Lett. 13, 3 (1981)118.

    Google Scholar 

  2. R.R.W. Ball, Mathematical Recreations and Essays (McMillan, London, 1892).

    Google Scholar 

  3. P. Buneman and L. Levy, The towers of Hanoi problem, Inf. Proc. Lett. 10, 4 (1980)243.

    Google Scholar 

  4. R.W. Floyd and R.L. Rivest, Expected time bounds for selection, Commun. ACM 18, 3 (1975)165.

    Google Scholar 

  5. P.J. Hayes, A note on the towers of Hanoi problem, Comput J. 20(1977)282.

    Google Scholar 

  6. R.M. Karp, The probabilistic analysis of some combinatorial search algorithms, in: Algorithms and Complexity: New Directions and Recent Results, ed. J.F. Traub (Academic Press, New York, 1976) p. 1.

    Google Scholar 

  7. R.M. Karp, Probabilistic analysis of partitioning algorithms for the Traveling Salesman problem in the plane, Maths. Oper. Res. 2(1977)209.

    Google Scholar 

  8. F. Scarioni and M.G. Speranza, Probabilistic analysis of an error-correcting algorithm for the Towers of Hanoi puzzle, Inf. Proc. Lett. 18, 2 (1984)99.

    Google Scholar 

  9. R. Sedgewick, The analysis of Quicksort programs, Acta Inf. 7, 4 (1977)327.

    Google Scholar 

  10. P.M. Spira, A new algorithm for finding all shortest paths in a graph of positive arcs in average time o(n logn), SIAM J. Comput. 2, 1 (1973)28.

    Google Scholar 

  11. T.R. Walsh, The towers of Hanoi revisited: moving the rings by counting the moves. Inf. Proc. Lett. 15, 2 (1982)64.

    Google Scholar 

  12. T.R. Walsh, Iteration strikes back (at the cyclic Towers of Hanoi), Inf. Proc. Lett. 16, 2 (1983)91.

    Google Scholar 

  13. T.R. Walsh, A case for iteration, to appear in: Congressus Numerantium.

  14. D. Wood, The Towers of Brahma and Hanoi revisited, J. of Recreational Math. 14(1981)17.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

About this article

Cite this article

Scarioni, F., Speranza, M.G. The density function of the number of moves to complete the Towers of Hanoi puzzle. Ann Oper Res 1, 291–303 (1984). https://doi.org/10.1007/BF01874394

Download citation

  • Issue Date:

  • DOI: https://doi.org/10.1007/BF01874394

Keywords and phrases

Navigation