Table of Contents
Fetching ...

On The Optimal General Solution To The Multi-Peg Tower of Hanoi

Abhiram Menon

TL;DR

This work derives a unified closed-form for the Frame–Stewart numbers $M(p,n)$ by parameterizing the regime with the index $i(p,n)$, determined via simplex boundaries $B_p(i)$, giving $M(p,n)=2^{i(p,n)+1}n- extstyleigl( extstyleigl)S_p(i(p,n))$ where $S_p(i)=\sum_{k=0}^i 2^k \binom{p+k-2}{k}$. It then proves Frame–Stewart optimality in the first two regimes: Regime 1 with $p-1<n\le\binom{p}{2}$ yields $M(p,n)=4n-2p+1$, and Regime 2 with $\binom{p}{2}<n\le\binom{p+1}{3}$ yields $M(p,n)=8n-2p^2+1$, using phase-based charging and capacity bounds. These results cover infinitely many $(p,n)$ pairs (up to the tetrahedral boundary) and provide efficient $O(p\log n)$ evaluation of $M(p,n)$. The paper also outlines a coherent plan to extend to Regime 3 and beyond, through higher-layer charging arguments and corresponding capacity analyses, offering a structured path toward resolving the conjecture more broadly.

Abstract

We derive a unified closed-form expression for the Frame-Stewart algorithm in the multi-peg Tower of Hanoi: M(p,n) = 2^(i(p,n)+1)*n - sum_{k=0}^{i(p,n)} 2^k * C(p+k-2, k), where i(p,n) = min{ j >= 0 : n <= C(p-1+j, j+1) }. and prove it satisfies the Frame-Stewart recurrence for all (p,n) via double induction using discrete slope analysis with simplex boundaries. It shows that M(p,n) grows linearly within each regime, with slopes doubling at successive boundaries. We also prove Frame-Stewart optimality for the first two regimes indexed by i: for p-1 < n <= C(p,2), M(p,n) = 4n - 2p + 1; for C(p,2) < n <= C(p+1,3), M(p,n) = 8n - 2p^2 + 1. These results give optimality proofs for infinitely many (p,n) pairs beyond trivial cases, settling the conjecture up to n <= C(p+1,3).

On The Optimal General Solution To The Multi-Peg Tower of Hanoi

TL;DR

This work derives a unified closed-form for the Frame–Stewart numbers by parameterizing the regime with the index , determined via simplex boundaries , giving where . It then proves Frame–Stewart optimality in the first two regimes: Regime 1 with yields , and Regime 2 with yields , using phase-based charging and capacity bounds. These results cover infinitely many pairs (up to the tetrahedral boundary) and provide efficient evaluation of . The paper also outlines a coherent plan to extend to Regime 3 and beyond, through higher-layer charging arguments and corresponding capacity analyses, offering a structured path toward resolving the conjecture more broadly.

Abstract

We derive a unified closed-form expression for the Frame-Stewart algorithm in the multi-peg Tower of Hanoi: M(p,n) = 2^(i(p,n)+1)*n - sum_{k=0}^{i(p,n)} 2^k * C(p+k-2, k), where i(p,n) = min{ j >= 0 : n <= C(p-1+j, j+1) }. and prove it satisfies the Frame-Stewart recurrence for all (p,n) via double induction using discrete slope analysis with simplex boundaries. It shows that M(p,n) grows linearly within each regime, with slopes doubling at successive boundaries. We also prove Frame-Stewart optimality for the first two regimes indexed by i: for p-1 < n <= C(p,2), M(p,n) = 4n - 2p + 1; for C(p,2) < n <= C(p+1,3), M(p,n) = 8n - 2p^2 + 1. These results give optimality proofs for infinitely many (p,n) pairs beyond trivial cases, settling the conjecture up to n <= C(p+1,3).
Paper Structure (26 sections, 25 theorems, 52 equations)

This paper contains 26 sections, 25 theorems, 52 equations.

Key Result

Lemma 1

If $i = i(p,n)$, then for every $n$, including the boundary points $n = B_p(i)$.

Theorems & Definitions (57)

  • Definition 1: Tower of Hanoi
  • Definition 2: Frame--Stewart Algorithm
  • Lemma 1: Discrete slope law
  • proof
  • Lemma 2: Binomial recursion
  • proof
  • Theorem 3: Equivalence with Frame--Stewart
  • proof
  • Lemma 4
  • proof
  • ...and 47 more