|
COMMENTS
|
Least k such that A006577(k) = k/n, or -1.
By definition, k is divisible by n. - Ralf Stephan, Sep 01 2003
The sequence (with question marks for the unknown values) begins 5, 2, 21, 16, 40, 120, 238, 96, 261, 150, ?, 288, 767, 2002, 405, 160, 170, 2016, ?, 1980, 693, 1078, 2645, ?, 625, 650, ?, 784, ?, ...
For n in {11, 19, 24, 27, 29, 35, 37, 38, 45, 46}, if k exists, it is greater than 10^7. - David A. Corneth, Jan 29 2022
|
|
PROG
|
(PARI) a(n)=if(n<0, 0, k=n; while(abs(if(k<0, 0, s=k; c=1; while((1-(s%2))*s/2+(s%2)*(3*s+1)>1, s=(1-(s%2))*s/2+(s%2)*(3*s+1); c++); c)-k/n)>0, k=k+n); k)
|