login
A328034
a(n) = 3n minus the largest power of 2 not exceeding 3n.
1
1, 2, 1, 4, 7, 2, 5, 8, 11, 14, 1, 4, 7, 10, 13, 16, 19, 22, 25, 28, 31, 2, 5, 8, 11, 14, 17, 20, 23, 26, 29, 32, 35, 38, 41, 44, 47, 50, 53, 56, 59, 62, 1, 4, 7, 10, 13, 16, 19, 22, 25, 28, 31, 34, 37, 40, 43, 46, 49, 52, 55, 58, 61, 64, 67, 70, 73, 76, 79, 82, 85, 88, 91, 94, 97, 100, 103, 106, 109
OFFSET
1,2
COMMENTS
For odd n, a(n) is odd. For even n, a(n) = 2*a(n/2).
Conjecture: iterations of a() stabilize at a power of 2, or at a 2-cycle (5*2^t,7*2^t).
FORMULA
a(n) = A053645(3*n).
PROG
(PARI) { A328034(n) = 3*n - 1<<(log(3*n+.5)\log(2)); }
CROSSREFS
Sequence in context: A030102 A072010 A255588 * A123360 A072015 A123242
KEYWORD
nonn
AUTHOR
Max Alekseyev, Nov 10 2019
STATUS
approved