A319284
The profiles of the backtrack tree for the n queens problem, triangle read by rows.
Original entry on oeis.org
1, 1, 1, 1, 2, 0, 1, 3, 2, 0, 1, 4, 6, 4, 2, 1, 5, 12, 14, 12, 10, 1, 6, 20, 36, 46, 40, 4, 1, 7, 30, 76, 140, 164, 94, 40, 1, 8, 42, 140, 344, 568, 550, 312, 92, 1, 9, 56, 234, 732, 1614, 2292, 2038, 1066, 352, 1, 10, 72, 364, 1400, 3916, 7552, 9632, 7828, 4040, 724, 1, 11, 90, 536, 2468, 8492, 21362, 37248, 44148, 34774, 15116, 2680
Offset: 0
[1]
[1, 1]
[1, 2, 0]
[1, 3, 2, 0]
[1, 4, 6, 4, 2]
[1, 5, 12, 14, 12, 10]
[1, 6, 20, 36, 46, 40, 4]
[1, 7, 30, 76, 140, 164, 94, 40]
[1, 8, 42, 140, 344, 568, 550, 312, 92]
[1, 9, 56, 234, 732, 1614, 2292, 2038, 1066, 352]
[1, 10, 72, 364, 1400, 3916, 7552, 9632, 7828, 4040, 724]
[1, 11, 90, 536, 2468, 8492, 21362, 37248, 44148, 34774, 15116, 2680]
[1, 12, 110, 756, 4080, 16852, 52856, 120104, 195270, 222720, 160964, 68264, 14200]
- D. E. Knuth, The Art of Computer Programming, Volume 4, Pre-fascicle 5B, Introduction to Backtracking, 7.2.2. Backtrack programming. 2018.
- Peter Luschny, Rows n = 0..19, flattened
- Candida Bowtell and Peter Keevash, The n-queens problem, arXiv:2109.08083 [math.CO] 2021.
- V. Kotesovec, Ways of placing non-attacking queens and kings..., part of "Between chessboard and computer", 1996, pp. 204 - 206.
- Peter Luschny, Julia implementation of the n queens problem with profiles
- Michael Simkin, The number of n-queens configurations, arXiv:2107.13460 [math.CO] 2021.
- Wikipedia, Backtracking
- Wikipedia, Eight queens puzzle
A172201
Number of ways to place 3 nonattacking amazons (superqueens) on an n X n board.
Original entry on oeis.org
0, 0, 0, 0, 48, 424, 1976, 6616, 17852, 41544, 86660, 166288, 298616, 508200, 827168, 1296744, 1968676, 2907016, 4189772, 5910944, 8182400, 11136168, 14926536, 19732600, 25760588, 33246664, 42459476, 53703216, 67320392, 83695144
Offset: 1
- Panos Louridas, idee & form 93/2007, pp. 2936-2938.
- 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 (5,-8,0,14,-14,0,8,-5,1).
-
R:=PowerSeriesRing(Integers(), 40); [0,0,0,0] cat Coefficients(R!( 4*x^5*(12+46*x+60*x^2+32*x^3-23*x^4-13*x^5+7*x^6-x^7)/((1+x)^2*(1-x)^7 ))); // G. C. Greubel, Apr 29 2022
-
CoefficientList[Series[4*x^5*(12+46*x+60*x^2+32*x^3-23*x^4-13*x^5+7*x^6-x^7)/((1+x)^2*(1-x)^7), {x, 0, 40}], x] (* Vincenzo Librandi, May 27 2013 *)
-
[(1/24)*(4*n^6 -40*n^5 +62*n^4 +628*n^3 -2904*n^2 +4074*n -1341 +3*(-1)^n*(2*n-1)) -4*(5*bool(n==1) +2*bool(n==2) -bool(n==3)) for n in (1..40)] # G. C. Greubel, Apr 29 2022
A172207
Number of ways to place 3 nonattacking bishops on a 3 X n board.
Original entry on oeis.org
1, 6, 26, 86, 211, 426, 758, 1234, 1881, 2726, 3796, 5118, 6719, 8626, 10866, 13466, 16453, 19854, 23696, 28006, 32811, 38138, 44014, 50466, 57521, 65206, 73548, 82574, 92311, 102786, 114026, 126058, 138909, 152606, 167176, 182646, 199043, 216394, 234726, 254066
Offset: 1
-
CoefficientList[Series[(2 x^6 + 14 x^3 + 8 x^2 + 2 x + 1) / (x - 1)^4, {x, 0, 50}], x] (* Vincenzo Librandi, May 27 2013 *)
A172221
Number of ways to place 3 nonattacking zebras on a 3 X n board.
Original entry on oeis.org
1, 20, 84, 200, 403, 720, 1180, 1808, 2631, 3676, 4970, 6540, 8413, 10616, 13176, 16120, 19475, 23268, 27526, 32276, 37545, 43360, 49748, 56736, 64351, 72620, 81570, 91228, 101621, 112776, 124720, 137480, 151083, 165556, 180926, 197220
Offset: 1
-
CoefficientList[Series[(2 x^8 - 4 x^7 + 2 x^6 - 8 x^5 + 28 x^4 - 20 x^3 + 10 x^2 + 16 x + 1) / (x - 1)^4, {x, 0, 50}], x] (* Vincenzo Librandi, May 28 2013 *)
A172449
Number of ways to place 8 nonattacking queens on an 8 X n board.
Original entry on oeis.org
0, 0, 0, 0, 0, 0, 0, 92, 1066, 7828, 44148, 195270, 707698, 2211868, 6120136, 15324708, 35312064, 75937606, 153942964, 296590536, 546621416, 968910732, 1659114170, 2754780934, 4449361442, 7009572728, 10796663102, 16292133888
Offset: 1
-
CoefficientList[Series[x^7 (-72 x^31 + 360 x^30 - 360 x^29 - 1320 x^28 + 4208 x^27 - 9064 x^26 + 28358 x^25 - 65290 x^24 + 80160 x^23 - 41550 x^22 - 19482 x^21 + 62314 x^20 - 43912 x^19 - 81620 x^18 + 228424 x^17 - 261720 x^16 + 248114 x^15 - 336290 x^14 + 460564 x^13 - 453438 x^12 + 288474 x^11 - 135252 x^10 + 80270 x^9 - 85476 x^8 + 49676 x^7 - 23614 x^6 - 4768 x^5 - 1794 x^4 - 4344 x^3 - 1546 x^2 - 238 x - 92) / (x - 1)^9, {x, 0, 50}], x] (* Vincenzo Librandi, May 29 2013 *)
A172218
Number of ways to place 3 nonattacking nightriders on a 3 X n board.
Original entry on oeis.org
1, 12, 36, 100, 213, 408, 712, 1148, 1745, 2528, 3524, 4760, 6263, 8060, 10178, 12644, 15485, 18728, 22400, 26528, 31139, 36260, 41918, 48140, 54953, 62384, 70460, 79208, 88655, 98828, 109754, 121460, 133973, 147320, 161528, 176624, 192635
Offset: 1
-
CoefficientList[Series[(2 x^10 - 4 x^9 + 6 x^8 - 4 x^7 - 6 x^6 + 24 x^5 - 18 x^4 + 24 x^3 - 6 x^2 + 8 x + 1) / (x - 1)^4, {x, 0, 50}], x] (* Vincenzo Librandi, May 28 2013 *)
A248944
T(n,k)=Number of length n arrays x(i), i=1..n with x(i) in i..i+k and no value appearing more than 1 time.
Original entry on oeis.org
2, 3, 3, 4, 7, 4, 5, 13, 14, 5, 6, 21, 36, 26, 6, 7, 31, 76, 90, 46, 7, 8, 43, 140, 246, 212, 79, 8, 9, 57, 234, 566, 738, 478, 133, 9, 10, 73, 364, 1146, 2104, 2108, 1044, 221, 10, 11, 91, 536, 2106, 5150, 7364, 5794, 2227, 364, 11, 12, 111, 756, 3590, 11196, 21652, 24720
Offset: 1
A269133
Number of ways to place m nonattacking queens on an m X n board, 1 <= m <= n (triangular array).
Original entry on oeis.org
1, 2, 0, 3, 2, 0, 4, 6, 4, 2, 5, 12, 14, 12, 10, 6, 20, 36, 46, 40, 4, 7, 30, 76, 140, 164, 94, 40, 8, 42, 140, 344, 568, 550, 312, 92, 9, 56, 234, 732, 1614, 2292, 2038, 1066, 352, 10, 72, 364, 1400, 3916, 7552, 9632, 7828, 4040, 724, 11, 90, 536, 2468, 8492, 21362, 37248, 44148, 34774, 15116, 2680, 12, 110, 756, 4080, 16852, 52856, 120104, 195270, 222720, 160964, 68264, 14200
Offset: 1
The triangular array begins:
n\m 1 2 3 4 5 6 7 8 9 10 11 12
1 1
2 2 0
3 3 2 0
4 4 6 4 2
5 5 12 14 12 10
6 6 20 36 46 40 4
7 7 30 76 140 164 94 40
8 8 42 140 344 568 550 312 92
9 9 56 234 732 1614 2292 2038 1066 352
10 10 72 364 1400 3916 7552 9632 7828 4040 724
11 11 90 536 2468 8492 21362 37248 44148 34774 15116 2680
12 12 110 756 4080 16852 52856 120104 195270 222720 160964 68264 14200
...
-
{A269133(m, n, B=[], t=if(#B, setminus(n, Set(concat(B+t=[-#B..-1], B-t))), n=[1..n]))= if(#B < m-1, vecsum([A269133(m, setminus(n, [t]), concat(B,t)) | t<-t]), #t)} \\ M. F. Hasler, Jan 11 2022
A137279
Number of ways of placing ceiling(n/2) nonattacking queens on an n X n Mobius chessboard.
Original entry on oeis.org
1, 4, 0, 16, 40, 192, 560, 3328, 11772, 63840, 259336, 1550976, 7169656, 42410256, 234044160, 1366190592
Offset: 1
Brett Stevens (brett(AT)math.carleton.ca), Mar 13 2008
a(4)=16 because any queen attacks all but two other squares and every solution is counted twice by enumerating all such placements.
Comments