login
A076057
Numbers k such that Sum_{j=1..k} A006513(j) = 3*k/2.
2
2, 4, 8, 16, 18, 32, 38, 46, 48, 62, 66, 80, 90, 102, 120, 138, 158, 160, 180, 212, 242, 278, 324, 364, 436, 482, 574, 576, 658, 736, 738, 882, 892, 900, 972, 974, 976, 1162, 1164, 1318, 1320, 1524, 1526, 1528, 1762, 1788, 1796, 1982, 2342, 2344, 2346, 2386, 2392, 2634, 3110
OFFSET
1,1
LINKS
FORMULA
a(n) seems to be asymptotic to c*n^2 with 1/2 < c < 1.
PROG
(PARI) f(n) = if (n%2, (3*n+1)/2, n/2); \\ A014682
g(n) = my(last = n); while (1, my(new = f(f(last))); if (new == last, return(new)); last = new; ); \\ A006513
isok(m) = !(m%2) && (sum(k=1, m, g(k)) == 3*m/2); \\ Michel Marcus, Feb 03 2022
(PARI) f(n) = if (n%2, (3*n+1)/2, n/2); \\ A014682
g(n) = my(last = n); while (1, my(new = f(f(last))); if (new == last, return(new)); last = new; ); \\ A006513
lista(nn) = {my(v = vector(nn, k, g(k)), w = vector(nn)); w[1] = v[1]; for (i=2, nn, w[i] = w[i-1] + v[i]; ); forstep (i=2, nn, 2, if (w[i] == 3*i/2, print1(i, ", ")); ); } \\ Michel Marcus, Feb 03 2022
CROSSREFS
Sequence in context: A369951 A088827 A316900 * A364061 A133809 A128700
KEYWORD
nonn
AUTHOR
Benoit Cloitre, Oct 30 2002
EXTENSIONS
More terms from Michel Marcus, Feb 03 2022
STATUS
approved