OFFSET
1,2
COMMENTS
We say two placements are equivalent if one can be obtained from the other by rotating or reflecting the grid.
The formula was derived by categorizing and counting grid cells into four exclusive categories: central cell (if any); other diagonal cells, other horizontal and vertical midline cells (if any), and all others (in eight triangular regions) (if any); then determining for each category, how many ways a white stone could be placed in each category, given the category in which the black stone was placed prior. The sequence was verified by another program which generated all positions, removed reflections and rotations, and tallied the residue.
LINKS
Index entries for linear recurrences with constant coefficients, signature (2,2,-6,0,6,-2,-2,1).
FORMULA
For odd n, a(n) = n*(n^3 + 3*n - 4)/8.
For even n, a(n) = n*(n^3 + n - 2)/8.
G.f.: -x^2*(x^5+x^4+7*x^3+5*x^2+8*x+2) / ((x-1)^5*(x+1)^3). - Colin Barker, May 21 2014
a(n) = n*(n^3 + n*3^(n mod 2) - 2*2^(n mod 2))/8. - Wesley Ivan Hurt, May 21 2014
MAPLE
A242709:=n->n*(n^3 + n*3^(n mod 2) - 2*2^(n mod 2))/8; seq(A242709(n), n=1..50); # Wesley Ivan Hurt, May 21 2014
MATHEMATICA
f[n_] := If[OddQ[n], (n^3 + 3 n - 4), (n^3 + n - 2)] n/8;
Table[f[n], {n, 1, 40}]
PROG
(PARI) concat(0, Vec(-x^2*(x^5+x^4+7*x^3+5*x^2+8*x+2)/((x-1)^5*(x+1)^3) + O(x^100))) \\ Colin Barker, May 21 2014
(Magma) [n*(n^3 + n*3^(n mod 2) - 2*2^(n mod 2))/8: n in [1..50]]; // Wesley Ivan Hurt, May 21 2014
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
James Stein, May 21 2014
STATUS
approved