OFFSET
0,4
COMMENTS
The minimum number of operations is A375494(n) and that minimum is attained by a(n) different sequences of operations.
PROG
(Python)
from itertools import product
seq = [None for _ in range(200)]
num = [ 0 for _ in range(len(seq))]
for L in range(0, 23):
for P in product((True, False), repeat=L):
x = 1
for upward in P:
x = 3*x+1 if upward else x//2
if x < len(seq):
if num[x] == 0 or L < seq[x]:
seq[x], num[x] = L, 1
elif L == seq[x]:
num[x] += 1
print(', '.join([str(x) for x in num]))
CROSSREFS
KEYWORD
nonn
AUTHOR
Russell Y. Webb, Aug 18 2024
STATUS
approved