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.

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

Original entry on oeis.org

0, 1, 2, 4, 5, 7, 10, 15, 21, 29, 40, 56, 78, 108, 149, 206, 285, 394, 544, 751, 1037, 1432, 1977, 2729, 3767, 5200, 7178, 9908, 13676, 18877, 26056, 35965, 49642, 68520, 94577, 130543, 180186, 248707, 343285, 473829, 654016, 902724, 1246010, 1719840, 2373857, 3276582
Offset: 0

Views

Author

Roger L. Bagula and Gary W. Adamson, Dec 01 2009

Keywords

References

  • R. Pallu de la Barrière, Optimal Control Theory, Dover Publications, New York, 1967, pages 339-344.

Crossrefs

Programs

  • Magma
    R:=PowerSeriesRing(Integers(), 60);
    [0] cat Coefficients(R!( x*(1+x^2-x^3)/((1-x)*(1-x-x^4)) )); // G. C. Greubel, Apr 20 2025
    
  • Mathematica
    LinearRecurrence[{2,-1,0,1,-1}, {0,1,2,4,5}, 60] (* G. C. Greubel, Jul 28 2016 *)
  • PARI
    a(n)=([0,1,0,0,0; 0,0,1,0,0; 0,0,0,1,0; 0,0,0,0,1; -1,1,0,-1,2]^n*[0;1;2;4;5])[1,1] \\ Charles R Greathouse IV, Jul 29 2016
    
  • SageMath
    def A168639_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P( x*(1+x^2-x^3)/((1-x)*(1-x-x^4)) ).list()
    print(A168639_list(60)) # G. C. Greubel, Apr 20 2025

Formula

Lim_{n -> oo} a(n+1)/a(n) = 1.38027756909761411567330169182..., see A086106.
a(n) = 2*a(n-1) -a(n-2) +a(n-4) -a(n-5). - R. J. Mathar, Dec 02 2009
a(n) = A098578(n) - A098578(n-3) + A098578(n-2). - R. J. Mathar, May 23 2013
a(n) = A003269(n+4) + A003269(n+2) - A003269(n+1) - 1. - G. C. Greubel, Apr 20 2025