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.

A283969 a(n) = n + 1 + Sum_{k=0..n} floor((n-k)/r), where r = (3+sqrt(5))/2.

Original entry on oeis.org

1, 4, 10, 18, 29, 43, 59, 78, 99, 123, 150, 179, 211, 246, 283, 323, 365, 410, 458, 508, 561, 616, 674, 735, 798, 864, 933, 1004, 1078, 1154, 1233, 1315, 1399, 1486, 1576, 1668, 1763, 1860, 1960, 2063, 2168, 2276, 2386, 2499, 2615, 2733, 2854, 2978, 3104
Offset: 0

Views

Author

Clark Kimberling, Mar 18 2017

Keywords

Comments

This is column 1 of the transposable interspersion A283938.

Crossrefs

Partial sums of A026352.

Programs

  • Mathematica
    r = GoldenRatio^2; z = 120;
    s[0] = 1; s[n_] := s[n] = s[n - 1] + 1 + Floor[n*r];
    Table[n + 1 + Sum[Floor[(n - k)/r], {k, 0, n}], {n, 0, z}] (* A283968 *)
    Table[s[n], {n, 0, z}] (* A283969 *)
  • PARI
    a(n) = if(n<1, 1, a(n - 1) + 1 + floor(n*(3 + sqrt(5))/2));
    for(n = 0, 50, print1(a(n),", ")) \\ Indranil Ghosh, Mar 19 2017
    
  • Python
    import math
    from sympy import sqrt
    def a(n):
        return 1 if n<1 else a(n - 1) + 1 + int(math.floor(n*(3 + sqrt(5))/2))
    print([a(n) for n in range(51)]) # Indranil Ghosh, Mar 19 2017

Formula

a(n) = n + 1 + Sum_{k=0..n} floor((n-k)/r), where r = (3+sqrt(5))/2.