A134011 Period 9: repeat [1, 2, 3, 4, 5, 4, 3, 2, 1].
1, 2, 3, 4, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5, 4, 3, 2, 1, 1, 2, 3, 4, 5
Offset: 0
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..1000
- Index entries for linear recurrences with constant coefficients, signature (0,0,0,0,0,0,0,0,1).
Crossrefs
Cf. A131974.
Programs
-
Magma
&cat [[1, 2, 3, 4, 5, 4, 3, 2, 1]: n in [0..8]]; // Wesley Ivan Hurt, Jun 11 2016
-
Maple
A134011:=n->[1, 2, 3, 4, 5, 4, 3, 2, 1][(n mod 9)+1]: seq(A134011(n), n=0..100); # Wesley Ivan Hurt, Jun 11 2016
-
Mathematica
PadRight[{}, 81, {1,2,3,4,5,4,3,2,1}] (* Harvey P. Dale, Oct 31 2011 *)
Formula
a(n) = a(n-9) for n > 8. G.f.: (1 + x + x^2 + x^3 + x^4)^2/(1 - x^9). - Chai Wah Wu, Jun 04 2016