A223888 Composite odious numbers (A000069) having no proper odious divisors greater than 1.
25, 69, 81, 87, 115, 145, 213, 265, 289, 339, 355, 391, 415, 445, 477, 493, 505, 529, 565, 695, 731, 747, 789, 815, 841, 901, 985, 1041, 1047, 1077, 1119, 1149, 1207, 1219, 1315, 1341, 1347, 1383, 1401, 1411, 1437, 1465, 1509, 1513, 1527, 1537, 1555, 1585
Offset: 1
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
odiousQ[n_] := OddQ@Total@IntegerDigits[n, 2]; okQ[n_] := n > 1 && odiousQ[n] && ! PrimeQ[n] && Catch[Do[If[odiousQ[d], Throw[False]], {d, Most@Rest@Divisors@n}]; True]; Select[Range@3000, okQ] (* Giovanni Resta, Mar 28 2013 *)
-
PARI
isodi(n) = hammingweight(n) % 2; noodid(n) = {fordiv(n, d, if ((d != 1) && (d < n) && isodi(d), return (0));); 1;} lista(nn) = {forcomposite(n=1, nn, if (isodi(n) && noodid(n), print1(n, ", ")););} \\ Michel Marcus, Feb 08 2016
Extensions
a(10)-a(48) from Giovanni Resta, Mar 28 2013
Comments