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

%I #45 Nov 06 2022 19:34:30

%S 0,0,2,3,6,10,21,42,86,171,342,682,1365,2730,5462,10923,21846,43690,

%T 87381,174762,349526,699051,1398102,2796202,5592405,11184810,22369622,

%U 44739243,89478486,178956970,357913941,715827882,1431655766,2863311531,5726623062,11453246122

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

%C Generally, a(n) is an autosequence if its inverse binomial transform is (-1)^n*a(n). It is of the first kind if the main diagonal is 0's and the first two upper diagonals (just above the main one) are the same. It is of the second kind if the main diagonal is equal to the first upper diagonal multiplied by 2. If the first upper diagonal is an autosequence, the sequence is a super autosequence. Example: A113405. The first upper diagonal is A001045(n). Another super autosequence: 0, 0, 0 followed by A059633(n). The first upper diagonal is A000045(n).

%C Difference table of a(n):

%C 0, 0, 2, 3, 6, 10, 21, 42, ...

%C 0, 2, 1, 3, 4, 11, 21, 44, ...

%C 2, -1, 2, 1, 7, 10, 23, 41, ...

%C -3, 3, -1, 6, 3, 13, 18, 45, ... .

%C This is an autosequence of the second kind. The main diagonal is 2*A001045(n) = A078008(n). More precisely it is a super autosequence, companion of A113405(n).

%C a(n+1) mod 10 = period 12: repeat 0, 2, 3, 6, 0, 1, 2, 6, 1, 2, 2, 5.

%C It is shifted A081374(n+1) mod 10 =

%C period 12: repeat 1, 2, 2, 5, 0, 2, 3, 6, 0, 1, 2, 6.

%C a(n) mod 9 = period 18:

%C repeat 0, 0, 2, 3, 6, 1, 3, 6, 5, 0, 0, 7, 6, 3, 8, 6, 3, 4 = c(n).

%C c(n) + c(n+9) = 0, 0, 9, 9, 9, 9, 9, 9, 9.

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

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

%F a(n+3) = 3*2^n - a(n), a(0)=a(1)=0, a(2)=2.

%F a(n) = 2*A113405(n+1) - A113405(n).

%F a(n+1) = 2*a(n) + period 6: repeat 0, 2, -1, 0, -2, 1. a(0)=0.

%F a(n) = 2^n - A081374(n+1).

%F a(n+3) = a(n+1) + A130755(n).

%F G.f.: x^2*(x-2) / ((x+1)*(2*x-1)*(x^2-x+1)). - _Colin Barker_, May 18 2014

%F a(n) = A024495(n) + A131531(n).

%F a(n+6) = a(n) + 21*2^n, a(0)=a(1)=0, a(2)=2, a(3)=3, a(4)=6, a(5)=10.

%F a(n) = A001045(n) - A092220(n).

%F a(n+12) = a(n) + 1365*2^n. First 12 values in the Data. (A024495(n+12) = A024495(n) + 1365*2^n).

%F a(3n) = A132805(n) = 3*A015565(n).

%F a(3n+1) = A132804(n) = 6*A015565(n).

%F a(3n+2) = A132397(n) = 2*A082311(n).

%F a(n) = 1/3*((-1)^n - 2*cos((n*Pi)/3) + 2^n). - _Alexander R. Povolotsky_, Jun 02 2014

%e G.f. = 2*x^2 + 3*x^3 + 6*x^4 + 10*x^5 + 21*x^6 + 42*x^7 + 86*x^8 + ...

%t a[n_] := (m = Mod[n, 6]; 1/3*(2^n + (-1)^n + 1/120*(m-6)*(m+1)*(m^3-29*m+40))); Table[a[n], {n, 0, 35}] (* _Jean-François Alcover_, May 19 2014, a non-recursive formula, after Mathematica's RSolve *)

%t LinearRecurrence[{2, 0, -1, 2}, {0, 0, 2, 3},50] (* _G. C. Greubel_, Feb 21 2017 *)

%o (PARI) concat([0,0], Vec(x^2*(x-2)/((x+1)*(2*x-1)*(x^2-x+1)) + O(x^100))) \\ _Colin Barker_, May 18 2014

%Y Cf. A000032, 1/(n+1), A164555/A027642 (all autosequences of 2nd kind). A007283, A175805.

%K nonn,easy

%O 0,3

%A _Paul Curtz_, May 17 2014

%E More terms from _Colin Barker_, May 18 2014