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.

A308880 Irregular array read by rows: row k (k>=1) contains k^2 numbers, formed by filling in a k X k square by rows so entries in all rows, columns, diagonals, antidiagonals are distinct, and then reading that square across rows.

This page as a plain text file.
%I A308880 #42 Mar 07 2020 13:50:20
%S A308880 0,0,1,2,3,0,1,2,2,3,0,1,4,5,0,1,2,3,2,3,0,1,1,4,5,2,5,0,1,4,0,1,2,3,
%T A308880 4,2,3,0,1,5,1,4,5,2,0,5,0,1,4,3,3,6,7,0,1,0,1,2,3,4,5,2,3,0,1,6,7,1,
%U A308880 4,5,2,0,8,5,0,1,4,3,6,3,7,6,0,1,4,4,2,9,5,7,10
%N A308880 Irregular array read by rows: row k (k>=1) contains k^2 numbers, formed by filling in a k X k square by rows so entries in all rows, columns, diagonals, antidiagonals are distinct, and then reading that square across rows.
%C A308880 The second row of the k X k square converges to A004443 as k increases.
%C A308880 When filling in the k X k square, always choose the smallest possible number. Each k X k square is uniquely determined.
%C A308880 Each k X k square read downwards by antidiagonals up to and including the main antidiagonal is A274528(1..k*(k+1)/2). - _I. V. Serov_, Jun 30 2019, following an argument by _Bernard Schott_.
%H A308880 I. V. Serov, <a href="/A308880/b308880.txt">Rows of first 32 squares, flattened</a> (There are 1^2+2^2+...+32^2 = 11440 entries.)
%H A308880 F. Michel Dekking, Jeffrey Shallit, and N. J. A. Sloane, <a href="https://www.combinatorics.org/ojs/index.php/eljc/article/view/v27i1p52/8039">Queens in exile: non-attacking queens on infinite chess boards</a>, Electronic J. Combin., 27:1 (2020), #P1.52.
%e A308880 The first eight squares are (here A=10, B=11, C=12):
%e A308880 0
%e A308880 --------
%e A308880 01
%e A308880 23
%e A308880 --------
%e A308880 012
%e A308880 230
%e A308880 145
%e A308880 --------
%e A308880 0123
%e A308880 2301
%e A308880 1452
%e A308880 5014
%e A308880 --------
%e A308880 01234
%e A308880 23015
%e A308880 14520
%e A308880 50143
%e A308880 36701
%e A308880 --------
%e A308880 012345
%e A308880 230167
%e A308880 145208
%e A308880 501436
%e A308880 376014
%e A308880 42957A
%e A308880 --------
%e A308880 0123456
%e A308880 2301674
%e A308880 1452083
%e A308880 5014362
%e A308880 3780145
%e A308880 4265798
%e A308880 9548237
%e A308880 --------
%e A308880 01234567
%e A308880 23016745
%e A308880 14520836
%e A308880 50143628
%e A308880 37801459
%e A308880 42675983
%e A308880 9548237A
%e A308880 A836BC92
%e A308880 --------
%e A308880 Concatenating the rows of these squares gives the sequence.
%o A308880 (MATLAB)
%o A308880 A308880 = [];
%o A308880 A308881 = [];
%o A308880 for n = 1:oo;
%o A308880 M = [0:(n-1)
%o A308880      zeros(n-1,n-0)*NaN];
%o A308880 for i = 2:n; for j = 1:n; M = Mnext(M,n,i,j); end; end
%o A308880 A308880 = [A308880 reshape(M',1,n^2)];
%o A308880 A308881 = [A308881 reshape(M ,1,n^2)];
%o A308880 end
%o A308880 function [M] = Mnext(M,n,i,j);
%o A308880 row = M(i,1:j-1);
%o A308880 col = M(1:i-1,j);
%o A308880 dim = diag(       M, j-i);
%o A308880 dia = diag(fliplr(M),n-i-j+1);
%o A308880 X = ([row col' dim' dia']);
%o A308880 for m = 0:length(X)-1; if isempty(find(X==m)); break; end; end;
%o A308880 M(i,j) = m;
%o A308880 end
%o A308880 % _I. V. Serov_, Jun 30 2019
%Y A308880 Cf. A004443, A308881, A274528.
%K A308880 nonn,tabf
%O A308880 1,4
%A A308880 _N. J. A. Sloane_, Jun 29 2019