OFFSET
1,1
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
24 has distinct prime factors {2, 3} and 2^1 + 3^2 = 11 is prime.
570 has distinct prime factors {2, 3, 5, 19} and 2^1 + 3^2 + 5^3 + 19^4 = 130457 is prime.
MAPLE
filter:= proc(n) local F, i;
if isprime(n) then return false fi;
F:= sort(convert(numtheory:-factorset(n), list));
isprime(add(F[i]^i, i=1..nops(F)))
end proc:
select(filter, [$4..1000]); # Robert Israel, Apr 09 2024
MATHEMATICA
Select[Range@1000, !PrimeQ@#&&PrimeQ@Total[(a=First/@FactorInteger[#])^Range@Length[a]]&]
PROG
(PARI) isok(c) = if (!isprime(c), my(f=factor(c)); isprime(sum(k=1, #f~, f[k, 1]^k))); \\ Michel Marcus, May 07 2021
CROSSREFS
KEYWORD
nonn
AUTHOR
Giorgos Kalogeropoulos, May 07 2021
STATUS
approved