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.

A097123 Expansion of (1-x)^2/((1-x)^3 - 4*x^3).

Original entry on oeis.org

1, 1, 1, 5, 17, 41, 97, 253, 673, 1745, 4481, 11573, 30001, 77689, 200929, 519725, 1344833, 3479969, 9004033, 23296357, 60276817, 155961545, 403535969, 1044107357, 2701521889, 6989923441, 18085741441, 46795063445, 121077583217
Offset: 0

Views

Author

Paul Barry, Jul 25 2004

Keywords

Crossrefs

Cf. A097122.

Programs

  • Mathematica
    LinearRecurrence[{3, -3, 5}, {1, 1, 1}, 30] (* Amiram Eldar, Oct 11 2021 *)
    CoefficientList[Series[(1-x)^2/((1-x)^3-4x^3),{x,0,30}],x] (* Harvey P. Dale, May 06 2022 *)
  • PARI
    a(n) = sum(k=0, n\3, binomial(n, 3*k) * 4^k); \\ Michel Marcus, Oct 11 2021

Formula

G.f.: (1-2*x+x^2)/(1-3*x+3*x^2-5*x^3).
a(n) = 3*a(n-1) - 3*a(n-2) + 5*a(n-3).
a(n) = Sum_{k=0..floor(n/3)} binomial(n, 3k) * 4^k.