OFFSET
1,1
LINKS
MATHEMATICA
Select[10*Range[0, 3*10^5] + 1, CompositeQ[#] && Divisible[# - 1, CarmichaelLambda[#]] &] (* Amiram Eldar, Jul 08 2022 *)
PROG
(Python)
from itertools import islice
from sympy import nextprime, factorint
def A354609_gen(): # generator of terms
p, q = 3, 5
while True:
for n in range(p+2+(-p-1)%10, q, 10):
f = factorint(n)
if max(f.values()) == 1 and not any((n-1) % (p-1) for p in f):
yield n
p, q = q, nextprime(q)
KEYWORD
nonn,base
AUTHOR
Omar E. Pol, Jul 08 2022
STATUS
approved