OFFSET
1,2
COMMENTS
1 0 1 1 1 1 1 1
0 1 1 -1 1 -1 -1 1
-1 -1 1 0 1 1 -1 -1
-1 1 0 1 1 -1 1 -1
-1 -1 -1 -1 1 0 1 1
-1 1 -1 1 0 1 -1 1
-1 1 1 -1 -1 1 1 0
-1 -1 1 1 -1 -1 0 1
LINKS
G. C. Greubel, Table of n, a(n) for n = 1..1000
Index entries for linear recurrences with constant coefficients, signature (2,-7).
FORMULA
a(1) = 1, a(2) = -5, a(n) = 2*a(n-1) - 7*a(n-2). - Philippe Deléham, Mar 05 2012
G.f.: x*(1-7*x)/(1-2*x+7*x^2). - Philippe Deléham, Mar 05 2012
G.f.: G(0)/(2*x) -1/x, where G(k)= 1 + 1/(1 - x*(6*k+1)/(x*(6*k+7) + 1/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Jun 03 2013
MATHEMATICA
Rest[CoefficientList[Series[x*(1-7*x)/(1-2*x+7*x^2), {x, 0, 30}], x]] (* G. C. Greubel, Oct 22 2018 *)
PROG
(PARI) x='x+O('x^30); Vec(x*(1-7*x)/(1-2*x+7*x^2)) \\ G. C. Greubel, Oct 22 2018
(Magma) I:=[1, -5]; [n le 2 select I[n] else 2*Self(n-1) - 7*Self(n-2): n in [1..30]]; // G. C. Greubel, Oct 22 2018
(GAP) a:=[1, -5];; for n in [3..30] do a[n]:=2*a[n-1]-7*a[n-2]; od; a; # Muniru A Asiru, Oct 23 2018
CROSSREFS
KEYWORD
sign,easy
AUTHOR
Simone Severini, Dec 08 2003
EXTENSIONS
Corrected and extended by Philippe Deléham, Mar 05 2012
STATUS
approved