0,2
In the binary expansion of n, delete everything left of the rightmost 1 bit, then interpret as ternary and add 1. - Ralf Stephan, Aug 22 2013
Antti Karttunen, Table of n, a(n) for n = 0..65537
Michael Gilleland, Some Self-Similar Integer Sequences
R. Stephan, Some divide-and-conquer sequences ...
R. Stephan, Table of generating functions
Index entries for sequences related to binary expansion of n
a(n) = A034472(A007814(n)) for n > 0.
a(2n) = 3a(n)-2; a(2n+1) = 2.
G.f.: 1/(1-x) + Sum_{k>=0} 3^k*x^2^k/(1 - x^2^(k+1)). - Ralf Stephan, Jun 13 2003
(PARI) A061393(n) = if(!n, 1, (1+3^valuation(n, 2))); \\ Antti Karttunen, Sep 30 2018
Cf. A061392.
Sequence in context: A303165 A188813 A072866 * A260361 A055935 A086930
Adjacent sequences: A061390 A061391 A061392 * A061394 A061395 A061396
nonn
Henry Bottomley, Apr 30 2001
approved