login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A343866
Number of inequivalent cyclic diagonal Latin squares of order 2n+1 up to rotations, reflections and permutation of symbols.
2
1, 0, 1, 1, 0, 2, 3, 0, 4, 4, 0, 5, 3, 0, 7, 7, 0, 2, 9, 0, 10, 10, 0, 11, 7, 0, 13, 4, 0, 14, 15, 0, 6, 16, 0, 17, 18, 0, 8, 19, 0, 20, 8, 0, 22, 10, 0, 8, 24, 0, 25, 25, 0, 26, 27, 0, 28, 10, 0, 14, 22, 0, 13, 31, 0, 32, 16, 0, 34, 34, 0, 20, 14, 0, 37, 37, 0, 14, 39, 0, 20
OFFSET
0,6
COMMENTS
Also the number of main classes of diagonal Latin squares of order 2n+1 that contain a cyclic Latin square. Compare A341585.
FORMULA
a((p-1)/2) = A341585((p-1)/2) for odd prime p.
EXAMPLE
a(12) = 3 since there are A123565(25) = 10 cyclic diagonal Latin squares whose first row is in ascending order. Each of these is uniquely defined by the step between rows and form 5 pairs by horizontal or vertical reflection (negating the step between rows). Up to exchanging rows with columns there are 3 distinct classes, so a(12) = 3.
PROG
(PARI)
iscanon(n, k, g) = k <= vecmin(g*k%n) && k <= vecmin(g*lift(1/Mod(k, n))%n)
a(n)={if(n==0, 1, my(m=2*n+1); sum(k=1, m-1, gcd(m, k)==1 && gcd(m, k-1)==1 && gcd(m, k+1)==1 && iscanon(m, k, [1, -1])))}
CROSSREFS
KEYWORD
nonn
AUTHOR
Andrew Howroyd, May 02 2021
STATUS
approved