login
Square array read by antidiagonals: T(n,k) is the position of the last requested element when the elements of the k-th composition (in standard order) are requested from a self-organizing list initialized to (1, 2, 3, ...), using the move-ahead(n) updating strategy; n >= 0, k >= 1.
3

%I #4 Jul 28 2024 17:02:06

%S 1,2,1,1,2,1,3,1,2,1,1,3,1,2,1,2,2,3,1,2,1,1,2,2,3,1,2,1,4,1,2,2,3,1,

%T 2,1,1,4,1,2,2,3,1,2,1,2,1,4,1,2,2,3,1,2,1,1,1,2,4,1,2,2,3,1,2,1,3,1,

%U 1,2,4,1,2,2,3,1,2,1,1,3,1,1,2,4,1,2,2,3,1,2,1

%N Square array read by antidiagonals: T(n,k) is the position of the last requested element when the elements of the k-th composition (in standard order) are requested from a self-organizing list initialized to (1, 2, 3, ...), using the move-ahead(n) updating strategy; n >= 0, k >= 1.

%C See A374996 for details.

%F T(0,k) = A007814(k) + 1.

%F T(1,k) = A374998(k).

%F T(n,k) = A374997(k) if n >= A333766(k)-1.

%F T(n,k) = A374996(n,k) - A374996(n,A025480(k-1)).

%F Sum_{j=1..m} T(n,k*2^j+2^(j-1)) = m*(m+1)/2 if m >= A333766(k). This is a consequence of the fact that the first m positions of the list are occupied by the elements 1, ..., m, as long as no element larger than m has been requested so far.

%e Array begins:

%e n\k| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

%e ---+--------------------------------------------

%e 0 | 1 2 1 3 1 2 1 4 1 2 1 3 1 2 1

%e 1 | 1 2 1 3 2 2 1 4 1 1 1 3 2 2 1

%e 2 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 3 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 4 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 5 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 6 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 7 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 8 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 9 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 10 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 11 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 12 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 13 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 14 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%e 15 | 1 2 1 3 2 2 1 4 2 1 1 3 2 2 1

%Y Cf. A007814, A025480, A374998 (row n=1), A333766, A374996, A374997.

%K nonn,tabl

%O 0,2

%A _Pontus von Brömssen_, Jul 27 2024