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.

A015533 a(n) = 4*a(n-1) + 9*a(n-2).

Original entry on oeis.org

0, 1, 4, 25, 136, 769, 4300, 24121, 135184, 757825, 4247956, 23812249, 133480600, 748232641, 4194255964, 23511117625, 131792774176, 738771155329, 4141219588900, 23213818753561, 130126251314344, 729429374039425, 4088853757986796, 22920279398302009
Offset: 0

Views

Author

Keywords

Comments

For n>=2, a(n) equals the permanent of the (n-1) X (n-1) tridiagonal matrix with 4's along the main diagonal, and 3's along the superdiagonal and the subdiagonal. - John M. Campbell, Jul 19 2011

Programs

  • Magma
    [n le 2 select n-1 else 4*Self(n-1)+9*Self(n-2): n in [1..30] ]; // Vincenzo Librandi, Nov 12 2012
    
  • Mathematica
    a[n_]:=(MatrixPower[{{1,4},{1,-5}},n].{{1},{1}})[[2,1]]; Table[Abs[a[n]],{n,-1,40}] (* Vladimir Joseph Stephan Orlovsky, Feb 19 2010 *)
    LinearRecurrence[{4, 9}, {0, 1}, 30] (* Vincenzo Librandi, Nov 12 2012 *)
  • PARI
    x='x+O('x^30); concat([0], Vec(x/(1-4*x-9*x^2))) \\ G. C. Greubel, Jan 01 2018
  • Sage
    [lucas_number1(n,4,-9) for n in range(0, 22)] # Zerinvary Lajos, Apr 23 2009
    

Formula

From R. J. Mathar, Apr 29 2008: (Start)
O.g.f.: x/(1-4*x-9*x^2).
a(n) = -9^n*(A^n - B^n)/(2*sqrt(13)) where A = -1/(2+sqrt(13)) and B = 1/(sqrt(13)-2). (End)
a(n) = Sum_{k, 0<=k<=n} A155161(n,k)*3^(n-k), n>=1. - Philippe Deléham, Jan 27 2009