%I #21 Mar 06 2024 04:47:45
%S 2,6,10,22,30,34,42,58,70,78,82,102,118,130,142,190,202,210,214,274,
%T 298,310,322,330,358,382,394,442,454,462,478,510,538,562,582,610,622,
%U 658,694,714,730,742,790,838,862,922,930,970,1002,1038,1042,1110,1138,1198
%N Numbers k > 1 such that p + k/p is prime for every prime p that divides k.
%C All terms of this sequence are even and squarefree.
%C The only term == 2 (mod 3) is 2. - _Robert Israel_, Jan 09 2024
%H Harvey P. Dale, <a href="/A140775/b140775.txt">Table of n, a(n) for n = 1..1000</a>
%e The primes dividing 70 are 2, 5, 7. Now, 2 + 70/2 = 37; 5 + 70/5 = 19; 7 + 70/7 = 17. Since 37, 19 and 17 are each prime, then 70 is included in this sequence.
%p filter:= t -> andmap(p -> isprime(p+t/p), numtheory:-factorset(t)):
%p select(filter, [seq(i,i=2..2000,4)]); # _Robert Israel_, Jan 09 2024
%t fQ[n_] := Block[{p = First@ Transpose@ FactorInteger@ n}, Union@ PrimeQ[p + n/p] == {True}]; Select[ Range[2, 1221], fQ@# &] (* _Robert G. Wilson v_, May 30 2008 *)
%t pnpQ[n_]:=AllTrue[#+n/#&/@Transpose[FactorInteger[n]][[1]],PrimeQ]; Select[ Range[2,1200],pnpQ] (* The program uses the AllTrue function from Mathematica version 10 *) (* _Harvey P. Dale_, Apr 15 2016 *)
%Y Cf. A140776, A140777, A294925.
%K nonn
%O 1,1
%A _Leroy Quet_, May 29 2008
%E More terms from _Robert G. Wilson v_, May 30 2008
%E Definition edited by _Robert Israel_, Jan 09 2024