OFFSET
1,2
PROG
(Python)
from sympy import primitive_root
from itertools import count, islice
def f(n): r = primitive_root(n); return r if r != None else 0
def agen(r=0): yield from ((m, r:=f(m))[1] for m in count(1) if f(m) > r)
print(list(islice(agen(), 18))) # Michael S. Branicky, Feb 13 2023
CROSSREFS
KEYWORD
nonn,more
AUTHOR
Sven Simon, Mar 30 2003
EXTENSIONS
a(24) from Michael S. Branicky, Feb 20 2023
STATUS
approved