%I #14 Jul 13 2024 13:53:41
%S 0,0,1,7,26,72,171,371,760,1500,2889,5475,10266,19116,35435,65495,
%T 120832,222664,410017,754671,1388650,2554784,4699707,8644907,15901336,
%U 29248068,53796617,98948523,181995914,334743972,615691547
%N a(n) = a(n-1)+a(n-2)+a(n-3)+4*n^2-16*n+18 with a(0)=0, a(1)=0 and a(2)=1.
%C The a(n+2) represent the Kn14 and Kn24 sums of the square array of Delannoy numbers A008288. See A180662 for the definition of these knight and other chess sums.
%H Harvey P. Dale, <a href="/A180669/b180669.txt">Table of n, a(n) for n = 0..1000</a>
%H <a href="/index/Rec#order_06">Index entries for linear recurrences with constant coefficients</a>, signature (4,-5,2,-1,2,-1).
%F a(n) = a(n-1)+a(n-2)+a(n-3)+4*(n-2)^2+2 with a(0)=0, a(1)=0 and a(2)=1.
%F a(n) = a(n-1)+A001590(n+5)-2-4*n with a(0)=0.
%F a(n) = Sum_{m=0..n} A005899(m)*A000073(n-m).
%F a(n+2) = Sum_{k=0..floor(n/2)} A008288(n-k+3,k+3).
%F GF(x) = (x^2*(1+x)^3)/((1-x)^3*(1-x-x^2-x^3)).
%F From _Bruno Berselli_, Sep 23 2010: (Start)
%F a(n) = 3*a(n-1)-2a(n-2)-a(n-4)+a(n-5)+8 for n>4.
%F a(n)-4*a(n-1)+5a(n-2)-2*a(n-3)+a(n-4)-2*a(n-5)+a(n-6) = 0 for n>5. (End)
%p nmax:=30: a(0):=0: a(1):=0: a(2):=1: for n from 3 to nmax do a(n):= a(n-1)+a(n-2)+a(n-3)+4*(n-2)^2+2 od: seq(a(n),n=0..nmax);
%t nxt[{n_,a_,b_,c_}]:={n+1,b,c,a+b+c+4n(n-2)+6}; NestList[nxt,{2,0,0,1},30][[;;,2]] (* or *) LinearRecurrence[{4,-5,2,-1,2,-1},{0,0,1,7,26,72},40] (* _Harvey P. Dale_, Jul 13 2024 *)
%Y Cf. A000073 (Kn11 & Kn21), A089068 (Kn12 & Kn22), A180668 (Kn13 & Kn23), A180669 (Kn14 & Kn24), A180670 (Kn15 & Kn25).
%Y Cf. A000073, A005899, A008288.
%K easy,nonn
%O 0,4
%A _Johannes W. Meijer_, Sep 21 2010