OFFSET
1,3
COMMENTS
For a definition and examples of this problem see the comment section of A276449.
The present sequence a(n) gives the number of 2-orbits of such 2-color boards with n squares of one color under C_4.
LINKS
Hong-Chang Wang, Table of n, a(n) for n = 1..100
Hong-Chang Wang, Example for n = 4
FORMULA
EXAMPLE
n = 4: one of the two 2-orbits is (o white, + black)
+ o + o o o o +
o o o o + o o o
o o o o o o o +
o + o + + o o o,
and one can take the first one as a representative.
For n = 3 there are a(3) = 2 2-orbits, represented by
+ o o o o o
o + o and + + +
o o + o o o.
For the 12 2-orbits for n=4, see the representatives given in the link.
MATHEMATICA
Table[(Function[j, Binomial[2 j (j + Boole@ OddQ@ n), j]]@ Floor[n/2] - If[MemberQ[{2, 3}, #], 0, Function[i, Binomial[(2 i) (2 i + #), i]]@ Floor[n/4]] &@ Mod[n, 4])/2, {n, 23}] (* Michael De Vlieger, Sep 07 2016 *)
PROG
(Python)
import math
def nCr(n, r):
f = math.factorial
return f(n) / f(r) / f(n-r)
# main program
for j in range(101):
i = j/2
if j%2==0:
b = nCr(2*i*i, i)
else:
b = nCr(2*i*(i+1), i)
if j%4==0:
c = nCr((j*j/4), (j/4))
elif j%4==1:
c = nCr(((j-1)/2)*((j-1)/2+1), ((j-1)/4))
else:
c = 0
print(str(j)+" "+str((b-c)/2))
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
Edited: Wolfdieter Lang, Oct 02 2016
STATUS
approved