OFFSET
0,4
COMMENTS
The member k=7 of a family of sequences starting 0,1,1,k with recurrence a(n) = a(n-1)+k*a(n-2)+a(n-3)-a(n-4).
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..1000
Hugh Williams, R. K. Guy, Some fourth-order linear divisibility sequences, Intl. J. Number Theory 7 (5) (2011) 1255-1277
Index entries for linear recurrences with constant coefficients, signature (1,7,1,-1).
FORMULA
a(n) = +a(n-1) +7*a(n-2) +a(n-3) -a(n-4).
The roots (r1..r4) of the characteristic polynomials for this "family" of sequences have the following form (not simplified) for k= 1,2,3,4,5,6.... r1=(sqrt(4*k+10+2*sqrt(4*k+9))+sqrt(4*k-6+2*sqrt(4*k+9)))/4. r2=(sqrt(4*k+10+2*sqrt(4*k+9))-sqrt(4*k-6+2*sqrt(4*k+9)))/4. r3=(-sqrt(4*k+10-2*sqrt(4*k+9))-sqrt(4*k-6-2*sqrt(4*k+9)))/4. r4=(-sqrt(4*k+10-2*sqrt(4*k+9))+sqrt(4*k-6-2*sqrt(4*k+9)))/4. For k=1,2,3, r3 and r4 are complex . Closed-form (not simplified) is as follows for all k (note:for k1-k3 set r3 and r4 =0 and round a(n) to nearest integer): a(n)=sqrt(4*k+9)/(4*k+9)*(((r1)^n+(r2)^n)-((r3)^n+(r4)^n)). [Tim Monahan, Sep 17 2011]
MATHEMATICA
CoefficientList[Series[-x*(x - 1)*(1 + x)/(1 - x - 7*x^2 - x^3 + x^4), {x, 0, 40}], x] (* Vincenzo Librandi, Dec 19 2012 *)
LinearRecurrence[{1, 7, 1, -1}, {0, 1, 1, 7}, 30] (* Harvey P. Dale, Nov 15 2020 *)
PROG
(Magma) I:=[0, 1, 1, 7]; [n le 4 select I[n] else Self(n-1) + 7*Self(n-2) + Self(n-3) - Self(n-4): n in [1..30]]; // Vincenzo Librandi, Dec 19 2012
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
R. J. Mathar, at the request of R. K. Guy, Sep 03 2010
STATUS
approved