login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A263984 Least composite primitive root of n-th prime. 1
9, 8, 8, 10, 6, 6, 6, 10, 10, 8, 12, 15, 6, 12, 10, 8, 6, 6, 12, 21, 14, 6, 6, 6, 10, 8, 6, 6, 6, 6, 6, 6, 6, 12, 8, 6, 6, 12, 10, 8, 6, 10, 21, 10, 8, 6, 22, 6, 6, 6, 6, 14, 14, 6, 6, 10, 8, 6, 6, 12, 12, 8, 14, 22, 10, 8, 28, 10, 6, 18 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
The only square in the sequence is a(1) = 9.
It seems nearly certain that all nonsquare composite numbers occur in this sequence.
LINKS
MATHEMATICA
primrootQ[n_, r_] := MultiplicativeOrder[r, n] == EulerPhi[n];
a[n_] := Module[{p = Prime[n], k = 6}, While[PrimeQ[k] || GCD[k, p] != 1 || !primrootQ[p, k], k++]; k];
Array[a, 70] (* Jean-François Alcover, Oct 23 2020, after PARI code *)
PROG
(PARI) isprimroot(n, r)=znorder(Mod(r, n))==eulerphi(n)
a(n)=my(p=prime(n), k=6); while(isprime(k)||gcd(k, p)!=1||!isprimroot(p, k), k++); k
CROSSREFS
Sequence in context: A347199 A011228 A175572 * A021095 A090998 A163930
KEYWORD
nonn
AUTHOR
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 28 08:22 EDT 2024. Contains 371236 sequences. (Running on oeis4.)