A364037 Least number k such that the floor of the average of the distinct prime factors of k is n, or -1 if no such number exists.
2, 3, 14, 5, 22, 7, 39, 34, 38, 11, 46, 13, 115, 58, 62, 17, 155, 19, 111, 82, 86, 23, 94, 141, 235, 106, 159, 29, 118, 31, 183, 305, 134, 201, 142, 37, 219, 365, 158, 41, 166, 43, 415, 178, 267, 47, 623, 194, 291, 202, 206, 53, 214, 218, 327, 226, 339, 59, 791, 61
Offset: 2
Keywords
Examples
a(4) = 14, because 14 = 2 * 7, floor((2 + 7) / 2) = 4, and no lesser number satisfies this.
Crossrefs
Cf. A363895.
Programs
-
Mathematica
seq[len_, kmax_] := Module[{s = Table[0, {len}], c = 0, k = 2, i}, While[c < len && k < kmax, i = Floor[Mean[FactorInteger[k][[;; , 1]]]] - 1; If[i <= len && s[[i]] == 0, c++; s[[i]] = k]; k++]; s]; seq[60, 1000] (* Amiram Eldar, Jul 02 2023 *)
-
PARI
f(n) = my(p = factor(n)[, 1]); vecsum(p)\#p; \\ A363895 a(n) = my(k=2); while (f(k) != n, k++); k; \\ Michel Marcus, Jul 02 2023
Formula
a(p) = p for prime p. - David A. Corneth, Jul 02 2023
Comments