A172226
Number of ways to place 3 nonattacking wazirs on an n X n board.
Original entry on oeis.org
0, 0, 22, 276, 1474, 5248, 14690, 35012, 74326, 144544, 262398, 450580, 739002, 1166176, 1780714, 2642948, 3826670, 5420992, 7532326, 10286484, 13830898, 18336960, 24002482, 31054276, 39750854, 50385248, 63287950
Offset: 1
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
- V. Kotesovec, Number of ways of placing non-attacking queens and kings on boards of various sizes
- Eric Weisstein's World of Mathematics, Grid Graph
- Wikipedia, Wazir (chess)
- Index entries for linear recurrences with constant coefficients, signature (7,-21,35,-35,21,-7,1).
-
I:=[0, 0, 22, 276, 1474, 5248, 14690, 35012]; [n le 8 select I[n] else 7*Self(n-1)-21*Self(n-2)+35*Self(n-3)-35*Self(n-4)+21*Self(n-5)-7*Self(n-6)+Self(n-7): n in [1..40]]; // Vincenzo Librandi, Apr 30 2013
-
[0] cat [(n-2)*(n^5+2*n^4-11*n^3-10*n^2+42*n-12)/6: n in [2..30]]; // Vincenzo Librandi, Apr 30 2013
-
A172226:=n->`if`(n=1, 0, (n-2)*(n^5 + 2*n^4 - 11*n^3 - 10*n^2 + 42*n - 12)/6); seq(A172226(n), n=1..60); # Wesley Ivan Hurt, Feb 06 2014
-
CoefficientList[Series[2 x^2 (x^5 - 9 x^4 + 22 x^3 - 2 x^2 - 61 x - 11) / (x-1)^7, {x, 0, 60}], x] (* Vincenzo Librandi, Apr 30 2013 *)
LinearRecurrence[{7,-21,35,-35,21,-7,1},{0,0,22,276,1474,5248,14690,35012},30] (* Harvey P. Dale, Apr 08 2022 *)
A172135
Number of ways to place 4 nonattacking knights on an n X n board.
Original entry on oeis.org
0, 1, 18, 412, 4436, 26133, 111066, 376560, 1080942, 2732909, 6253408, 13204356, 26100160, 48819677, 87137934, 149398608, 247349946, 397168485, 620696612, 946921684, 1413726108, 2069939461, 2977725410, 4215337872
Offset: 1
- E. Bonsdorff, K. Fabel, O. Riihimaa, Schach und Zahl, 1966, p. 51-63
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
- Vaclav Kotesovec, Number of ways of placing non-attacking queens and kings on boards of various sizes
- Index entries for linear recurrences with constant coefficients, signature (9,-36,84,-126,126,-84,36,-9,1).
-
[0,1,18,412,4436] cat [(n^8 -54*n^6 +144*n^5 +1019*n^4 -5232*n^3 -2022*n^2 +51120*n -77184)/24: n in [6..50]]; // G. C. Greubel, Apr 19 2022
-
CoefficientList[Series[x*(1 +9*x +286*x^2 +1292*x^3 -345*x^4 +3099*x^5 -5142*x^6 +3606*x^7 -1162*x^8 -390*x^9 +690*x^10 -312*x^11 +48*x^12)/(1-x)^9, {x, 0, 40}], x] (* Vincenzo Librandi, May 26 2013 *)
-
[0,1,18,412,4436] + [(n^8 -54*n^6 +144*n^5 +1019*n^4 -5232*n^3 -2022*n^2 +51120*n -77184)/24 for n in (6..50)] # G. C. Greubel, Apr 19 2022
A172136
Number of ways to place 5 nonattacking knights on an n X n board.
Original entry on oeis.org
0, 0, 2, 340, 9386, 97580, 649476, 3184708, 12472084, 41199404, 119171110, 309957412, 739123094, 1639655452, 3422020324, 6778432292, 12833460256, 23356032940, 41051290730, 69954580804
Offset: 1
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
- Vaclav Kotesovec, Number of ways of placing non-attacking queens and kings on boards of various sizes
- Index entries for linear recurrences with constant coefficients, signature (11,-55,165,-330,462,-462,330,-165,55,-11,1).
-
CoefficientList[Series[2x^2(74 x^15 -518x^14 +1110x^13 +1046x^12 -11332x^11 + 29950x^10 -42430x^9 +32476x^8 -11684x^7 -1000x^6 +15021x^5 -18443x^4 -6352x^3 - 2878x^2 -159x -1)/(x-1)^11, {x,0,40}], x] (* Vincenzo Librandi, May 02 2013 *)
-
[0,0,2,340,9386,97580,649476] + [(n^10 -90*n^8 +240*n^7 +3235*n^6 - 16320*n^5 -40530*n^4 +396480*n^3 -231656*n^2 -3359520*n +6509280)/120 for n in (8..50)] # G. C. Greubel, Apr 19 2022
A244081
Number T(n,k) of ways to place k nonattacking knights on an n X n board; triangle T(n,k), n>=0, 0<=k<=A030978(n), read by rows.
Original entry on oeis.org
1, 1, 1, 1, 4, 6, 4, 1, 1, 9, 28, 36, 18, 2, 1, 16, 96, 276, 412, 340, 170, 48, 6, 1, 25, 252, 1360, 4436, 9386, 13384, 12996, 8526, 3679, 994, 158, 15, 1, 1, 36, 550, 4752, 26133, 97580, 257318, 491140, 688946, 716804, 556274, 323476, 141969, 47684, 12488, 2560, 393, 40, 2
Offset: 0
T(4,8) = 6:
._______. ._______. ._______. ._______. ._______. ._______.
|_|o|_|o| |o|_|o|_| |o|o|o|o| |o|_|_|o| |o|_|o|o| |o|o|_|o|
|o|_|o|_| |_|o|_|o| |_|_|_|_| |o|_|_|o| |_|_|_|o| |o|_|_|_|
|_|o|_|o| |o|_|o|_| |_|_|_|_| |o|_|_|o| |o|_|_|_| |_|_|_|o|
|o|_|o|_| |_|o|_|o| |o|o|o|o| |o|_|_|o| |o|o|_|o| |o|_|o|o| .
.
Triangle T(n,k) begins:
1;
1, 1;
1, 4, 6, 4, 1;
1, 9, 28, 36, 18, 2;
1, 16, 96, 276, 412, 340, 170, 48, 6;
1, 25, 252, 1360, 4436, 9386, 13384, 12996, 8526, 3679, 994, 158, 15, 1;
...
As independence polynomials:
1
1 + x
1 + 4*x + 6*x^2 + 4*x^3 + x^4
1 + 9*x + 28*x^2 + 36*x^3 + 18*x^4 + 2*x^5
1 + 16*x + 96*x^2 + 276*x^3 + 412*x^4 + 340*x^5 + 170*x^6 + 48*x^7 + 6*x^8
...
-
b:= proc(n, l) option remember; local d, f, g, k;
d:= nops(l)/3; f:=false;
if n=0 then 1
elif l[1..d]=[f$d] then b(n-1, [l[d+1..3*d][], true$d])
else for k while not l[k] do od; g:= subsop(k=f, l);
if k>1 then g:=subsop(2*d-1+k=f, g) fi;
if k2 then g:=subsop( d-2+k=f, g) fi;
if k(p->seq(coeff(p, x, i), i=0..degree(p)))(b(n, [true$(n*3)])):
seq(T(n), n=0..7);
-
b[n_, l_] := b[n, l] = Module[{d, f, g, k}, d = Length[l]/3; f = False; Which[n == 0, 1, l[[1 ;; d]] == Array[f&, d], b[n - 1, Join[l[[d + 1 ;; 3*d]], Array[True&, d]]], True, For[k = 1, !l[[k]], k++]; g = ReplacePart[l, k -> f];
If [k > 1, g = ReplacePart[g, 2*d - 1 + k -> f]];
If [k < d, g = ReplacePart[g, 2*d + 1 + k -> f]];
If [k > 2, g = ReplacePart[ g, d - 2 + k -> f]];
If [k < d - 1, g = ReplacePart[g, d + 2 + k -> f]];
Expand[b[n, ReplacePart[l, k -> f]] + b[n, g]*x]]];
T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 0, Exponent[p, x]}]][
b[n, Array[True&, n*3]]];
Table[T[n], {n, 0, 7}] // Flatten (* Jean-François Alcover, Mar 28 2016, after Alois P. Heinz *)
Table[Count[IndependentVertexSetQ[KnightTourGraph[n, n], #] & /@ Subsets[Range[n^2], {k}], True], {n, 4}, {k, 0, If[n == 2, 4, (1 - (-1)^n + 2 n^2)/4]}] // Flatten (* Eric W. Weisstein, May 05 2017 *)
A201540
Number of ways to place n nonattacking knights on an n X n board.
Original entry on oeis.org
1, 6, 36, 412, 9386, 257318, 8891854, 379978716, 19206532478, 1120204619108, 74113608972922, 5483225594409823, 448414229054798028, 40154319792412218900, 3906519894750904583838
Offset: 1
-
b[n_, l_] := b[n, l] = Module[{d, f, g, k}, d = Length[l]/3; f = False; Which[n == 0, 1, l[[1 ;; d]] == Array[f&, d], b[n - 1, Join[l[[d + 1 ;; 3*d]], Array[True&, d]]], True, For[k = 1, ! l[[k]], k++]; g = ReplacePart[l, k -> f];
If[k > 1, g = ReplacePart[g, 2*d - 1 + k -> f]];
If[k < d, g = ReplacePart[g, 2*d + 1 + k -> f]];
If[k > 2, g = ReplacePart[g, d - 2 + k -> f]];
If[k < d - 1, g = ReplacePart[g, d + 2 + k -> f]];
Expand[b[n, ReplacePart[l, k -> f]] + b[n, g]*x]]];
T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 0, Exponent[p, x]}]][ b[n, Array[True&, n*3]]];
a[n_] := T[n][[n + 1]];
Table[an = a[n]; Print["a(", n, ") = ", an]; an, {n, 1, 10}] (* Jean-François Alcover, Mar 29 2016, after Alois P. Heinz's code for A244081 *)
A172212
Number of ways to place 3 nonattacking knights on a 3 X n board.
Original entry on oeis.org
1, 12, 36, 100, 233, 456, 796, 1280, 1935, 2788, 3866, 5196, 6805, 8720, 10968, 13576, 16571, 19980, 23830, 28148, 32961, 38296, 44180, 50640, 57703, 65396, 73746, 82780, 92525, 103008, 114256, 126296, 139155, 152860, 167438, 182916, 199321
Offset: 1
-
CoefficientList[Series[(6 x^6 - 8 x^5 + 2 x^4 + 24 x^3 - 6 x^2 + 8 x + 1) / (x - 1)^4, {x, 0, 50}], x] (* Vincenzo Librandi, May 27 2013 *)
A172138
Number of ways to place 3 nonattacking zebras on an n X n board.
Original entry on oeis.org
0, 4, 84, 452, 1772, 5596, 14888, 34640, 72712, 140716, 255036, 437968, 718980, 1136092, 1737376, 2582576, 3744848, 5312620, 7391572, 10106736, 13604716, 18056028, 23657560, 30635152, 39246296, 49782956, 62574508, 77990800
Offset: 1
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
- Vaclav Kotesovec, Number of ways of placing non-attacking queens and kings on boards of various sizes
- Index entries for linear recurrences with constant coefficients, signature (7,-21,35,-35,21,-7,1).
-
[0,4,84,452,1772] cat [(n^6 -27*n^4 +120*n^3 +74*n^2 -1608*n +2976)/6: n in [6..50]]; // G. C. Greubel, Apr 19 2022
-
CoefficientList[Series[4x(1+14*x-13*x^2+58*x^3-29*x^4-9*x^5+x^6+ 33*x^7- 45*x^8 +23*x^9-4*x^10)/(1-x)^7, {x, 0, 40}], x] (* Vincenzo Librandi, May 27 2013 *)
LinearRecurrence[{7,-21,35,-35,21,-7,1},{0,4,84,452,1772,5596,14888,34640,72712,140716,255036,437968},30] (* Harvey P. Dale, Mar 11 2023 *)
-
[0,4,84,452,1772]+[(n^6 -27*n^4 +120*n^3 +74*n^2 -1608*n +2976)/6 for n in (6..50)] # G. C. Greubel, Apr 19 2022
A172530
Number of ways to place 3 nonattacking knights on an n X n toroidal board.
Original entry on oeis.org
0, 0, 6, 208, 600, 3252, 10584, 27584, 61992, 125300, 233772, 409584, 682084, 1089172, 1678800, 2510592, 3657584, 5208084, 7267652, 9961200, 13435212, 17860084, 23432584, 30378432, 38955000, 49454132, 62205084
Offset: 1
-
CoefficientList[Series[- 2 x^2 (50 x^9 - 398 x^8 + 1425 x^7 - 2989 x^6 + 3971 x^5 - 3325 x^4 + 1605 x^3 - 365 x^2 + 83 x + 3) / (x - 1)^7, {x, 0, 40}], x] (* Vincenzo Librandi, May 29 2013 *)
A173429
Number of ways to place 3 nonattacking nightriders on an n X n board.
Original entry on oeis.org
0, 4, 36, 276, 1152, 3920, 10568, 25348, 53848, 106292, 194732, 339416, 562652, 899796, 1388008, 2083908, 3044992, 4356344, 6102144, 8404204, 11380564, 15199100, 20019856, 26067112, 33551812, 42766092, 53981600, 67570804
Offset: 1
- Vincenzo Librandi, Table of n, a(n) for n = 1..1000
- Christopher R. H. Hanusa, T Zaslavsky, S Chaiken, A q-Queens Problem. IV. Queens, Bishops, Nightriders (and Rooks), arXiv preprint arXiv:1609.00853 [math.CO], 2016.
- V. Kotesovec, Number of ways of placing non-attacking queens and kings on boards of various sizes
- Wikipedia, Nightrider (chess)
- Index entries for linear recurrences with constant coefficients, signature (2, 0, -1, 0, -2, 2, 0, 1, 0, 0, -3, 0, 2, 0, 4, -4, 0, -2, 0, 3, 0, 0, -1, 0, -2, 2, 0, 1, 0, -2, 1).
-
CoefficientList[Series[-(36 x^29 + 124 x^28 + 496 x^27 + 1128 x^26 + 2632 x^25 + 4280 x^24 + 7160 x^23 + 9296 x^22 + 12936 x^21 + 14828 x^20 + 18828 x^19 + 20164 x^18 + 23820 x^17 + 23684 x^16 + 25460 x^15 + 22972 x^14 + 22412 x^13 + 18532 x^12 + 16820 x^11 + 12996 x^10 + 10912 x^9 + 7552 x^8 + 5428 x^7 + 3012 x^6 + 1652 x^5 + 604 x^4 + 204 x^3 + 28 x^2 + 4 x) / ((x + 1)^4 (x - 1)^7 (x^2 + 1) (x^2 + x + 1) (x^8 + x^6 + x^4 + x^2 + 1)^2), {x, 0, 50}], x] (* Vincenzo Librandi, May 30 2013 *)
LinearRecurrence[{2,0,-1,0,-2,2,0,1,0,0,-3,0,2,0,4,-4,0,-2,0,3,0,0,-1,0,-2,2,0,1,0,-2,1},{0,4,36,276,1152,3920,10568,25348,53848,106292,194732,339416,562652,899796,1388008,2083908,3044992,4356344,6102144,8404204,11380564,15199100,20019856,26067112,33551812,42766092,53981600,67570804,83876732,103365728,126463668},30] (* Harvey P. Dale, Dec 27 2015 *)
A243718
Number of inequivalent (mod D_8) ways to place 3 nonattacking knights on an n X n board.
Original entry on oeis.org
1, 9, 40, 195, 618, 1751, 4075, 8794, 17015, 31268, 53666, 88781, 140200, 215405, 320013, 465436, 659965, 920114, 1257580, 1695303, 2249206, 2950131, 3819135, 4896590, 6209683, 7810096, 9732230, 12041009, 14779220, 18027113, 21837121, 26307056, 31500345
Offset: 2
- Heinrich Ludwig, Table of n, a(n) for n = 2..1000
- Index entries for linear recurrences with constant coefficients, signature (3,1,-11,6,14,-14,-6,11,-1,-3,1).
-
Drop[CoefficientList[Series[-25 - 8*x + 3*x^3 + (25 - 67*x - 48*x^2 + 270*x^3 - 41*x^4 - 318*x^5 + 291*x^6 + 354*x^7 - 188*x^8 - 87*x^9 + 49*x^10) / ((1-x)^7*(1+x)^4), {x, 0, 20}], x],2] (* Vaclav Kotesovec, Jun 19 2014 *)
Showing 1-10 of 12 results.
Comments