login
A322867
a(n) = A000120(A122111(n)).
6
1, 1, 1, 2, 1, 2, 1, 2, 2, 2, 1, 2, 1, 2, 2, 3, 1, 4, 1, 2, 2, 2, 1, 3, 4, 2, 3, 2, 1, 4, 1, 3, 2, 2, 4, 3, 1, 2, 2, 3, 1, 4, 1, 2, 3, 2, 1, 3, 3, 4, 2, 2, 1, 3, 4, 3, 2, 2, 1, 3, 1, 2, 3, 3, 4, 4, 1, 2, 2, 4, 1, 2, 1, 2, 4, 2, 3, 4, 1, 3, 3, 2, 1, 3, 4, 2, 2, 3, 1, 3, 3, 2, 2, 2, 4, 3, 1, 4, 3, 6, 1, 4, 1, 3, 4
OFFSET
1,4
FORMULA
a(n) = A000120(A122111(n)) = A000120(A322865(n)) = A001222(A322863(n)).
MATHEMATICA
Array[DigitCount[#, 2, 1] &@ If[# < 3, 1, Block[{k = #, m = 0}, Times @@ Power @@@ Table[k -= m; k = DeleteCases[k, 0]; {Prime@Length@k, m = Min@ k}, Length@ Union@ k]] &@ Catenate[ConstantArray[PrimePi[#1], #2] & @@@ FactorInteger@ #]] &, 105] (* Michael De Vlieger, Dec 31 2018, after JungHwan Min at A122111 *)
PROG
(PARI)
A064989(n) = {my(f); f = factor(n); if((n>1 && f[1, 1]==2), f[1, 2] = 0); for (i=1, #f~, f[i, 1] = precprime(f[i, 1]-1)); factorback(f)};
A122111(n) = if(1==n, n, prime(bigomega(n))*A122111(A064989(n)));
A322867(n) = hammingweight(A122111(n));
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Dec 30 2018
STATUS
approved