OFFSET
1,2
COMMENTS
A multiplicative analog of A231271.
A prime p is a term, iff p and p^2 are both odious or both evil.
LINKS
Peter J. C. Moses, Table of n, a(n) for n = 1..5000
EXAMPLE
Evil number n=15 has divisors {1,3,5,15}.
Since all numbers 15*1=15, 15*3=45, 15*5=75 and 15*15=225 are evil, then 15 is a term.
MATHEMATICA
odiousQ[n_]:=OddQ[DigitCount[n, 2][[1]]]; selQ[n_]:=OddQ[n] && Length[Union[Map[odiousQ, Map[n #&, Divisors[n]]]]] == 1; Select[Range[400], selQ] (* Peter J. C. Moses, Nov 10 2013 *)
PROG
(PARI) isok(n) = (n % 2) && (!(s = sumdiv(n, d, hammingweight(n*d) % 2)) || (s == numdiv(n))); \\ Michel Marcus, Nov 10 2013
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Vladimir Shevelev, Nov 10 2013
EXTENSIONS
More terms from Michel Marcus
STATUS
approved