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.

A212668 a(n) = (16/3)*(n+1)*n*(n-1) + 8*n^2 + 1.

Original entry on oeis.org

9, 65, 201, 449, 841, 1409, 2185, 3201, 4489, 6081, 8009, 10305, 13001, 16129, 19721, 23809, 28425, 33601, 39369, 45761, 52809, 60545, 69001, 78209, 88201, 99009, 110665, 123201, 136649, 151041, 166409, 182785, 200201, 218689, 238281, 259009, 280905, 304001
Offset: 1

Views

Author

Keywords

Comments

a(n) is the difference between numbers of nonnegative multiples of 2*n+1 with even and odd digit sum in base 2*n in interval [0, 32*n^5).

Crossrefs

Programs

  • Magma
    [(16/3)*(n+1)*n*(n-1)+8*n^2+1: n in [1..40]]; // Vincenzo Librandi, Dec 01 2015
  • Mathematica
    LinearRecurrence[{4, -6, 4, -1}, {9, 65, 201, 449}, 40] (* Vincenzo Librandi, Dec 01 2015 *)
    CoefficientList[Series[x (9+29x-5x^2-x^3)/(1-x)^4,{x,0,40}],x] (* Harvey P. Dale, Mar 29 2023 *)
  • PARI
    a(n)=16*(n+1)*n*(n-1)/3+8*n^2+1 \\ Charles R Greathouse IV, Oct 07 2015
    
  • PARI
    Vec(x*(9+29*x-5*x^2-x^3)/(1-x)^4 + O(x^100)) \\ Colin Barker, Nov 30 2015
    

Formula

a(n) = 2/(2*n+1)*Sum_{i=1..n} tan^5(Pi*i/(2*n+1)) * sin(2*Pi*i/(2*n+1)).
G.f.: x*(9+29*x-5*x^2-x^3) / (1-x)^4. - Colin Barker, Nov 30 2015