A091086 a(n) = A000975(n) mod 10.
0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0, 1, 2, 5, 0
Offset: 0
Links
- Index entries for linear recurrences with constant coefficients, signature (0,0,0,1).
Programs
-
Mathematica
CoefficientList[Series[x (1 + 2 x + 5 x^2)/(1 - x^4), {x, 0, 50}], x] (* G. C. Greubel, Sep 26 2017 *) PadRight[{},120,{0,1,2,5}] (* Harvey P. Dale, Apr 30 2022 *)
-
PARI
x='x+O('x^50); Vec(x*(1+2*x+5*x^2)/(1-x^4)) \\ G. C. Greubel, Sep 26 2017
Formula
G.f.: x*(1 + 2*x + 5*x^2)/(1 - x^4).
E.g.f.: 2*exp(x) - exp(-x) - cos(x) - 2*sin(x).
a(n) = 2 - (-1)^n - cos(Pi*n/2) - 2*sin(Pi*n/2).
a(n+4) = a(n). - G. C. Greubel, Sep 26 2017
2*a(n) = (n mod 2) + (n mod 4)^2. - Bruno Berselli, Oct 18 2018
Comments