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.

A026039 a(n) = (d(n) - r(n))/5, where d = A026037 and r is the periodic sequence with fundamental period (1,2,0,2,0).

Original entry on oeis.org

2, 4, 8, 13, 21, 31, 44, 61, 81, 106, 135, 169, 209, 254, 306, 364, 429, 502, 582, 671, 768, 874, 990, 1115, 1251, 1397, 1554, 1723, 1903, 2096, 2301, 2519, 2751, 2996, 3256, 3530, 3819, 4124, 4444, 4781, 5134, 5504, 5892, 6297, 6721, 7163, 7624, 8105, 8605, 9126, 9667, 10229, 10813, 11418, 12046, 12696, 13369
Offset: 3

Views

Author

Keywords

Crossrefs

Cf. A026037.

Programs

  • Magma
    [Round((2*n-1)*(n^2-n+6)/30): n in [3..60]]; // Vincenzo Librandi, Jun 25 2011
  • Mathematica
    f[n_] := Round[(2 n - 1)*(n^2 - n + 6)/30]; Array[f, 57, 3]
    LinearRecurrence[{3,-3,1,0,1,-3,3,-1},{2,4,8,13,21,31,44,61},60] (* Harvey P. Dale, Sep 05 2023 *)

Formula

a(n) = (n + 3)*(2*n^2 + 9*n + 22)/30 - 1/5 - (-1/25*((5 - 5^(1/2))^(1/2) - (5 + 5^(1/2))^(1/2))*2^(1/2))*sin(2*n*Pi/5) - (1/25*((5 - 5^(1/2))^(1/2) + (5 + 5^(1/2))^(1/2))*2^(1/2))*sin(4*n*Pi/5). - Richard Choulet, Dec 14 2008
a(n) = round((2*n-1)*(n^2-n+6)/30) = floor((2*n^3-3*n^2+13*n)/30) = ceiling((n-1)*(2*n^2-n+12)/30) = round((n-1)*(2*n^2-n+12)/30). - Mircea Merca, Dec 03 2010
From R. J. Mathar, May 24 2010: (Start)
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3) + a(n-5) - 3*a(n-6) + 3*a(n-7) - a(n-8).
G.f.: -x^3*(-2+2*x-2*x^2+x^3-2*x^4+3*x^5-3*x^6+x^7) / ( (x^4+x^3+x^2+x+1)*(x-1)^4 ). (End)
a(n) = a(n-5) + n^2 - 6*n + 13, n > 5, a(1)=0, a(2)=1. - Mircea Merca, Dec 03 2010