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.

A229655 Quintisection a(5n+k) gives k-th differences of a for k=0..4 with a(n)=0 for n<4 and a(4)=1.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 0, 0, 1, -4, 0, 0, 1, -3, 6, 0, 1, -2, 3, -4, 1, -1, 1, -1, 2, 0, 0, 0, 1, -8, 0, 0, 1, -7, 22, 0, 1, -6, 15, -28, 1, -5, 9, -13, 18, -4, 4, -4, 5, -11, 0, 0, 1, -6, 24, 0, 1, -5, 18, -46, 1, -4, 13, -28, 50, -3, 9, -15, 22, -33, 6, -6, 7
Offset: 0

Views

Author

Alois P. Heinz, Sep 27 2013

Keywords

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; local m, q;
          m:= irem(n, 5, 'q'); `if`(n<5, `if`(n=4, 1, 0),
          add(a(q+m-j)*(-1)^j*binomial(m, j), j=0..m))
        end:
    seq(a(n), n=0..100);
  • Mathematica
    a[n_] := a[n] = Module[{ m, q}, {q, m} = QuotientRemainder[n, 5]; If[n < 5, If[n == 4, 1, 0], Sum[a[q + m - j]*(-1)^j*Binomial[m, j], {j, 0, m}]]];
    Table[a[n], {n, 0, 100}] (* Jean-François Alcover, Jun 09 2018, from Maple *)

Formula

a(5*n) = a(n),
a(5*n+1) = a(n+1) - a(n),
a(5*n+2) = a(n+2) - 2*a(n+1) + a(n),
a(5*n+3) = a(n+3) - 3*a(n+2) + 3*a(n+1) - a(n),
a(5*n+4) = a(n+4) - 4*a(n+3) + 6*a(n+2) - 4*a(n+1) + a(n).