OFFSET
1,2
COMMENTS
Every positive integer occurs exactly once, and for every n, the numbers in row n have the parity of n.
EXAMPLE
Corner:
1 3 7 15 31 63 127 255
2 4 6 8 12 14 16 24
5 9 11 13 17 19 23 25
10 18 20 22 26 34 36 38
21 37 41 43 45 53 69 73
42 74 82 84 86 90 106 138
85 149 165 169 171 173 181 213
170 298 330 338 340 342 346 362
341 597 661 677 681 683 685 693
The binary representation of 22 is 10110, which has 4 runs: 1, 0, 11, 0.
MATHEMATICA
a[n_] := a[n] = Select[Range[8000], Length[Split[IntegerDigits[#, 2]]] == n &];
t[n_, k_] := a[n][[k]];
Grid[Table[t[n, k], {n, 1, 12}, {k, 1, 12}]] (* array *)
Table[t[n - k + 1, k], {n, 12}, {k, n, 1, -1}] // Flatten (* sequence *)
CROSSREFS
KEYWORD
AUTHOR
Clark Kimberling, Mar 11 2024
STATUS
approved