A288189 a(n) is the smallest composite number whose sum of prime divisors (with multiplicity) is divisible by prime(n).
4, 8, 6, 10, 28, 22, 52, 34, 76, 184, 58, 213, 148, 82, 172, 309, 424, 118, 393, 268, 142, 584, 316, 664, 573, 388, 202, 412, 214, 436, 753, 508, 813, 274, 1465, 298, 933, 974, 652, 1336, 1384, 358, 1137, 382, 772, 394, 1257, 1329, 892, 454, 916, 1864, 478, 1497, 1538, 1569
Offset: 1
Keywords
Examples
a(5)=6 because 6 = 2*3 is the smallest number whose sum of prime divisors (2+3 = 5) is divisible by 5. a(37) = 213 = A288814(74) = A288814(2*37).
Links
- Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
With[{s = Array[Boole[CompositeQ@ #] Total@ Flatten[ConstantArray[#1, #2] & @@@ FactorInteger@ #] &, 10^4] /. 0 -> ""}, Table[FirstPosition[s, ?(Mod[#, p] == 0 &)][[1]], {p, Prime@ Range@ 56}]] (* _Michael De Vlieger, Apr 14 2018 *)
-
PARI
sopfr(k) = my(f=factor(k)); sum(j=1, #f~, f[j, 1]*f[j, 2]); a(n) = my(pn=prime(n)); forcomposite(c=pn, , if (sopfr(c) % pn == 0, return(c))); \\ Michel Marcus, Jul 03 2017
Comments