OFFSET
1,5
COMMENTS
For even n, the diagonals do not intersect and there can be no symmetrical solutions. For odd n, a symmetrical solution will have a rook on the central square and the remaining n-1 rooks must be placed so as to avoid the main diagonals. See A292080 for information on counting non-attacking rook configurations with no rook on either main diagonal. - Andrew Howroyd, Sep 12 2017
LINKS
Andrew Howroyd, Table of n, a(n) for n = 1..100
Geoffrey Chase, Checkerboard Problem Solved, Creative Computing 6(1), Jan 1980, 122.
Bahairiv Joshi, Unique Solutions to the Checkerboard Problem, Creative Computing 6(10), Oct 1980, 124-125.
Abijah Reed, Comments on Checkerboard Problem Solved, Creative Computing 6(5), May 1980, 94.
FORMULA
EXAMPLE
The 4 X 4 solution is unique, up to equivalence, with pieces at (1,1), (2,3), (3,4) and (4,2).
MATHEMATICA
sf = Subfactorial;
x[n_] := x[n] = Integrate[If[EvenQ[n], (x^2 - 4*x + 2)^(n/2), (x - 1)*(x^2 - 4*x + 2)^((n - 1)/2)]/E^x, {x, 0, Infinity}];
F[n_ /; EvenQ[n]] := With[{m = n/2}, m*(x[2*m] - (2*m - 3)*x[2*m - 1])];
F[n_ /; OddQ[n]] := With[{m = (n - 1)/2}, (2*m + 1)*x[2*m] + 3*m*x[2*m - 1] - 2*m*(m - 1)*x[2*m - 2]];
d[n_] := (-1)^n HypergeometricPFQ[{1/2, -n}, {}, 2];
R[n_] := If[OddQ[n], 0, If[n == 0, 1, (n - 1)!*2/(n/2 - 1)!]];
a[1] = 1; a[n_] := With[{m = Quotient[n, 2]}, (F[n] + If[EvenQ[n], 0, 2^m * sf[m] + 2*R[m] + 2*d[m] + 2*Boole[m == 0]])/8];
Array[a, 30] (* Jean-François Alcover, Sep 15 2019 *)
PROG
sf(n) = {n! * polcoeff( exp(-x + x * O(x^n)) / (1 - x), n)}
F(n) = {my(v = vector(n)); for(n=4, length(v), v[n] = (n-1)*v[n-1] + 2*if(n%2==1, (n-1)*v[n-2], (n-2)*if(n==4, 1, v[n-4]))); if(n<4, [1, 0, 0][n], if(n%2==0, n*(v[n] - (n-3)*v[n-1]), 2*n*v[n-1] + 3*(n-1)*v[n-2] - (n-1)*(n-3)*v[n-3])/2)}
D(n) = {sum(k=0, n, (-1)^(n-k) * binomial(n, k) * (2*k)!/(2^k*k!))}
R(n) = {if(n%2==1, 0, if(n==0, 1, (n-1)!*2/(n/2-1)!))}
a(n) = {(F(n) + if(n%2==0, 0, my(m=n\2); 2^m * sf(m) + 2*R(m) + 2*D(m) + 2*(m==0)))/8} \\ Andrew Howroyd, Sep 12 2017
CROSSREFS
KEYWORD
nonn
AUTHOR
Jud McCranie, Sep 24 2001
EXTENSIONS
a(11)-a(12) from Lars Blomberg, Jan 13 2013
Name clarified and terms a(13) and beyond from Andrew Howroyd, Sep 12 2017
STATUS
approved