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.

A181196 T(n,k) = number of n X k matrices containing a permutation of 1..n*k in increasing order rowwise, columnwise, diagonally and (downwards) antidiagonally.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 5, 4, 1, 1, 1, 14, 29, 8, 1, 1, 1, 42, 290, 169, 16, 1, 1, 1, 132, 3532, 6392, 985, 32, 1, 1, 1, 429, 49100, 352184, 141696, 5741, 64, 1, 1, 1, 1430, 750325, 25097600, 36372976, 3142704, 33461, 128, 1, 1, 1, 4862, 12310294
Offset: 1

Views

Author

R. H. Hardin, Oct 10 2010

Keywords

Comments

Table starts:
.1.1...1......1..........1..............1...................1
.1.1...2......5.........14.............42.................132
.1.1...4.....29........290...........3532...............49100
.1.1...8....169.......6392.........352184............25097600
.1.1..16....985.....141696.......36372976.........14083834704
.1.1..32...5741....3142704.....3777546912.......8092149471168
.1.1..64..33461...69705920...392658046912....4673805856338368
.1.1.128.195025.1546100352.40820345224064.2702482348019033600

Examples

			All solutions for 3 X 4:
..1..2..3..4....1..2..3..4....1..2..3..4....1..2..3..4....1..2..3..4
..5..6..7..8....5..6..7..9....5..6..7.10....5..6..8..9....5..6..8.10
..9.10.11.12....8.10.11.12....8..9.11.12....7.10.11.12....7..9.11.12
...
..1..2..3..6....1..2..3..6....1..2..3..6....1..2..3..6....1..2..3..6
..4..5..7..8....4..5..7..9....4..5..7.10....4..5..8..9....4..5..8.10
..9.10.11.12....8.10.11.12....8..9.11.12....7.10.11.12....7..9.11.12
...
..1..2..4..6....1..2..4..6....1..2..4..6....1..2..4..6....1..2..4..6
..3..5..7..8....3..5..7..9....3..5..7.10....3..5..8..9....3..5..8.10
..9.10.11.12....8.10.11.12....8..9.11.12....7.10.11.12....7..9.11.12
...
..1..2..3..5....1..2..3..5....1..2..3..5....1..2..3..5....1..2..3..5
..4..6..7..8....4..6..7..9....4..6..7.10....4..6..8..9....4..6..8.10
..9.10.11.12....8.10.11.12....8..9.11.12....7.10.11.12....7..9.11.12
...
..1..2..4..5....1..2..4..5....1..2..4..5....1..2..4..5....1..2..4..5
..3..6..7..8....3..6..7..9....3..6..7.10....3..6..8..9....3..6..8.10
..9.10.11.12....8.10.11.12....8..9.11.12....7.10.11.12....7..9.11.12
...
..1..2..3..7....1..2..3..7....1..2..4..7....1..2..4..7
..4..5..8..9....4..5..8.10....3..5..8..9....3..5..8.10
..6.10.11.12....6..9.11.12....6.10.11.12....6..9.11.12
		

Crossrefs

Rows n=1-5 give: A000012, A000108, A181197, A181198, A181199.
Columns 1+2, 3-8 give: A000012, A011782, A001653, A181192, A181193, A181194, A181195.
A227578 is a similar but different array.

Programs

  • Maple
    b:= proc(l) option remember; local n; n:= nops(l);
          `if`({l[]}={0}, 1, add(`if`((i=1 or l[i-1]<=l[i]) and l[i]>
          `if`(i=n, 0, l[i+1]), b(subsop(i=l[i]-1, l)), 0), i=1..n))
        end:
    T:= (n,k)-> b([n$k]):
    seq(seq(T(n, 1+d-n), n=1..d), d=1..12);  # Alois P. Heinz, Jul 24 2012
  • Mathematica
    b[l_List] := b[l] = With[{n = Length[l]}, If[Union[l] == {0}, 1, Sum[If[(i == 1 || l[[i-1]] <= l[[i]]) && l[[i]] > If[i == n, 0, l[[i+1]]], b[ReplacePart[l, i -> l[[i]]-1]], 0], {i, 1, n}]]]; T[n_, k_] := b[Array[n&, k]]; Table[Table[T[n, 1+d-n], {n, 1, d}], {d, 1, 12}] // Flatten (* Jean-François Alcover, Mar 06 2015, after Alois P. Heinz *)

Formula

Empirical column 1: a(n) = a(n-1).
Empirical column 2: a(n) = a(n-1).
Empirical column 3: a(n) = 2*a(n-1).
Empirical column 4: a(n) = 6*a(n-1)-a(n-2).
Empirical column 5: a(n) = 24*a(n-1)-40*a(n-2)-8*a(n-3).
Empirical column 6: a(n) = 120*a(n-1)-1672*a(n-2)+544*a(n-3)-6672*a(n-4) +256*a(n-5).
Empirical column 7: a(n) = 720*a(n-1) -84448*a(n-2) +1503360*a(n-3) -17912224*a(n-4) -318223104*a(n-5) +564996096*a(n-6) +270471168*a(n-7) -11373824*a(n-8) +65536*a(n-9).