Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #8 Sep 08 2017 13:36:08
%S 0,6,44,164,440,970,1876,3304,5424,8430,12540,17996,25064,34034,45220,
%T 58960,75616,95574,119244,147060,179480,216986,260084,309304,365200,
%U 428350,499356,578844,667464,765890,874820,994976,1127104,1271974,1430380,1603140,1791096,1995114
%N Wiener index of the n X n queen graph.
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/QueenGraph.html">Queen Graph</a>
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/WienerIndex.html">Wiener Index</a>
%H <a href="/index/Rec#order_05">Index entries for linear recurrences with constant coefficients</a>, signature (5,-10,10,-5,1).
%F a(n) = (n - 1)*n*(3*n^2 - 2*n + 1)/3.
%F a(n) = 5*a(n-1) - 10*a(n-2) + 10*a(n-3) - 5*a(n-4) + a(n-5).
%F G.f.: 2*x^2*(3 + 7*x + 2*x^2)/(1 - x)^5.
%t Table[(n - 1) n (3 n^2 - 2 n + 1)/3, {n, 20}]
%t LinearRecurrence[{5, -10, 10, -5, 1}, {0, 6, 44, 164, 440}, 20]
%t CoefficientList[Series[2 x (3 + 7 x + 2 x^2)/(1 - x)^5, {x, 0, 20}], x]
%K nonn,easy
%O 1,2
%A _Eric W. Weisstein_, Sep 08 2017