OFFSET
0,2
LINKS
Andrew Howroyd, Table of n, a(n) for n = 0..25
FORMULA
a(n) = (1/8)*(3^(n^2) + 2*3^(n^2/4) + 3*3^(n^2/2) + 2*3^((n^2+n)/2)) if n is even;
a(n) = (1/8)*(3^(n^2) + 2*3^((n^2+3)/4) + 3^((n^2+1)/2) + 4*3^((n^2+n)/2)) if n is odd. [corrected by Chris Hallstrom, Mar 22 2021]
MATHEMATICA
Join[{1, 3}, Table[CycleIndexPolynomial[
GraphData[{"Grid", {n, n}}, "AutomorphismGroup"],
Table[Subscript[s, i], {i, 1, 4}]] /.
Table[Subscript[s, i] -> 3, {i, 1, 4}], {n, 2, 10}]]
(* Geoffrey Critzer, Aug 09 2016 *)
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Vladeta Jovovic, May 15 2000
EXTENSIONS
Terms a(10) and beyond from Andrew Howroyd, Apr 15 2021
STATUS
approved