%I #20 Feb 08 2019 12:44:02
%S 0,1,0,1,0,0,1,2,1,0,1,3,0,2,0,1,4,4,3,3,0,1,5,2,0,1,4,0,1,6,5,5,4,4,
%T 5,0,1,7,3,6,0,5,2,6,0,1,8,6,2,6,5,1,5,7,0,1,9,4,6,4,0,3,5,3,8,0,1,10,
%U 7,7,7,7,6,6,6,6,9,0,1,11,5,3,2,7,0,6,1,2,4,10,0
%N Array read by antidiagonals: T(i,j) (i>=0, j>=0) = number of steps to reach either top row or main diagonal using the steps (i,j)->(j,i) or (i,j)->(i,j-i).
%C We start at (i,j) and apply either (i,j) -> (j,i) if i>j or (i,j) -> (i,j-i) if j>i. T(i,j) is the minimal number of steps to reach either (0,k) or (k,k) for some k.
%C Somewhat analogous to the array in A072030 except that here the offset is different and we pay for transposition steps as well as subtraction steps.
%F Recurrence: T(0,k)=TR(k,k)=0; if i>j then T(i,j)=T(j,i)+1; if j>i then T(i,j)=T(i,j-i)+1.
%F For a > 1 and b,k > 0, T(ak,k) = a, T(ak+b,k) = T(b,k) + a + 2, T(k,ak) = a - 1, T(k,ak+b) = T(k,b) + a. - _Charlie Neder_, Feb 08 2019
%e Array begins:
%e 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
%e 1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, ...
%e 1, 2, 0, 3, 1, 4, 2, 5, 3, 6, 4, 7, 5, ...
%e 1, 3, 4, 0, 4, 5, 1, 5, 6, 2, 6, 7, 3, ...
%e 1, 4, 2, 5, 0, 5, 3, 6, 1, 6, 4, 7, 2, ...
%e 1, 5, 5, 6, 6, 0, 6, 6, 7, 7, 1, 7, 7, ...
%e 1, 6, 3, 2, 4, 7, 0, 7, 4, 3, 5, 8, 1, ...
%e 1, 7, 6, 6, 7, 7, 8, 0, 8, 7, 7, 8, 8, ...
%e 1, 8, 4, 7, 2, 8, 5, 9, 0, 9, 5, 8, 3, ...
%e 1, 9, 7, 3, 7, 8, 4, 8, 10, 0, 10, 8, 4, ...
%e 1, 10, 5, 7, 5, 2, 6, 8, 6, 11, 0, 11, 6, ...
%e 1, 11, 8, 8, 8, 8, 9, 9, 9, 9, 12, 0, 12, ...
%e 1, 12, 6, 4, 3, 8, 2, 9, 4, 5, 7, 13, 0, ...
%e ...
%e The first few antidiagonals are:
%e 0,
%e 1, 0,
%e 1, 0, 0,
%e 1, 2, 1, 0,
%e 1, 3, 0, 2, 0,
%e 1, 4, 4, 3, 3, 0,
%e 1, 5, 2, 0, 1, 4, 0,
%e 1, 6, 5, 5, 4, 4, 5, 0,
%e 1, 7, 3, 6, 0, 5, 2, 6, 0,
%e 1, 8, 6, 2, 6, 5, 1, 5, 7, 0,
%e 1, 9, 4, 6, 4, 0, 3, 5, 3, 8, 0,
%e ...
%p M:=12;
%p A:=Array(0..M, 0..M, 0);
%p for k from 0 to M do A[0,k]:=0; A[k,k]:=0; od:
%p # border number k
%p # col k, row n
%p for k from 1 to M do
%p for n from 1 to k-1 do A[n,k]:=A[n,k-n]+1; od:
%p # row k, col i
%p for i from k-1 by -1 to 0 do A[k,i]:=A[i,k]+1; od:
%p od:
%p for n from 0 to M do lprint([seq(A[n,k],k=0..M)]); od: # square array
%p for n from 0 to M do lprint([seq(A[n-j,j],j=0..n)]); od: # antidiagonals
%Y Cf. A072030.
%Y For initial rows and columns see A267182-A267187.
%Y For the array read mod 2, see A267188.
%K nonn,tabl
%O 0,8
%A _N. J. A. Sloane_, Jan 16 2016