A384658 Primitive terms in A384657: numbers k such that A384655(k) > k and A384655(d) <= d for every proper divisor d of k.
24, 80, 108, 112, 180, 200, 252, 280, 300, 352, 396, 416, 420, 440, 468, 520, 612, 660, 684, 780, 828, 1044, 1088, 1116, 1216, 1332, 1472, 1476, 1548, 1692, 1856, 1908, 1984, 2124, 2196, 2288, 2412, 2556, 2628, 2844, 2988, 2992, 3204, 3344, 3492, 3536, 3636, 3708, 3852, 3924, 3952
Offset: 1
Keywords
Examples
24 is a term since A384655(24) = 25 > 24, the proper divisors of 24 are {1, 2, 3, 4, 6, 8, 12}, A384655(1) = 0 < 1, A384655(2) = 1 < 2, A384655(3) = 1 < 3, A384655(4) = 3 < 4, A384655(6) = 4 < 6, A384655(8) = 7 < 8, and A384655(12) = 11 < 12.
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
f[p_, e_, k_] := p^e - If[e < k, 0, p^(e - k)]; q[n_] := Module[{fct = FactorInteger[n], emax, s}, emax = Max[fct[[;; , 2]]]; If[emax < 2, False, s = emax * n; Do[s -= Times @@ (f[#1, #2, k] & @@@ fct), {k, 1, emax}]; s > n]]; primQ[n_] := q[n] && AllTrue[Divisors[n], # == n || !q[#] &]; Select[Range[4000], primQ]
-
PARI
is1(m) = {my(f = factor(m), p, e, emax, s); if(issquarefree(f), 0, p = f[,1]; e = f[,2]; emax = vecmax(e); s = emax*m; for(k = 1, emax, s -= prod(i = 1, #p, p[i]^e[i] - if(e[i] < k, 0, p[i]^(e[i]-k)))); s > m);} isok(k) = if(!is1(k), 0, fordiv(k, d, if(d < k && is1(d), return(0))); 1);
Comments