login
A246435
Length of representation of n in fractional base 3/2.
16
1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9
OFFSET
0,4
LINKS
B. Chen, R. Chen, J. Guo, S. Lee et al., On Base 3/2 and its sequences, arXiv:1808.04304 [math.NT], 2018.
FORMULA
a(n) = if n < 3 then 1, otherwise a(2*floor(n/3)) + 1.
a(n) = A055642(A024629(n)).
MATHEMATICA
a[n_] := If[n < 3, 1, a[2 Quotient[n, 3]] + 1]; Array[a, 100, 0] (* Jean-François Alcover, Feb 05 2019 *)
PROG
(Haskell)
a246435 n = if n < 3 then 1 else a246435 (2 * div n 3) + 1
-- Reinhard Zumkeller, Sep 05 2014
CROSSREFS
Cf. A024629, A055642, A070989, A081604, A081848 (run lengths).
Sequence in context: A329194 A375499 A210533 * A301461 A172471 A373811
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Sep 05 2014
STATUS
approved