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.

A181191 Number of n X n matrices containing a permutation of 1..n*n in increasing order rowwise, columnwise, diagonally and (downwards) antidiagonally.

This page as a plain text file.
%I A181191 #22 May 10 2022 05:30:16
%S A181191 1,1,4,169,141696,3777546912,4673805856338368,
%T A181191 368253691037579094795185,2426023001499238992505630883146240,
%U A181191 1697356437632520242875237327471631991584394752,156101219875805260212264222801658705937606174957553142873088
%N A181191 Number of n X n matrices containing a permutation of 1..n*n in increasing order rowwise, columnwise, diagonally and (downwards) antidiagonally.
%H A181191 Alois P. Heinz, <a href="/A181191/b181191.txt">Table of n, a(n) for n = 1..20</a>
%e A181191 All solutions for 3 X 3:
%e A181191 ..1..2..3....1..2..3....1..2..4....1..2..4
%e A181191 ..4..5..6....4..5..7....3..5..6....3..5..7
%e A181191 ..7..8..9....6..8..9....7..8..9....6..8..9
%p A181191 b:= proc(l) option remember; local n; n:= nops(l);
%p A181191       `if`({l[]}={0}, 1, add(`if`((i=1 or l[i-1]<=l[i]) and l[i]>
%p A181191       `if`(i=n, 0, l[i+1]), b(subsop(i=l[i]-1, l)), 0), i=1..n))
%p A181191     end:
%p A181191 a:= n-> b([n$n]):
%p A181191 seq(a(n), n=1..10);  # _Alois P. Heinz_, Jul 24 2012
%t A181191 b[l_] := b[l] = With[{n = Length[l]},
%t A181191    If[Union[l]=={0}, 1, Sum[If[(i==1 || l[[i-1]] <= l[[i]]) && l[[i]] >
%t A181191    If[i==n, 0, l[[i+1]]], b[ReplacePart[l, i->l[[i]]-1]], 0], {i, 1, n}]]];
%t A181191 a[n_] := b[Table[n, {n}]];
%t A181191 Table[a[n], {n, 1, 11}] (* _Jean-François Alcover_, May 10 2022, after _Alois P. Heinz_ *)
%Y A181191 Main diagonal of A181196.
%Y A181191 Cf. A039917, A181196.
%K A181191 nonn
%O A181191 1,3
%A A181191 _R. H. Hardin_, Oct 10 2010
%E A181191 a(10)-a(16) from _Alois P. Heinz_, Jul 24 2012