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.

A375888 Rectangular array: row n shows all k such that n is the number of rises in the trajectory of k in the Collatz problem.

Original entry on oeis.org

1, 2, 5, 4, 10, 3, 8, 20, 6, 17, 16, 21, 12, 34, 11, 32, 40, 13, 35, 22, 7, 64, 42, 24, 68, 23, 14, 9, 128, 80, 26, 69, 44, 15, 18, 25, 256, 84, 48, 70, 45, 28, 19, 49, 33, 512, 85, 52, 75, 46, 29, 36, 50, 65, 43, 1024, 160, 53, 136, 88, 30, 37, 51, 66, 86, 57
Offset: 0

Views

Author

Clark Kimberling, Sep 11 2024

Keywords

Comments

Assuming that the Collatz conjecture (also known as the 3x+1 conjecture) is true, this is a permutation of the positive integers; viz., every positive integer occurs exactly once. Conjecture: every row contains a pair of consecutive integers.

Examples

			Corner:
   1     2     4     8    16    32    64   128   256   512  1024
   5    10    20    21    40    42    80    84    85   160   168
   3     6    12    13    24    26    48    52    53    96   104
  17    34    35    68    69    70    75   136   138   140   141
  11    22    23    44    45    46    88    90    92    93   176
   7    14    15    28    29    30    56    58    60    61   112
   9    18    19    36    37    38    72    74    76    77    81
6 is in row 2 because the trajectory, (6, 3, 10, 5, 16, 4, 2, 1), has exactly 2 rises: 3 to 10, and 5 to 16.
		

Crossrefs

Cf. A000027, A000079 (row 1), A092893 (column 1), A006667, A070265, A078719.
Cf. A354236.

Programs

  • Mathematica
    t = Table[Count[Differences[NestWhileList[If[EvenQ[#], #/2, 3 # + 1] &, n, # > 1 &]], ? Positive], {n, 2048}]; (* after _Harvey P. Dale, A006667 *)
    r[n_] := Flatten[Position[t, n - 1]];
    Column[Table[r[n], {n, 1, 21}]] (* array *)
    u = Table[r[k][[n + 1 - k]], {n, 1, 12}, {k, 1, n}]
    Flatten[u] (* sequence *)

Formula

Transpose of the array in A354236.