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.

A073724 a(n) = (4^(n+1) + 6n + 5)/9.

Original entry on oeis.org

1, 3, 9, 31, 117, 459, 1825, 7287, 29133, 116515, 466041, 1864143, 7456549, 29826171, 119304657, 477218599, 1908874365, 7635497427, 30541989673, 122167958655, 488671834581, 1954687338283, 7818749353089, 31274997412311
Offset: 0

Views

Author

Wouter Meeussen, Sep 01 2002

Keywords

Comments

a(n) is the number of times a disk is moved from peg 1 to peg 2 during a move of a tower of 2n or (2n-1) disks from peg 1 to peg 2 ("Tower of Hanoi" problem). Binomial transform of A025579.
An approximation to A091841.

Examples

			Moving a tower of 4 disks = 2^4 - 1 moves, coded {1,0,5,1,2,3,1,0,5,4,2,5,1,0,5}. The move from peg 1 to peg 2 has code "0" and this occurs 3 times. For 3 disks we also find 3 zeros in {0,1,3,0,4,5,0}. Hence a(2)=3. The coding corresponds to the rank of the permutation {'from peg' 1, 'to peg' 2, 'by peg' 3} or {1,2,3} with rank 0.
		

Crossrefs

Cf. A001045, A002450, A007583, A020988, A025579, A047849 (first differences), A090822, A091841.

Programs

  • Magma
    [(4^(n+1)+6*n+5)/9: n in [0..40] ]; // Vincenzo Librandi, Apr 28 2011
  • Mathematica
    Table[(4^(n+1)+6n+5)/9, {n, 0, 24}]
  • PARI
    a(n)=(4*4^n+6*n+5)/9
    
  • PARI
    a(n)=polcoeff((1-3*x)/(1-4*x)/(1-x)^2+x*O(x^n),n)
    

Formula

G.f.: (1-3*x)/((1-4*x)*(1-x)^2).
a(n) = Sum_{k=0..n} A047849(k). - L. Edson Jeffery, May 01 2021
From Elmo R. Oliveira, Dec 11 2023: (Start)
a(n) = 6*a(n-1) - 9*a(n-2) + 4*a(n-3) for n>2.
E.g.f.: (1/9)*(4*(exp(4*x)) + 6*x*exp(x) + 5*exp(x)). (End)

A091840 Lengths of suffix blocks associated with A091787.

Original entry on oeis.org

1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 32, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 32, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 119, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 1, 1, 3, 1, 1, 9, 1
Offset: 1

Views

Author

N. J. A. Sloane, Mar 10 2004

Keywords

Crossrefs

Showing 1-2 of 2 results.