login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A293668
First differences of A292046.
3
1, 2, 3, 1, 4, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
OFFSET
0,2
COMMENTS
a(n) is also the length of n-th run of consecutive integers in the complement of A292046, starting from the 1st run "4, 5".
This sequence is invariant under the following transform: subtract 1 from every term, eliminate zeros. Other sequences with this property include A001511 and other generalized ruler functions, A002260, A272729.
LINKS
FORMULA
a(0) = 1, a(n) = A292046(n+1)-A292046(n) for n>0.
If n = 2^k, a(n) = a(k)+1; otherwise a(n) = 1.
a(n) = A255308(n) + 1.
a(n) = O(log*(n)), where log* is the iterated logarithm. More precisely, a(n) <= A230864(n+1)+1.
PROG
(PARI) A293668(n) = { my(k=1); while(n && !bitand(n, n-1), n = valuation(n, 2); k++); (k); }; \\ Antti Karttunen, Sep 30 2018
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Andrey Zabolotskiy, Oct 14 2017
STATUS
approved