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.

A024038 a(n) = 4^n - n^2.

Original entry on oeis.org

1, 3, 12, 55, 240, 999, 4060, 16335, 65472, 262063, 1048476, 4194183, 16777072, 67108695, 268435260, 1073741599, 4294967040, 17179868895, 68719476412, 274877906583, 1099511627376, 4398046510663, 17592186043932
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    [ 4^n-n^2: n in [0..30] ]; // Vincenzo Librandi, Dec 25 2010
    
  • Mathematica
    Table[4^n-n^2,{n,0,30}] (* or *) LinearRecurrence[{7,-15,13,-4},{1,3,12,55},30] (* Harvey P. Dale, Sep 14 2013 *)
  • SageMath
    [4^n-n^2 for n in range(31)] # G. C. Greubel, Aug 18 2023

Formula

a(n) = A000325(n)*A006127(n). - Reinhard Zumkeller, Apr 10 2010
G.f.: (1 - 4*x + 6*x^2 + 3*x^3)/((1 - x)^3*(1 - 4*x)). - Colin Barker, May 29 2012
E.g.f.: exp(4*x) - x*(1 + x)*exp(x). - G. C. Greubel, Aug 18 2023