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.

A002798 a(n) = a(n-1) + a(n-2) - a(n-3).

Original entry on oeis.org

18, 45, 69, 96, 120, 147, 171, 198, 222, 249, 273, 300, 324, 351, 375, 402, 426, 453, 477, 504, 528, 555, 579, 606, 630, 657, 681, 708, 732, 759, 783, 810, 834, 861, 885, 912, 936, 963, 987, 1014, 1038, 1065, 1089
Offset: 1

Views

Author

Keywords

Comments

The old definition was a(n) = a(n-2)+a(n-3)-a(n-5).
The following applies to this sequence and also to all sequences of the form a(n) = a(n-1) + a(n-2) - a(n-3), regardless of initial values: (a(n+3i) + a(n))/(a(n+2i) + a(n+i)) = 1, as long as a(n+2i) + a(n+i) != 0. - Klaus Purath, Jun 05 2024

References

  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Maple
    A002798:=3*(6+9*z+2*z**2)/(z+1)/(z-1)**2; # Simon Plouffe in his 1992 dissertation
  • Mathematica
    LinearRecurrence[{1,1,-1},{18,45,69},50] (* Harvey P. Dale, Sep 17 2023 *)

Formula

a(n) = 6*A007310(n) + 3*A047208(n).
a(n) = (51*n - 12)/2 - 3*(1 - (-1)^n)/4 = 2*a(n-1) - a(n-2) + 3(-1)^n. - Klaus Purath, Jun 05 2024

Extensions

Definition simplified by Ray Chandler. - N. J. A. Sloane, Mar 07 2024