login
a(n) = 2*a(n-1) + 2*a(n-2) + 2*a(n-3) - a(n-4); a(0)=0, a(1)=1, a(2)=2, a(3)=5.
5

%I #63 Aug 10 2023 03:37:00

%S 0,1,2,5,16,45,130,377,1088,3145,9090,26269,75920,219413,634114,

%T 1832625,5296384,15306833,44237570,127848949,369490320,1067846845,

%U 3086134658,8919094697,25776662080,74495936025,215297250946,622220603405

%N a(n) = 2*a(n-1) + 2*a(n-2) + 2*a(n-3) - a(n-4); a(0)=0, a(1)=1, a(2)=2, a(3)=5.

%C This is a divisibility sequence; that is, if n divides m, then a(n) divides a(m). - _T. D. Noe_, Dec 23 2008

%C Case P1 = 2, P2 = -4, Q = 1 of the 3-parameter family of 4th-order linear divisibility sequences found by Williams and Guy. - _Peter Bala_, Mar 04 2014

%H G. C. Greubel, <a href="/A138573/b138573.txt">Table of n, a(n) for n = 0..1000</a>

%H Kunle Adegoke, Robert Frontczak, and Taras Goy, <a href="https://arxiv.org/abs/2308.04567">Binomial Fibonacci sums from Chebyshev polynomials</a>, arXiv:2308.04567 [math.CO], 2023.

%H Peter Bala, <a href="/A100047/a100047.pdf">Linear divisibility sequences and Chebyshev polynomials</a>

%H H. C. Williams and R. K. Guy, <a href="http://www.emis.de/journals/INTEGERS/papers/a17self/a17self.Abstract.html">Some Monoapparitic Fourth Order Linear Divisibility Sequences</a>, Integers, Volume 12A (2012) The John Selfridge Memorial Volume.

%H <a href="/index/Di#divseq">Index to divisibility sequences</a>

%H <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (2,2,2,-1).

%F a(n) = round(w^n/2/sqrt(5)) where w = (1+r)/(1-r) = 2.89005363826396... and r = sqrt(sqrt(5)-2) = 0.485868271756...; for n >= 3, a(n) = A071101(n+3).

%F G.f.: -x*(x-1)*(1+x)/(1 - 2*x - 2*x^2 - 2*x^3 + x^4). - _R. J. Mathar_, Jun 03 2009

%F From _Peter Bala_, Mar 04 2014: (Start)

%F Define a Lucas sequence {U(n)} in the ring of Gaussian integers by the recurrence U(n) = (1 + i)*U(n-1) + U(n-2) with U(0) = 0 and U(1) = 1. Then a(n) = |U(n)|^2.

%F Let a, b denote the zeros of x^2 - (1 + i)*x - 1 and c, d denote the zeros of x^2 - (1 - i)*x - 1.

%F Then a(n) = (a^n - b^n)*(c^n - d^n)/((a - b)*(c - d)).

%F a(n) = (alpha(1)^n + beta(1)^n - alpha(2)^n - beta(2)^n)/(2*sqrt(5)), where alpha(1), beta(1) are the roots of x^2 - ( 1 + sqrt(5))*x + 1 = 0, and alpha(2), beta(2) are the roots of x^2 - (1 - sqrt(5))*x + 1 = 0.

%F The o.g.f. is the Hadamard product of the rational functions x/(1 - (1 + i)x - x^2) and x/(1 - (1 - i)x - x^2). (End)

%F From _Peter Bala_, Mar 24 2014: (Start)

%F a(n) = (1/sqrt(5))*(T(n,phi) - T(n,-1/phi)), where phi = 1/2*(1 + sqrt(5)) is the golden ratio and T(n,x) denotes the Chebyshev polynomial of the first kind. Compare with the Fibonacci numbers, A000045, whose terms are given by the Binet formula 1/sqrt(5)*( phi^n - (-1/phi)^n ).

%F a(n) = top right (or bottom left) entry of the 2 X 2 matrix T(n, M), where M is the 2 X 2 matrix [0, 1; 1, 1]; the off-diagonal elements of M^n give the sequence of Fibonacci numbers. Bottom right entry of the matrix T(n, M) gives A138574. See the remarks in A100047 for the general connection between Chebyshev polynomials and linear divisibility sequences of the fourth order. (End)

%F a(n) = (((phi + sqrt(phi))^n + (phi - sqrt(phi))^n)/2 - (-1)^n * cos(n*arctan(sqrt(phi))))/sqrt(5), where phi=(1+sqrt(5))/2. - _Vladimir Reshetnikov_, May 11 2016

%F a(n) = A143056(n+1)^2 + A272665(n+1)^2. - _Vladimir Reshetnikov_, Oct 05 2016

%F Lim_{n -> inf} a(n)/a(n-1) = A318605. - _A.H.M. Smeets_, Sep 12 2018

%p seq(coeff(series((x*(1-x)*(x+1))/(1-2*x-2*x^2-2*x^3+x^4),x,n+1), x, n), n = 0 .. 30); # _Muniru A Asiru_, Sep 12 2018

%t Round@Table[(((GoldenRatio + Sqrt[GoldenRatio])^n + (GoldenRatio - Sqrt[GoldenRatio])^n)/2 - (-1)^n Cos[n ArcTan[Sqrt[GoldenRatio]]])/Sqrt[5], {n, 0, 20}] (* or *) LinearRecurrence[{2, 2, 2, -1}, {0, 1, 2, 5}, 20] (* _Vladimir Reshetnikov_, May 11 2016 *)

%t Table[Abs[Fibonacci[n, 1 + I]]^2, {n, 0, 20}] (* _Vladimir Reshetnikov_, Oct 05 2016 *)

%t CoefficientList[Series[-x*(x-1)*(1+x)/(1-2*x-2*x^2-2*x^3+x^4), {x, 0, 20}], x] (* _Stefano Spezia_, Sep 12 2018 *)

%o (PARI) x='x+O('x^50); concat([0], Vec(x*(1-x)*(1+x)/(1 -2*x -2*x^2 -2*x^3 +x^4))) \\ _G. C. Greubel_, Aug 08 2017

%o (GAP) a:=[0,1,2,5];; for n in [5..30] do a[n]:=2*a[n-1]+2*a[n-2]+2*a[n-3]-a[n-4]; od; a; # _Muniru A Asiru_, Sep 12 2018

%Y Cf. A071101, A000045, A100047, A138574, A143056, A272665.

%K nonn

%O 0,3

%A _Benoit Cloitre_, May 12 2008