A373194 Numbers k such that phi(k) is a Lucas number.
1, 2, 3, 4, 5, 6, 8, 10, 12, 19, 27, 38, 54, 2049, 2732, 4098, 5779, 11558, 36717, 48956, 73434, 21994424093409, 29325898791212, 43988848186818, 439894502304193355596420713117, 586526003072257807461894284156, 879789004608386711192841426234, 56570478046795035524653081529155199270281, 56570478046795035532692004624509431078281
Offset: 1
Keywords
Links
- Hugo Pfoertner, Table of n, a(n) for n = 1..64
- Max Alekseyev, PARI/GP Scripts for Miscellaneous Math Problems (invphi.gp).
Programs
-
Mathematica
lucasQ[n_] := Or @@ (IntegerQ[Sqrt[#]] & /@ (5*n^2 + 20*{-1, 1})); Select[Range[10^4], lucasQ[EulerPhi[#]] &] (* Amiram Eldar, May 27 2024 *)
-
PARI
isok(k) = islucas(eulerphi(k)); \\ using islucas from A102460 \\ Michel Marcus, May 27 2024
-
PARI
\\ read Max Alekseyev's invphi.gp a373194(uptoNLucas) = my(A=List()); for(n=0, uptoNLucas, my(L = invphi(fibonacci(n+1) + fibonacci(n-1))); if(#L, for(k=1, #L, listput(A,L[k])))); Set(A); a373194(150) \\ Hugo Pfoertner, Jun 10 2024
-
Python
from sympy.ntheory.primetest import is_square from sympy import totient islucas = lambda n: is_square(5*n*n - 20) or is_square(5*n*n + 20) print([n for n in range(1,10**4) if islucas(totient(n))])
Extensions
a(18)-a(21) from Amiram Eldar, May 27 2024
a(22) onwards from Hugo Pfoertner, May 27 2024