OFFSET
0,7
COMMENTS
A two-way infinite sequences which is palindromic (up to sign). - Michael Somos, Mar 21 2003
LINKS
Index entries for linear recurrences with constant coefficients, signature (0, 1, 1, 0, -1, 1, 0, -1, -1, 1, 1, -1, -1, 0, 1, -1, 0, 1, 1, 0, -1).
FORMULA
MAPLE
M := Matrix(21, (i, j)-> if (i=j-1) or (j=1 and member(i, [2, 3, 6, 10, 11, 15, 18, 19])) then 1 elif j=1 and member(i, [5, 8, 9, 12, 13, 16, 21]) then -1 else 0 fi); a := n -> (M^(n))[1, 1]; seq (a(n), n=0..67); # Alois P. Heinz, Jul 25 2008
MATHEMATICA
CoefficientList[Series[1/((1-x^2)(1-x^3)(1-x^6)(1-x^10)), {x, 0, 80}], x] (* or *) LinearRecurrence[{0, 1, 1, 0, -1, 1, 0, -1, -1, 1, 1, -1, -1, 0, 1, -1, 0, 1, 1, 0, -1}, {1, 0, 1, 1, 1, 1, 3, 1, 3, 3, 4, 3, 7, 4, 7, 7, 9, 7, 13, 9, 14}, 80] (* Harvey P. Dale, Aug 07 2015 *)
PROG
(PARI) a(n)=if(n<-20, -a(-21-n), if(n<0, 0, polcoeff(1/((1-x^2)*(1-x^3)*(1-x^6)*(1-x^10))+x*O(x^n), n)))
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved