Rooks Problem

DOWNLOAD Mathematica Notebook RooksMax

The rook is a chess piece that may move any number of spaces either horizontally or vertically per move. The maximum number of nonattacking rooks that may be placed on an n×n chessboard is n. This arrangement is achieved by placing the rooks along the diagonal (Madachy 1979). The total number of ways of placing n nonattacking rooks on an n×n board is n! (Madachy 1979, p. 47). In general, the polynomial

 R_(mn)(x)=sum_(k)r_k^((m,n))x^k

whose coefficients r_k^((m,n)) give the numbers of ways k nonattacking rooks can be placed on an m×n chessboard is called a rook polynomial.

The number of rotationally and reflectively inequivalent ways of placing n nonattacking rooks on an n×n board are 1, 2, 7, 23, 115, 694, ... (OEIS A000903; Dudeney 1970, p. 96; Madachy 1979, pp. 46-54).

The minimum number of rooks needed to occupy or attack all spaces on an 8×8 chessboard is 8 (Madachy 1979), arranged in the same orientation as above.

Consider an n×n chessboard with the restriction that, for every subset of {1,...,n}, a rook may not be put in column s+j (mod n) when on row j, where the rows are numbered 0, 1, ..., n-1. Vardi (1991) denotes the number of rook solutions so restricted as rook(s,n). rook({1},n) is simply the number of derangements on n symbols, known as a subfactorial. The first few values are 1, 2, 9, 44, 265, 1854, ... (OEIS A000166). rook({1,2},n) is a solution to the married couples problem, sometimes known as ménage numbers. The first few ménage numbers are 0, 0, 1, 2, 13, 80, 579, ... (OEIS A000179).

Although simple formulas are not known for general {1,...,p}, recurrence relations can be used to compute rook({1,...,p},n) in polynomial time for p=3, ..., 6 (Metropolis et al. 1969, Minc 1978, Vardi 1991).

Wolfram Web Resources

Mathematica »

The #1 tool for creating Demonstrations and anything technical.

Wolfram|Alpha »

Explore anything with the first computational knowledge engine.

Wolfram Demonstrations Project »

Explore thousands of free applications across science, mathematics, engineering, technology, business, art, finance, social sciences, and more.

Computerbasedmath.org »

Join the initiative for modernizing math education.

Online Integral Calculator »

Solve integrals with Wolfram|Alpha.

Step-by-step Solutions »

Walk through homework problems step-by-step from beginning to end. Hints help you try the next step on your own.

Wolfram Problem Generator »

Unlimited random practice problems and answers with built-in Step-by-step solutions. Practice online or make a printable study sheet.

Wolfram Education Portal »

Collection of teaching and learning tools built by Wolfram education experts: dynamic textbook, lesson plans, widgets, interactive Demonstrations, and more.

Wolfram Language »

Knowledge-based programming for everyone.