OFFSET
1,1
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
MAPLE
with(numtheory): for n from 1 by 2 to 10^4 do if [isprime(n+phi(n)),
isprime(n-phi(n))]=[true, true] then print(n); fi; od; # Muniru A Asiru, Aug 31 2017
MATHEMATICA
Select[ Range[1500], PrimeQ[ # + EulerPhi[ # ]] && PrimeQ[ # - EulerPhi[ # ]] & ]
epQ[n_]:=Module[{ep=EulerPhi[n]}, AllTrue[n+{ep, -ep}, PrimeQ]]; Select[ Range[ 1500], epQ] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Aug 22 2016 *)
PROG
(PARI) is(n)=my(t=eulerphi(n)); isprime(n-t) && isprime(n+t) \\ Charles R Greathouse IV, Jan 25 2017
(GAP)
A068081:=[];; for n in [1, 3..10^4+1] do if IsPrime(n+Phi(n)) and IsPrime(n-Phi(n)) then Add(A068081, n); fi; od; A068081; # Muniru A Asiru, Aug 31 2017
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Amarnath Murthy, Feb 17 2002
EXTENSIONS
Edited and extended by Robert G. Wilson v, Feb 18 2002
STATUS
approved