OFFSET
1,5
LINKS
Colin Barker, Table of n, a(n) for n = 1..1000
Index entries for linear recurrences with constant coefficients, signature (0,0,0,5,0,0,0,-10,0,0,0,10,0,0,0,-5,0,0,0,1).
FORMULA
a(n) = (3/8 + n/4 - (1/4)*cos((Pi*n)/2) - (1/8)*cos(Pi*n) + (1/4)*sin((Pi*n)/2))^(((n + 3) mod 4) + 1). - Ilya Gutkovskiy, Dec 02 2015
From Colin Barker, Dec 02 2015: (Start)
a(n) = 5*a(n-4)-10*a(n-8)+10*a(n-12)-5*a(n-16)+a(n-20) for n>20.
G.f.: x*(1+x+x^2+x^3-3*x^4-x^5+3*x^6+11*x^7+3*x^8-x^9-3*x^10+11*x^11-x^12+x^13-x^14+x^15) / ((1-x)^5*(1+x)^5*(1+x^2)^5).
(End)
MAPLE
seq(seq(n^k, k=1..4), n=1..15); # Zerinvary Lajos, Jun 29 2007
MATHEMATICA
Table[(3/8 + n/4 - (1/4) Cos[(Pi n)/2] - (1/8) Cos[Pi n] + (1/4) Sin[(Pi n)/2])^(Mod[n + 3, 4] + 1), {n, 1, 58}] (* Ilya Gutkovskiy, Dec 02 2015 *)
PROG
(PARI) Vec(x*(1+x+x^2+x^3-3*x^4-x^5+3*x^6+11*x^7+3*x^8-x^9-3*x^10+11*x^11-x^12+x^13-x^14+x^15) / ((1-x)^5*(1+x)^5*(1+x^2)^5) + O(x^100)) \\ Colin Barker, Dec 02 2015
CROSSREFS
KEYWORD
nonn,easy,tabf
AUTHOR
Mohammad K. Azarian, Sep 02 2005
STATUS
approved