OFFSET
1,2
COMMENTS
Theorem. A positive odd number is in the sequence iff in its binary expansion all bits in the k-th position from the end, for k=2, 4, 6, ..., are zeros. For example, 337, 341 have binary expansions 101010001, 101010101. Thus both of them are in the sequence. If A(x) is the counting function of a(n) <= x, then A(x)=O(sqrt(x))and Omega(sqrt(x)). If f(x) = Sum_{n>=1} x^a(n), abs(x) < 1, then f(x)*f(x^2) = x^3/(1-x^4); a(n) = 2*A145812(n) - 1.
Every positive odd integer m == 3 (mod 2^(2r)) is a unique sum of the form a(2^(r-1)*(s-1)+1) + a(2^(r-1)*(t-1)+1), r=1,2,..., while other odd integers are not expressible in such form (see also comment to A145812). - Vladimir Shevelev, Oct 21 2008
To get the decomposition of m=4k+3 as the sum a(l)+2*a(s), write m-2 as Sum b_j 2^j, then a(s) = 1 + Sum_{j odd} b_j 2^(j-1). For example, if m=55, then we have 53 = 2^0 + 2^2 + 2^4 + 2^5. Thus a(l) = 1 + 2^4 = 17 and the required decomposition is 55 = a(l) + 2*17, such that a(l)=21. We see that l=4, s=3, i.e., "index coordinates" of 55 are (4,3). Thus we have a one-to-one map of positive integers of the form 4k+3 to the positive lattice points on the plane. - Vladimir Shevelev, Oct 26 2008
Odd terms of A000695 (the Moser-de Bruijn sequence: sums of distinct powers of 4). - Jon E. Schoenfield, Mar 18 2021
LINKS
Klaus Brockhaus, Table of n, a(n) for n = 1..8192
MATHEMATICA
aQ[n_] := OddQ[n] && Module[{d = Reverse[IntegerDigits[n, 2]]}, Length[d] < 2 || Max[d[[2;; -1;; 2]]] == 0]; Select[Range[4500], aQ] (* Amiram Eldar, Dec 15 2018 *)
PROG
(PARI) isok(n) = {if (n % 2, my(rb = Vecrev(binary(n)), brb = vector(#rb\2, k, rb[2*k])); (#brb == 0) || vecmax(brb) == 0, 0); } \\ Michel Marcus, Dec 15 2018
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Shevelev, Oct 20 2008, Oct 21 2008
EXTENSIONS
Extended beyond a(16) by Klaus Brockhaus, Oct 22 2008
STATUS
approved