cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-2 of 2 results.

A183119 Magnetic Tower of Hanoi, total number of moves generated by a certain algorithm, yielding a "forward moving" non-optimal solution of the [RED ; NEUTRAL ; BLUE] pre-colored puzzle.

Original entry on oeis.org

0, 1, 4, 11, 32, 93, 276, 823, 2464, 7385, 22148, 66435, 199296, 597877, 1793620, 5380847, 16142528, 48427569, 145282692, 435848059, 1307544160, 3922632461, 11767897364, 35303692071, 105911076192, 317733228553, 953199685636, 2859599056883, 8578797170624, 25736391511845
Offset: 0

Views

Author

Uri Levy, Jan 03 2011

Keywords

Comments

The Magnetic Tower of Hanoi puzzle is described in link 1 listed below. The Magnetic Tower is pre-colored. Pre-coloring is [RED ; NEUTRAL ; BLUE], given in [Source ; Intermediate ; Destination] order. The solution algorithm producing the presented sequence is NOT optimal. The particular "75" algorithm solving the puzzle at hand is presented in a paper referenced by link 1 listed below. For the optimal solution of the Magnetic Tower of Hanoi puzzle with the given pre-coloring configuration see A183113 and A183114. Optimal solutions are discussed and their optimality is proved in link 2 listed below.
Large N limit of the sequence is 0.5*(3/4)*3^N = 0.5*0.75*3^N. Series designation: S75(n).

References

  • Uri Levy, The Magnetic Tower of Hanoi, Journal of Recreational Mathematics, Volume 35 Number 3 (2006), 2010, pp 173.

Crossrefs

A122983 - "Binomial transform of aeration of A081294" is an "original" sequence (also) describing the number of moves of disk number k, solving the pre-colored puzzle at hand when executing the "75" algorithm mentioned above and presented in the paper referenced by link 1 above. The integer sequence listed above is the partial sums of the A122983 original sequence.
A003462 "Partial sums of A000244" is the sequence (also) describing the total number of moves solving [RED ; BLUE ; BLUE] or [RED ; RED ; BLUE] pre-colored Magnetic Tower of Hanoi puzzle.

Programs

  • Magma
    [3^(n+1)/8+(n-1)/2+(-1)^n/8: n in [0..30]]; // Vincenzo Librandi, Dec 04 2018
  • Maple
    seq(coeff(series(x*(3*x^2-1)/((1+x)*(3*x-1)*(x-1)^2),x,n+1), x, n), n = 0 .. 30); # Muniru A Asiru, Dec 04 2018
  • Mathematica
    LinearRecurrence[{4, -2, -4, 3}, {0, 1, 4, 11}, 30] (* Jean-François Alcover, Dec 04 2018 *)
    Table[3^(n + 1) / 8 + (n - 1) / 2 + (-1)^n / 8, {n, 0, 30}] (* Vincenzo Librandi, Dec 04 2018 *)
  • PARI
    a(n) = 3^(n+1)/8 + (n-1)/2 + (-1)^n/8 \\ Charles R Greathouse IV, Jun 11 2015
    

Formula

G.f.: x*(-1+3*x^2) / ( (1+x)*(3*x-1)*(x-1)^2 ).
(a(n)=S75(n) in referenced paper):
a(n) = 3*a(n-1) - n + 3; n even; n >= 2
a(n) = 3*a(n-1) - n + 2; n odd; n >= 1
a(n) = a(n-2) + 3^(n-1) + 1; n >= 2
a(n) = 3^(n+1)/8 + (n-1)/2 +(-1)^n/8.

Extensions

More terms from Jean-François Alcover, Dec 04 2018

A183114 Magnetic Tower of Hanoi, total number of moves, optimally solving the [RED ; NEUTRAL ; BLUE] pre-colored puzzle.

Original entry on oeis.org

0, 1, 4, 11, 32, 93, 272, 807, 2404, 7185, 21516, 64483, 193352, 579909, 1739496, 5218143, 15653900, 46960889, 140881444, 422642459, 1267924528, 3803769261, 11411301184, 34233893527, 102701665332, 308104972769, 924314883004, 2772944595283, 8318833704088, 24956500987925
Offset: 0

Views

Author

Uri Levy, Dec 29 2010

Keywords

Comments

The Magnetic Tower of Hanoi puzzle is described in link 1 listed below. The Magnetic Tower is pre-colored. Pre-coloring is [RED ; NEUTRAL ; BLUE], given in [Source ; Intermediate ; Destination] order. The solution algorithm producing the sequence is optimal (the sequence presented gives the minimum number of moves to solve the puzzle for the given pre-coloring configuration). Optimal solutions are discussed and their optimality is proved in link 2 listed below.
Number of moves to solve the given puzzle, for large N, is close to 0.5*(8/11)*3^N ~ 0.5*0.727*3^(N). Series designation: S727(N).

References

  • U. Levy, The Magnetic Tower of Hanoi, Journal of Recreational Mathematics, Volume 35 Number 3 (2006), 2010, pp 173.

Crossrefs

A183113 is an "original" sequence describing the number of moves of disk number k, optimally solving the pre-colored puzzle at hand. The integer sequence listed above is the partial sums of the A183113 original sequence.
A003462 "Partial sums of A000244" is the sequence (also) describing the total number of moves solving [RED ; BLUE ; BLUE] or [RED ; RED ; BLUE] pre-colored Magnetic Tower of Hanoi puzzle.

Programs

  • Magma
    I:=[0,1,4,11,32]; [n le 5 select I[n] else 4*Self(n-1)-2*Self(n-2)-2*Self(n-3)-5*Self(n-4)+6*Self(n-5): n in [1..30]]; // Vincenzo Librandi, Dec 04 2018
  • Maple
    seq(coeff(series(x*(2*x-1)*(1+x)^2/((x-1)*(3*x-1)*(2*x^3+x^2-1)),x,n+1), x, n), n = 0 .. 35); # Muniru A Asiru, Dec 04 2018
  • Mathematica
    LinearRecurrence[{4, -2, -2, -5, 6}, {0, 1, 4, 11, 32}, 30] (* Jean-François Alcover, Dec 04 2018 *)
    CoefficientList[Series[x (2 x - 1) (1 + x)^2 / ((x - 1) (3 x - 1) (2 x^3 + x^2 - 1)), {x, 0, 33}], x] (* Vincenzo Librandi, Dec 04 2018 *)

Formula

G.f.: x*(2*x-1)*(1+x)^2 / ( (x-1)*(3*x-1)*(2*x^3+x^2-1) ).
Recurrence Relations (a(n)=S727(n) as in referenced paper):
a(N) = a(N-2) + 2*a(N-3) + 8*3^(N-3) + 2 ; N ≥ 3 ; S727(0) = 0
Closed-Form Expression:
Define:
λ1 = [1+sqrt(26/27)]^(1/3) + [1-sqrt(26/27)]^(1/3)
λ2 = -0.5* λ1 + 0.5*i*{[sqrt(27)+sqrt(26)]^(1/3)- [sqrt(27)-sqrt(26)]^(1/3)}
λ3 = -0.5* λ1 - 0.5*i*{[sqrt(27)+sqrt(26)]^(1/3)- [sqrt(27)-sqrt(26)]^(1/3)}
AS = [(7/11)* λ2* λ3 - (10/11)*(λ2 + λ3) + (19/11)]/[( λ2 - λ1)*( λ3 - λ1)]
BS = [(7/11)* λ1* λ3 - (10/11)*(λ1 + λ3) + (19/11)]/[( λ1 - λ2)*( λ3 - λ2)]
CS = [(7/11)* λ1* λ2 - (10/11)*(λ1 + λ2) + (19/11)]/[( λ2 - λ3)*( λ1 - λ3)]
For any N > 0:
a(N) = (4/11)*3^N + AS* λ1^N + BS* λ2^N + CS* λ3^N - 1
a(n) = 4*a(n-1)-2*a(n-2)-2*a(n-3)-5*a(n-4)+6*a(n-5). - Vincenzo Librandi, Dec 04 2018

Extensions

More terms from Jean-François Alcover, Dec 04 2018
Showing 1-2 of 2 results.