A035005 Number of possible queen moves on an n X n chessboard.
0, 12, 56, 152, 320, 580, 952, 1456, 2112, 2940, 3960, 5192, 6656, 8372, 10360, 12640, 15232, 18156, 21432, 25080, 29120, 33572, 38456, 43792, 49600, 55900, 62712, 70056, 77952, 86420, 95480, 105152, 115456, 126412, 138040, 150360
Offset: 1
Examples
3 X 3 board: queen has 8*6 moves and 1*8 moves, so a(3)=56.
Links
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
- Milan Janjic and Boris Petkovic, A Counting Function, arXiv preprint arXiv:1301.4550 [math.CO], 2013. - From _N. J. A. Sloane_, Feb 13 2013
- Index entries for linear recurrences with constant coefficients, signature (4,-6,4,-1).
Crossrefs
Programs
-
Magma
[(n-1)*2*n^2 + (4*n^3-6*n^2+2*n)/3: n in [1..40]]; // Vincenzo Librandi, Jun 16 2011
-
Mathematica
Table[(n-1)2n^2+(4n^3-6n^2+2n)/3,{n,40}] (* or *) LinearRecurrence[ {4,-6,4,-1},{0,12,56,152},40] (* Harvey P. Dale, Aug 24 2011 *)
Formula
a(n) = (n-1)*2*n^2 + (4*n^3-6*n^2+2*n)/3.
a(n) = 4 * A162147(n-1). - Johannes W. Meijer, Feb 04 2010
a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4); a(0)=0, a(1)=12, a(2)=56, a(3)=152. - Harvey P. Dale, Aug 24 2011
From Colin Barker, Mar 11 2012: (Start)
a(n) = 2*n*(1-6*n+5*n^2)/3.
G.f.: 4*x^2*(3+2*x)/(1-x)^4. (End)
E.g.f.: 2*exp(x)*x^2*(9 + 5*x)/3. - Stefano Spezia, Jul 31 2022
Extensions
More terms from Erich Friedman
Comments