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.

A108981 a(n) = 3a(n-1) + 4a(n-2), a(0) = 1, a(1) = 5.

Original entry on oeis.org

1, 5, 19, 77, 307, 1229, 4915, 19661, 78643, 314573, 1258291, 5033165, 20132659, 80530637, 322122547, 1288490189, 5153960755, 20615843021, 82463372083, 329853488333, 1319413953331, 5277655813325, 21110623253299
Offset: 0

Views

Author

Philippe Deléham, Jul 23 2005

Keywords

Comments

The Hankel transform of this sequence is [1,-6,0,0,0,0,0,0,0,0,...]. - Philippe Deléham, Apr 15 2008
Let A be the Hessenberg matrix of order n, defined by: A[1,j]=1, A[i,i]:=-2, A[i,i-1]=-1, and A[i,j]=0 otherwise. Then, for n >= 1, a(n-1) = charpoly(A,2). - Milan Janjic, Jan 26 2010

Crossrefs

Programs

  • Magma
    I:=[1,5]; [n le 2 select I[n] else 3*Self(n-1)+4*Self(n-2): n in [1..30]]; // Vincenzo Librandi, Feb 17 2014
    
  • Mathematica
    LinearRecurrence[{3,4},{1,5},30] (* Harvey P. Dale, Feb 16 2014 *)
  • PARI
    Vec((1+2*x)/(1+x)/(1-4*x)+O(x^99)) \\ Charles R Greathouse IV, Jan 11 2012
    
  • Python
    def A108981(n): return ((4<<(m:=n+1<<1))|2)//5-((1<>1 # Chai Wah Wu, Apr 22 2025

Formula

Inverse binomial transform of A003948.
a(2n) = 4a(2n-1) - 1; a(2n+1) = 4a(2n) + 1.
O.g.f.: (1+2*x)/((1+x)(1-4*x)). - R. J. Mathar, Apr 02 2008
Sum_{k=0..n} a(k) = A037481(n+1). - Philippe Deléham, Apr 15 2008

Extensions

Corrected by T. D. Noe, Nov 07 2006
Edited by N. J. A. Sloane at the suggestion of R. J. Mathar, Apr 14 2008