OFFSET
1,3
COMMENTS
For any k > 0, there are A308251(k-1) positive terms with k binary digits.
The ones in the binary representation of any term encodes a finite set of nonnegative integers, say S, such that the differences between any two distinct elements of S are all unique.
For any m >= 0, m belongs to the sequence iff 2*m belongs to the sequence.
LINKS
EXAMPLE
Regarding 7:
- 7 AND 14 = 6, which is neither 0 nor a power of 2,
- so 7 does not belong to the sequence.
Regarding 13:
- we have the following values:
k 13 AND (13*2^k)
--- ---------------
1 2^3
2 2^2
3 2^3
>=4 0
- so 13 belongs to the sequence.
PROG
(PARI) is(n) = { my (m=n); while (m>>=1, if (hammingweight(bitand(m, n))>1, return (0))); return (1) }
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, Sep 20 2020
STATUS
approved