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.

A167373 Expansion of (1+x)*(3*x+1)/(1+x+x^2).

Original entry on oeis.org

1, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1, -2, 3, -1
Offset: 0

Views

Author

Jamel Ghanouchi, Nov 02 2009

Keywords

Comments

Bisection of A138034.
Also row 2n of A137276 or A135929.

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical functions, National Bureau of Standards, Applied Math. Series 55, Tenth Printing, 1972, Chapter 22.

Crossrefs

Programs

  • Maple
    A167373 := proc(n)
        option remember;
        if n < 4 then
            op(n+1,[1,3,-1,-2]) ;
        else
            procname(n-3) ;
        end if;
    end proc:
    seq(A167373(n),n=0..20) ; # R. J. Mathar, Feb 06 2020
  • Mathematica
    CoefficientList[Series[(1 + x)*(3*x + 1)/(1 + x + x^2), {x, 0, 50}], x] (* G. C. Greubel, Jun 12 2016 *)
    LinearRecurrence[{-1,-1},{1,3,-1},120] (* Harvey P. Dale, Apr 05 2023 *)

Formula

G.f.: (1+x)*(3*x+1)/(1+x+x^2).
a(n) = a(n-3), n>4.
a(n) = - a(n-1) - a(n-2) for n>2.
a(n) = 4*sin(2*n*Pi/3)/sqrt(3)-2*cos(2*n*Pi/3) for n>0 with a(0)=1. - Wesley Ivan Hurt, Jun 12 2016

Extensions

Edited by R. J. Mathar, Nov 03 2009
Further edited and extended by Simon Plouffe, Nov 23 2009
Recomputed by N. J. A. Sloane, Dec 20 2009