login
Array associated with squares, by antidiagonals.
4

%I #11 Jul 12 2017 03:17:40

%S 1,2,3,5,4,8,10,6,7,15,17,11,9,14,24,26,18,12,13,23,35,37,27,19,16,22,

%T 34,48,50,38,28,20,21,33,47,63,65,51,39,29,25,32,46,62,80,82,66,52,40,

%U 30,31,45,61,79,99,101,83,67,53,41,36,44,60,78,98,120,122,102,84,68,54,42,43,59,77,97,119,143,145,123,103,85,69,55,49,58,76,96,118,142,168,170,146,124,104,86,70,56,57,75,95,117,141,167,195

%N Array associated with squares, by antidiagonals.

%C Every positive integer occurs exactly once; hence, as a sequence, A185725 is a permutation of the positive integers. The square with corners T(0,0)=1 and T(n,n)=n^2 is occupied by the numbers 1,2,...,n^2.

%C T(1,k)=(k-1)^2+1 (A002522)

%C T(n,1)=-1+n^2 for n>=2.

%H G. C. Greubel, <a href="/A185728/b185728.txt">Table of n, a(n) for the first 50 rows, flattened</a>

%F T(n,k)=(k-1)^2+n if n<k; T(n,n)=n^2; T(n,k)=n^2-k if n>k.

%e Northwest corner:

%e 1...2...5...10...17

%e 3...4...6...11...18

%e 8...7...9...12...19

%e 15..14..13..16...20

%t f[n_,k_]:=(k-1)^2+n/; k>n;

%t f[n_,n_]:=n^2; f[n_,k_]:=n^2-k/; k<n;

%t TableForm[Table[f[n,k],{n,1,10},{k,1,15}]]

%t Table[f[n-k+1,k],{n,14},{k,n,1,-1}]//Flatten

%Y Cf. A185725, A185726, A060734.

%K nonn,tabl

%O 1,2

%A _Clark Kimberling_, Feb 01 2011