%I #19 Aug 15 2022 08:35:03
%S 0,0,52,176,372,640,980,1392,1876,2432,3060,3760,4532,5376,6292,7280,
%T 8340,9472,10676,11952,13300,14720,16212,17776,19412,21120,22900,
%U 24752,26676,28672
%N Number of 5-cycles in the n X n king graph.
%H Colin Barker, <a href="/A288919/b288919.txt">Table of n, a(n) for n = 1..1000</a>
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/GraphCycle.html">Graph Cycle</a>
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/KingGraph.html">King Graph</a>
%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (3,-3,1).
%F a(n) = 36*n^2 - 128*n + 112 for n > 1. - _Andrew Howroyd_, Jun 19 2017
%F From _Colin Barker_, Mar 11 2019: (Start)
%F G.f.: 4*x^3*(13 + 5*x) / (1 - x)^3.
%F a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3) for n > 4. (End)
%F E.g.f.: 4*(exp(x)*(28 - 23*x + 9*x^2) - 28 - 5*x). - _Stefano Spezia_, Aug 14 2022
%t Table[If[n == 1, 0, 4 (n - 2) (9 n - 14)], {n, 30}]
%t Join[{0, 0}, LinearRecurrence[{3, -3, 1}, {20, 0, 52}, {3, 20}]]
%t CoefficientList[Series[-((4 x^2 (13 + 5 x))/(-1 + x)^3), {x, 0, 20}], x]
%o (PARI) a(n)=if(n<3, 0, 36*n^2-128*n+112) \\ _Charles R Greathouse IV_, Jun 19 2017
%o (PARI) concat([0,0], Vec(4*x^3*(13 + 5*x) / (1 - x)^3 + O(x^40))) \\ _Colin Barker_, Mar 11 2019
%Y Cf. A016742 (3-cycles), A288918 (4-cycles), A288920 (6-cycles).
%K nonn,easy
%O 1,3
%A _Eric W. Weisstein_, Jun 19 2017