|
|
A105073
|
|
Define a(1)=0, a(2)=2 then a(n) = 3*a(n-1) - a(n-2), a(n+1) = 3*a(n)-a(n-1) and a(n+2) = 3*a(n+1) - a(n) + 2.
|
|
1
|
|
|
0, 2, 6, 16, 44, 116, 304, 798, 2090, 5472, 14328, 37512, 98208, 257114, 673134, 1762288, 4613732, 12078908, 31622992, 82790070, 216747218, 567451584, 1485607536, 3889371024, 10182505536, 26658145586, 69791931222, 182717648080, 478361013020, 1252365390980
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
Previously, the Name had included the comment, "This sequence is such that 20*(a(n)^2) + 20*a(n) + 1 = j^2 = a square."
However, Anthony Hernandez observed that this statement is not true for all terms; e.g., at a(4)=16, 20*16^2 + 20*16 + 1 = 5441, a nonsquare.
It is true that 20*a(n)^2 + 20*a(n) + 1 = A305315(n/3)^2 when n == 0 (mod 3) and A305316((n-2)/3)^2 when n == 2 (mod 3); however, for n == 1 (mod 3) with n > 1, sqrt(20*a(n)^2 + 20*a(n) + 1) is a noninteger number whose fractional part apparently approaches 3 - sqrt(5) as n increases, and Andrey Zabolotskiy observes that round(sqrt(20*a(n)^2 + 20*a(n) + 1) + sqrt(5)) appears to be equal to A002878(n). (End)
|
|
LINKS
|
|
|
FORMULA
|
a(n) = (1/6)*(Fibonacci(2n+4) - 2*Fibonacci(2n) - 2*cos((n+2)(2*Pi/3)) - 4). - Ralf Stephan, May 20 2007
a(n) = 3*a(n-1) - a(n-2) + a(n-3) - 3*a(n-4) + a(n-5).
G.f.: 2*x^2/((1-x) * (1+x+x^2) * (1-3*x+x^2)).
|
|
MATHEMATICA
|
a[n_]:=(1/6)*(Fibonacci[2*n+4] - 2*Fibonacci[2*n] - 2*Cos[(n+2)*(2*Pi/3)] - 4 ); Array[a, 50] (* Stefano Spezia, Jan 11 2019 *)
RecurrenceTable[{a[1]==0, a[2]==2, a[3]==6, a[4]==16, a[5]==44, a[n]== 3 a[n-1] - a[n-2] + a[n-3] - 3 a[n-4] + a[n-5]}, a, {n, 35}] (* Vincenzo Librandi, Jan 13 2019 *)
|
|
PROG
|
(Magma) I:=[0, 2, 6, 16, 44]; [n le 5 select I[n] else 3*Self(n-1) - Self(n-2) + Self(n-3) - 3*Self(n-4) + Self(n-5): n in [1..35]]; // Vincenzo Librandi, Jan 13 2019
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|