A335306 a(n) is the smallest composite number whose sum of distinct prime divisors is prime(n).
4, 9, 6, 10, 121, 22, 210, 34, 273, 399, 58, 435, 651, 82, 777, 903, 1645, 118, 885, 1281, 142, 1065, 1533, 1659, 1335, 3115, 202, 2037, 214, 2163, 3729, 6213, 2667, 274, 2919, 298, 2235, 4917, 3297, 3423, 5845, 358, 3801, 382, 7059, 394, 6501, 7385, 8229, 454, 4683
Offset: 1
Keywords
Examples
a(7) = 10 since (2,5) is the only prime partition of 7 into distinct smaller parts, and 2*5 = 10. a(11) = 11^2 = 121 because the prime partitions of 11 into smaller parts are: (2,2,7), (2,2,2,5), (2,2,2,2,3), (3,3,5), (2,3,3,3), none of which have only distinct primes.
Links
- Chai Wah Wu, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
a[n_] := Block[{k = 4, p = Prime@ n}, While[PrimeQ[k] || p != Total[First /@ FactorInteger[k]], k++]; k]; Array[a, 50] (* Giovanni Resta, May 31 2020 *)
-
PARI
a(n) = {my(p=prime(n)); forcomposite(k=1, p^2, if (vecsum(factor(k)[, 1]) == p, return(k)););} \\ Michel Marcus, May 31 2020
-
Python
from sympy import prime, primefactors def A335306(n): p = prime(n) for m in range(max(4,2*p-4),p**2+1): if sum(primefactors(m)) == p: return m # Chai Wah Wu, Jun 01 2020
Extensions
More terms from Michel Marcus, May 31 2020
Comments