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”).

A376617
Binary Niven numbers (A049445) k such that m = k/wt(k) and m/wt(m) are also binary Niven numbers, where wt(k) = A000120(k) is the binary weight of k.
7
1, 2, 4, 8, 16, 24, 32, 40, 48, 64, 72, 80, 96, 128, 136, 144, 160, 192, 256, 264, 272, 288, 320, 384, 512, 520, 528, 544, 576, 640, 756, 768, 960, 1024, 1032, 1040, 1056, 1088, 1104, 1152, 1280, 1296, 1380, 1472, 1512, 1536, 1620, 1656, 1728, 1840, 1856, 1920, 1944
OFFSET
1,2
COMMENTS
Numbers k such that A376615(k) = 0 or A376615(k) >= 4.
LINKS
EXAMPLE
24 is a term since 24/wt(24) = 12 is an integer, 12/wt(12) = 6 is an integer, and 6/wt(6) = 3 is an integer.
MATHEMATICA
q[k_] := Module[{w = DigitCount[k, 2, 1], w2, m, n}, IntegerQ[m = k/w] && Divisible[m, w2 = DigitCount[m, 2, 1]] && Divisible[n = m/w2, DigitCount[n, 2, 1]]]; Select[Range[2000], q]
PROG
(PARI) s(n) = {my(w = hammingweight(n)); if(w == 1, 0, if(n % w, 1, 1 + s(n/w))); }
is(k) = {my(sk = s(k)); sk == 0 || sk >= 4; }
CROSSREFS
Subsequence of A049445 and A376616.
A000079 is a subsequence.
Sequence in context: A072874 A160158 A010072 * A318654 A375979 A333994
KEYWORD
nonn,easy,base
AUTHOR
Amiram Eldar, Sep 30 2024
STATUS
approved