A367095 Number of distinct sums of pairs (repeats allowed) of prime indices of n.
0, 1, 1, 1, 1, 3, 1, 1, 1, 3, 1, 3, 1, 3, 3, 1, 1, 3, 1, 3, 3, 3, 1, 3, 1, 3, 1, 3, 1, 5, 1, 1, 3, 3, 3, 3, 1, 3, 3, 3, 1, 6, 1, 3, 3, 3, 1, 3, 1, 3, 3, 3, 1, 3, 3, 3, 3, 3, 1, 5, 1, 3, 3, 1, 3, 6, 1, 3, 3, 6, 1, 3, 1, 3, 3, 3, 3, 6, 1, 3, 1, 3, 1, 6, 3, 3, 3, 3, 1, 5, 3, 3, 3, 3, 3, 3, 1, 3, 3, 3, 1, 6, 1, 3, 5
Offset: 1
Keywords
Examples
The prime indices of 15 are {2,3}, with sums of pairs: 2+2 = 4 2+3 = 5 3+3 = 6 so a(15) = 3. The prime indices of 180 are {1,1,2,2,3}, with sums of pairs: 1+1 = 2 1+2 = 3 1+3 = 4 2+2 = 4 2+3 = 5 3+3 = 6 so a(180) = 5.
Links
Crossrefs
Depends only on squarefree kernel A007947. (Even more exactly, on A322591 - Antti Karttunen, Jan 20 2025)
Positions of first appearances appear to be a subset of A325986.
A304793 counts positive subset-sums of prime indices.
Programs
-
Mathematica
prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]]; Table[Length[Union[Total/@Tuples[prix[n],2]]],{n,100}]
-
PARI
A367095(n) = if(1==n, 0, my(pis=apply(primepi,factor(n)[,1]), pairsums = vector(binomial(1+#pis,2)), k=0); for(i=1,#pis,for(j=i,#pis,k++; pairsums[k] = pis[i]+pis[j])); #Set(pairsums)); \\ Antti Karttunen, Jan 20 2025
Extensions
Data section extended to a(105) by Antti Karttunen, Jan 20 2025
Comments