A360678 Sum of the left half (inclusive) of the prime indices of n.
0, 1, 2, 1, 3, 1, 4, 2, 2, 1, 5, 2, 6, 1, 2, 2, 7, 3, 8, 2, 2, 1, 9, 2, 3, 1, 4, 2, 10, 3, 11, 3, 2, 1, 3, 2, 12, 1, 2, 2, 13, 3, 14, 2, 4, 1, 15, 3, 4, 4, 2, 2, 16, 3, 3, 2, 2, 1, 17, 2, 18, 1, 4, 3, 3, 3, 19, 2, 2, 4, 20, 3, 21, 1, 5, 2, 4, 3, 22, 3, 4, 1
Offset: 1
Keywords
Examples
The prime indices of 810 are {1,2,2,2,2,3}, with left half (inclusive) {1,2,2}, so a(810) = 5. The prime indices of 3675 are {2,3,3,4,4}, with left half (inclusive) {2,3,3}, so a(3675) = 8.
Crossrefs
Programs
-
Mathematica
prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]]; Table[Total[Take[prix[n],Ceiling[Length[prix[n]]/2]]],{n,100}]
Comments