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-1 of 1 results.

A039917 Number of orderings of 1,2,...,n^2 in an n X n matrix such that each row, each column and both diagonals are increasing.

Original entry on oeis.org

1, 1, 9, 2017, 21569213, 17835527619513, 1677123511579177202174, 24742950249259362969953039657613, 75512002909758683196631913316950684079768626, 60752021865167494642984305761115275381534124800396484901989, 15991585283632910454908797943467512732011897255095362833558749286619895509557
Offset: 1

Views

Author

Keywords

Examples

			From _Alois P. Heinz_, Jul 23 2012: (Start)
a(2) = 1:  [1, 3]
           [2, 4].
a(3) = 9:
[1, 4, 7]  [1, 3, 7]  [1, 2, 7]  [1, 4, 6]  [1, 3, 6]
[2, 5, 8]  [2, 5, 8]  [3, 5, 8]  [2, 5, 8]  [2, 5, 8]
[3, 6, 9]  [4, 6, 9]  [4, 6, 9]  [3, 7, 9]  [4, 7, 9]
.
[1, 2, 6]  [1, 4, 6]  [1, 3, 6]  [1, 2, 6]
[3, 5, 8]  [2, 5, 7]  [2, 5, 7]  [3, 5, 7]
[4, 7, 9]  [3, 8, 9]  [4, 8, 9]  [4, 8, 9]. (End)
		

Crossrefs

Programs

  • Maple
    b:= proc(l) option remember; local n; n:= nops(l); `if`({l[]}={0},
          1, add(`if`((l[i]-1<>n-i or i=1 or l[i-1]-1<=n-i) and l[i]>
          `if`(i=n, 0, l[i+1]), b(subsop(i=l[i]-1, l)), 0), i=1..n))
        end:
    a:= n-> b([n$n]):
    seq(a(n), n=1..8);  # Alois P. Heinz, Jul 23 2012
  • Mathematica
    b[l_List] := b[l] = Module[{n = Length[l]}, If[Union[l] == {0}, 1, Sum[If[ (l[[i]]-1 != n-i || i == 1 || l[[i-1]]-1 <= n-i) && l[[i]] > If[i == n, 0, l[[i+1]]], b[ReplacePart[l, i -> l[[i]]-1]], 0], {i, 1, n}]]];
    a[n_] := b[Table[n, {n}]];
    Array[a, 8] (* Jean-François Alcover, Nov 08 2020, after Alois P. Heinz *)

Extensions

One more term from Jud McCranie, Aug 09 2001
a(6)-a(13) from Alois P. Heinz, Jul 23 2012
Showing 1-1 of 1 results.