cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-5 of 5 results.

A338562 Number of cyclic diagonal Latin squares of order 2n+1.

Original entry on oeis.org

1, 0, 240, 20160, 0, 319334400, 62270208000, 0, 4979623993344000, 1946321606541312000, 0, 517040334777699532800000, 155112100433309859840000000, 0, 229885811837232250818134016000000, 230239482316981838896315760640000000, 0, 82665183731089159437333210700185600000000
Offset: 0

Views

Author

Eduard I. Vatutin, Nov 02 2020

Keywords

Comments

A cyclic Latin square is a Latin square in which row i is obtained by cyclically shifting row i-1 by d places.
Equivalently, a Latin square is cyclic if and only if each row is a cyclic permutation of the first row and each column is a cyclic permutation of the first column.
Every cyclic diagonal Latin square is a cyclic Latin square, so a(n) <= A338522(2*n+1).
Cyclic diagonal Latin squares exist only for odd orders not divisible by 3. - Andrew Howroyd, May 26 2021

Examples

			For n=3 there are 6 cyclic Latin squares of order 7 with the first row in ascending order, only 4 of them are diagonal:
  0 1 2 3 4 5 6   0 1 2 3 4 5 6   0 1 2 3 4 5 6   0 1 2 3 4 5 6
  2 3 4 5 6 0 1   3 4 5 6 0 1 2   4 5 6 0 1 2 3   5 6 0 1 2 3 4
  4 5 6 0 1 2 3   6 0 1 2 3 4 5   1 2 3 4 5 6 0   3 4 5 6 0 1 2
  6 0 1 2 3 4 5   2 3 4 5 6 0 1   5 6 0 1 2 3 4   1 2 3 4 5 6 0
  1 2 3 4 5 6 0   5 6 0 1 2 3 4   2 3 4 5 6 0 1   6 0 1 2 3 4 5
  3 4 5 6 0 1 2   1 2 3 4 5 6 0   6 0 1 2 3 4 5   4 5 6 0 1 2 3
  5 6 0 1 2 3 4   4 5 6 0 1 2 3   3 4 5 6 0 1 2   2 3 4 5 6 0 1
and 4*7! = 20160 cyclic diagonal Latin squares.
		

Crossrefs

Cf. A123565 (ordered first row), A338522, A341585 (main classes), A342306, A370672.

Programs

  • PARI
    a(n)={my(m=2*n+1); m!*if(gcd(m, 6)==1, sum(k=1, m, gcd(k^3-k, m)==1))} \\ Andrew Howroyd, Apr 30 2021

Formula

a(n) = A123565(2*n+1) * (2*n+1)!.
a(n) = A370672(n) * (2n)!. - Eduard I. Vatutin, Mar 13 2024

Extensions

More terms from Andrew Howroyd, Apr 30 2021
Zero terms for even orders removed by Andrew Howroyd, May 26 2021

A342998 Minimum number of diagonal transversals in a cyclic diagonal Latin square of order 2n+1.

Original entry on oeis.org

1, 0, 5, 27, 0, 4523, 128818, 0, 204330233, 11232045257
Offset: 0

Views

Author

Eduard I. Vatutin, Apr 02 2021

Keywords

Comments

A cyclic Latin square is a Latin square in which row i is obtained by cyclically shifting row i-1 by d places (see A338562, A123565 and A341585).
Cyclic diagonal Latin squares do not exist for even orders.
a(n) <= A342997(n).
All cyclic diagonal Latin squares are diagonal Latin squares, so A287647(n) <= a((n-1)/2).

Examples

			For n=2 one of best cyclic diagonal Latin squares of order 5
  0 1 2 3 4
  2 3 4 0 1
  4 0 1 2 3
  1 2 3 4 0
  3 4 0 1 2
has a(2)=5 diagonal transversals:
  0 . . . .   . 1 . . .   . . 2 . .   . . . 3 .   . . . . 4
  . . 4 . .   . . . 0 .   . . . . 1   2 . . . .   . 3 . . .
  . . . . 3   4 . . . .   . 0 . . .   . . 1 . .   . . . 2 .
  . 2 . . .   . . 3 . .   . . . 4 .   . . . . 0   1 . . . .
  . . . 1 .   . . . . 2   3 . . . .   . 4 . . .   . . 0 . .
		

Crossrefs

A342997 Maximum number of diagonal transversals in a cyclic diagonal Latin square of order 2n+1.

Original entry on oeis.org

1, 0, 5, 27, 0, 4665, 131106, 0, 204995269, 11254190082
Offset: 0

Views

Author

Eduard I. Vatutin, Apr 02 2021

Keywords

Comments

A cyclic Latin square is a Latin square in which row i is obtained by cyclically shifting row i-1 by d places (see A338562, A123565 and A341585).
Cyclic diagonal Latin squares do not exist for even n.
All cyclic diagonal Latin squares are diagonal Latin squares, so a((n-1)/2) <= A287648(n).
All diagonal transversals are transversals, so a(n) <= A006717(n).
A342998 <= a(n).

Examples

			For n=2 one of the best cyclic diagonal Latin squares of order 5
  0 1 2 3 4
  2 3 4 0 1
  4 0 1 2 3
  1 2 3 4 0
  3 4 0 1 2
has a(2)=5 diagonal transversals:
  0 . . . .   . 1 . . .   . . 2 . .   . . . 3 .   . . . . 4
  . . 4 . .   . . . 0 .   . . . . 1   2 . . . .   . 3 . . .
  . . . . 3   4 . . . .   . 0 . . .   . . 1 . .   . . . 2 .
  . 2 . . .   . . 3 . .   . . . 4 .   . . . . 0   1 . . . .
  . . . 1 .   . . . . 2   3 . . . .   . 4 . . .   . . 0 . .
		

Crossrefs

A343866 Number of inequivalent cyclic diagonal Latin squares of order 2n+1 up to rotations, reflections and permutation of symbols.

Original entry on oeis.org

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

Views

Author

Andrew Howroyd, May 02 2021

Keywords

Comments

Also the number of main classes of diagonal Latin squares of order 2n+1 that contain a cyclic Latin square. Compare A341585.

Examples

			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.
		

Crossrefs

Programs

  • 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])))}

Formula

a((p-1)/2) = A341585((p-1)/2) for odd prime p.

A366333 a(n) is the number of distinct numbers of diagonal transversals that a semicyclic diagonal Latin square of order 2n+1 can have.

Original entry on oeis.org

1, 0, 1, 1, 0, 2, 20, 0, 271, 1208, 0
Offset: 0

Views

Author

Eduard I. Vatutin, Oct 07 2023

Keywords

Comments

A horizontally semicyclic diagonal Latin square is a square where each row r(i) is a cyclic shift of the first row r(0) by some value d(i) (see example). A vertically semicyclic diagonal Latin square is a square where each column c(i) is a cyclic shift of the first column c(0) by some value d(i). Cyclic diagonal Latin squares (see A338562) fall under the definition of vertically and horizontally semicyclic diagonal Latin squares simultaneously, in this type of squares each row r(i) is obtained from the previous one r(i-1) using cyclic shift by some value d.
Semicyclic diagonal Latin squares do not exist for even orders n.

Examples

			For n=6*2+1=13 the number of diagonal transversals that a semicyclic diagonal Latin square of order 13 may have is 127339, 127830, 128489, 128519, 128533, 128608, 128751, 128818, 128861, 129046, 129059, 129171, 129243, 129286, 129353, 129474, 129641, 129657, 130323 or 131106. Since there are 20 distinct values, a(6)=20.
		

Crossrefs

Showing 1-5 of 5 results.