# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/ Search: id:a355968 Showing 1-1 of 1 %I A355968 #31 Oct 31 2022 05:55:32 %S A355968 1,2,4,8,16,28,64,56,84,112,1024,168,4096,448,336,728,36309,672,57057, %T A355968 1456,1344,7168,105105,2184,6384,24150,5376,5208,405405,4368,389025, %U A355968 11648,20020,72618,10416,8736,927675,114114,48300,24024,855855,17472,1426425,40040 %N A355968 a(n) is the smallest number that has exactly n odious divisors (A000069). %C A355968 a(n) <= 2^(n-1) with equality for n = 1, 2, 3, 4, 5, 7, 11, 13 up to a(44). %H A355968 Amiram Eldar, Table of n, a(n) for n = 1..100 %e A355968 a(6) = 28 since 28 has 6 divisors {1, 2, 4, 7, 14, 28} that have all an odd number of 1's in their binary expansion: 1, 10, 100, 111, 1110 and 11100; also, no positive integer smaller than 28 has six divisors that are odious. %t A355968 f[n_] := DivisorSum[n, 1 &, OddQ[DigitCount[#, 2, 1]] &]; seq[len_, nmax_] := Module[{s = Table[0, {len}], c = 0, n = 1, i}, While[c < len && n < nmax, i = f[n]; If[i <= len && s[[i]] == 0, c++; s[[i]] = n]; n++]; s]; seq[20, 10^6] (* _Amiram Eldar_, Jul 21 2022 *) %o A355968 (PARI) isod(n) = hammingweight(n) % 2; \\ A000069 %o A355968 a(n) = my(k=1); while (sumdiv(k, d, isod(d)) != n, k++); k; \\ _Michel Marcus_, Jul 22 2022 %o A355968 (Python) %o A355968 from sympy import divisors %o A355968 from itertools import count, islice %o A355968 def c(n): return bin(n).count("1")&1 %o A355968 def f(n): return sum(1 for d in divisors(n, generator=True) if c(d)) %o A355968 def agen(): %o A355968 n, adict = 1, dict() %o A355968 for k in count(1): %o A355968 fk = f(k) %o A355968 if fk not in adict: adict[fk] = k %o A355968 while n in adict: yield adict[n]; n += 1 %o A355968 print(list(islice(agen(), 36))) # _Michael S. Branicky_, Jul 25 2022 %Y A355968 Cf. A000069, A093696, A227872, A330289, A355969. %Y A355968 Similar sequences: A087997, A333456, A355303, A355699. %K A355968 nonn,base %O A355968 1,2 %A A355968 _Bernard Schott_, Jul 21 2022 %E A355968 More terms from _Amiram Eldar_, Jul 21 2022 # Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE