cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-9 of 9 results.

A061993 Number of ways to place 7 nonattacking queens on a 7 X n board.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 40, 312, 2038, 9632, 37248, 120104, 335010, 835056, 1897702, 3998456, 7907094, 14818300, 26512942, 45562852, 75580634, 121520020, 190031678, 289879092, 432420154, 632159540, 907376502, 1280833348
Offset: 0

Views

Author

Antonio G. Astudillo (afg_astudillo(AT)hotmail.com), Jun 10 2001

Keywords

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[2*x^7*(20-4*x+331*x^2-88*x^3+1292*x^4-1356*x^5+2019*x^6 +264*x^7-2857*x^8+6472*x^9-7616*x^10+7462*x^11-7831*x^12+8326*x^13-5672*x^14 +1998*x^15-308*x^16-142*x^17+510*x^18-284*x^19-220*x^20+320*x^21-140*x^22 +24*x^23)/(1-x)^8, {x, 0, 40}], x] (* Vincenzo Librandi, May 12 2013 *)
  • SageMath
    def p(x): return 20-4*x+331*x^2-88*x^3+1292*x^4-1356*x^5+2019*x^6 +264*x^7-2857*x^8+6472*x^9-7616*x^10+7462*x^11-7831*x^12+8326*x^13-5672*x^14 +1998*x^15-308*x^16-142*x^17+510*x^18-284*x^19-220*x^20+320*x^21-140*x^22 +24*x^23
    [( 2*x^7*p(x)/(1-x)^8 ).series(x,n+1).list()[n] for n in (0..40)] # G. C. Greubel, Apr 29 2022

Formula

Explicit formula (V. Kotesovec, 1992): a(n) = n^7 - 63*n^6 + 1879*n^5 - 34411*n^4 + 417178*n^3 - 3336014*n^2 + 16209916*n - 36693996, n >= 23.
Recurrence: a(n) = 8*a(n-1) - 28*a(n-2) + 56*a(n-3) - 70*a(n-4) + 56*a(n-5) - 28*a(n-6) + 8*a(n-7) - a(n-8), n >= 31.
G.f.: 2*x^7*(20 - 4*x + 331*x^2 - 88*x^3 + 1292*x^4 - 1356*x^5 + 2019*x^6 + 264*x^7 - 2857*x^8 + 6472*x^9 - 7616*x^10 + 7462*x^11 - 7831*x^12 + 8326*x^13 - 5672*x^14 + 1998*x^15 - 308*x^16 - 142*x^17 + 510*x^18 - 284*x^19 - 220*x^20 + 320*x^21 - 140*x^22 + 24*x^23)/(1 - x)^8.

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

Views

Author

Peter Luschny, Sep 16 2018

Keywords

Comments

The profile (p_0, p_1, ..., p_n) is the number of nodes at each level of the tree.

Examples

			[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]
		

References

  • D. E. Knuth, The Art of Computer Programming, Volume 4, Pre-fascicle 5B, Introduction to Backtracking, 7.2.2. Backtrack programming. 2018.

Crossrefs

Cf. A000170 (T(n,n)), A319283 (row sums), A319288 (indices of the row maxima).
Cf. A000012 (col. 0), A000027 (col. 1), A002378 (col. 2), A061989 and A079908 (col. 3), A061990 (col. 4), A061991 (col. 5), A061992 (col. 6), A061993 (col. 7), A172449 (col. 8).

Programs

  • Julia
    # See the link section.

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

Views

Author

Vaclav Kotesovec, Feb 03 2010

Keywords

Crossrefs

Programs

  • Mathematica
    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 *)

Formula

a(n) = n^8 - 84*n^7 + 3378*n^6 - 85078*n^5 + 1467563*n^4 - 17723656*n^3 + 145910074*n^2 - 745654756*n + 1802501048, for n >= 31. - Vaclav Kotesovec, Feb 03 2010
G.f.: x^8*(-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. - Vaclav Kotesovec, Mar 20 2010

A172205 Number of ways to place 6 nonattacking kings on a 6 X n board.

Original entry on oeis.org

0, 0, 16, 408, 8544, 62266, 291908, 1021254, 2916232, 7179314, 15790572, 31795390, 59638832, 105546666, 177953044, 287974838, 449932632, 681918370, 1006409660, 1450930734, 2048760064, 2839684634, 3870800868, 5197362214, 6883673384
Offset: 1

Views

Author

Vaclav Kotesovec, Jan 29 2010

Keywords

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[-2 x^2 (475 x^8 - 1015 x^7 + 4398 x^6 + 194 x^5 + 10875 x^4 + 5233 x^3 + 3012 x^2 + 148 x + 8) / (x - 1)^7, {x, 0, 50}], x] (* Vincenzo Librandi, May 27 2013 *)

Formula

a(n) = 2*(162n^6-3240n^5+29160n^4-151830n^3+483798n^2-895085n+749335)/5, n>=5.
G.f.: -2*x^3*(475*x^8-1015*x^7+4398*x^6+194*x^5+10875*x^4+5233*x^3+3012*x^2 +148*x+8)/(x-1)^7. - Vaclav Kotesovec, Mar 24 2010

A172215 Number of ways to place 6 nonattacking knights on a 6 X n board.

Original entry on oeis.org

1, 58, 729, 8830, 60285, 257318, 858262, 2404448, 5879329, 12927182, 26115008, 49238436, 87675623, 148787822, 242366502, 381127124, 581249573, 862965246, 1251190796, 1776208532, 2474393475, 3388987070, 4570917554, 6079666980
Offset: 1

Views

Author

Vaclav Kotesovec, Jan 29 2010

Keywords

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[-(104 x^15 - 116 x^14 - 1328 x^13 + 3992 x^12 + 806 x^11 - 16380 x^10 + 27343 x^9 - 4845 x^8 - 15537 x^7 + 38275 x^6 - 2753 x^5 + 11789 x^4 + 4910 x^3 + 344 x^2 + 51 x + 1) / (x - 1)^7, {x, 0, 50}], x] (* Vincenzo Librandi, May 27 2013 *)
    LinearRecurrence[{7,-21,35,-35,21,-7,1},{1,58,729,8830,60285,257318,858262,2404448,5879329,12927182,26115008,49238436,87675623,148787822,242366502,381127124},30] (* Harvey P. Dale, Dec 31 2022 *)

Formula

a(n) = (648n^6-11340n^5+103770n^4-606645n^3+2328317n^2-5466660n+6051720)/10, n>=10.
G.f.: -x * (104*x^15 -116*x^14 -1328*x^13 +3992*x^12 +806*x^11 -16380*x^10 +27343*x^9 -4845*x^8 -15537*x^7 +38275*x^6 -2753*x^5 +11789*x^4 +4910*x^3 +344*x^2 +51*x +1) / (x-1)^7. - Vaclav Kotesovec, Mar 25 2010
a(n) = 7*a(n-1) - 21*a(n-2) + 35*a(n-3) - 35*a(n-4) + 21*a(n-5) - 7*a(n-6) + a(n-7). - Wesley Ivan Hurt, Apr 16 2023

A172232 Number of ways to place 6 nonattacking wazirs on a 6 X n board.

Original entry on oeis.org

0, 2, 504, 10010, 78052, 368868, 1280832, 3612344, 8774380, 19049692, 37898664, 70311824, 123209012, 205885204, 330502992, 512631720, 771833276, 1132294540, 1623506488, 2280989952, 3147068036, 4271685188, 5713272928, 7539662232, 9829042572, 12670967612
Offset: 1

Views

Author

Vaclav Kotesovec, Jan 29 2010

Keywords

Comments

Wazir is a (fairy chess) leaper [0,1].

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[- 2 x (3 x^9 - 5 x^8 + 100 x^7 + 354 x^6 + 2548 x^5 + 7572 x^4 + 9248 x^3 + 3262 x^2 + 245 x + 1) / (x - 1)^7, {x, 0, 50}], x] (* Vincenzo Librandi, May 28 2013 *)

Formula

a(n) = 2*(486*n^6 -5670*n^5 +30240*n^4 -95230*n^3 +187899*n^2 -220775*n +120540) / 15, n>=5.
G.f.: -2*x^2 * (3*x^9 -5*x^8 +100*x^7 +354*x^6 +2548*x^5 +7572*x^4 +9248*x^3 +3262*x^2 +245*x +1) / (x-1)^7. - Vaclav Kotesovec, Mar 25 2010

A172211 Number of ways to place 6 nonattacking bishops on a 6 X n board.

Original entry on oeis.org

1, 16, 313, 2320, 12160, 53744, 209428, 683524, 1905625, 4664384, 10297579, 20907590, 39664250, 71114916, 121559433, 199459466, 315906248, 485124352, 725031335, 1057839684, 1510706686, 2116429956, 2914190277, 3950340692
Offset: 1

Views

Author

Vaclav Kotesovec, Jan 29 2010

Keywords

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[-(2 x^30 - 6 x^29 + 14 x^28 - 26 x^27 + 44 x^26 - 220 x^25 + 596 x^24 - 1060 x^23 + 1654 x^22 - 2266 x^21 + 5622 x^20 - 13570 x^19 + 19848 x^18 - 22392 x^17 + 24048 x^16 - 30525 x^15 + 57673 x^14 - 80154 x^13 + 61962 x^12 - 30874 x^11 + 25832 x^10 - 9360 x^9 + 16960 x^8 - 4710 x^7 + 18006 x^6 + 6928 x^5 + 1968 x^4 + 430 x^3 + 222 x^2 + 9 x + 1) / (x - 1)^7, {x, 0, 50}], x] (* Vincenzo Librandi, May 27 2013 *)

Formula

a(n) = (648n^6-17820n^5+240930n^4-2011545n^3+10806047n^2-35094560n+53430940)/10, n>=25.
For any fixed value of k > 1, a(n) = 1/k!*(kn)^k - (2k-1)/2/(k-2)!*(kn)^(k-1) + ...
G.f.: -x*(2*x^30-6*x^29+14*x^28-26*x^27+44*x^26-220*x^25+596*x^24-1060*x^23+1654*x^22
-2266*x^21+5622*x^20-13570*x^19+19848*x^18-22392*x^17+24048*x^16-30525*x^15+57673*x^14
-80154*x^13+61962*x^12-30874*x^11+25832*x^10-9360*x^9+16960*x^8-4710*x^7+18006*x^6+6928*x^5
+1968*x^4+430*x^3+222*x^2+9*x+1)/(x-1)^7. - Vaclav Kotesovec, Mar 25 2010

A172224 Number of ways to place 6 nonattacking zebras on a 6 X n board.

Original entry on oeis.org

1, 924, 8989, 37270, 145233, 525796, 1605490, 4136952, 9435413, 19632414, 37957424, 69050898, 119351315, 197524064, 314935542, 486171662, 729604121, 1068003424, 1529198580, 2146783422, 2960869583, 4018886128, 5376425842
Offset: 1

Views

Author

Vaclav Kotesovec, Jan 29 2010

Keywords

Comments

Zebra is a (fairy chess) leaper [2,3].

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[-(32 x^20 - 48 x^19 - 84 x^18 - 1004 x^17 + 3350 x^16 - 802 x^15 + 3364 x^14 - 32132 x^13 + 42540 x^12 + 3538 x^11 + 10674 x^10 - 126767 x^9 + 151663 x^8 - 20769 x^7 - 34421 x^6 + 9539 x^5 + 40807 x^4 - 6284 x^3 + 2542 x^2 + 917 x + 1) / (x - 1)^7, {x, 0, 50}], x] (* Vincenzo Librandi, May 28 2013 *)

Formula

a(n) = (1944n^6-27540n^5+227070n^4-1222555n^3+4366071n^2-9580580n+9925860)/30, n>=15.
For any fixed value of k > 1, a(n) = 1/k!*(kn)^k - (k-1)(9k-20)/2/k!*(kn)^(k-1) + ...
G.f.: -x * (32*x^20 -48*x^19 -84*x^18 -1004*x^17 +3350*x^16 -802*x^15 +3364*x^14 -32132*x^13 +42540*x^12 +3538*x^11 +10674*x^10 -126767*x^9 +151663*x^8 -20769*x^7 -34421*x^6 +9539*x^5 +40807*x^4 -6284*x^3 +2542*x^2 +917*x +1) / (x-1)^7. - Vaclav Kotesovec, Mar 25 2010

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

Views

Author

Marko Riedel, Feb 19 2016

Keywords

Examples

			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
...
		

Crossrefs

Cf. A000027 (m=1), A002378 (m=2), A061989 (m=3), A061990 (m=4), A061991 (m=5), A061992 (m=6), A061993 (m=7), A172449 (m=8).
Cf. A036464 (2Q), A047659 (3Q), A061994 (4Q), A108792 (5Q), A176186 (6Q).
Cf. A006717, A051906, A319284 (backtrack trees).

Programs

  • PARI
    {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
Showing 1-9 of 9 results.