The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A103309 Smallest prime primitive root of n that is less than n, or 0 if none exists. 7
 0, 0, 0, 2, 3, 2, 5, 3, 0, 2, 3, 2, 0, 2, 3, 0, 0, 3, 5, 2, 0, 0, 7, 5, 0, 2, 7, 2, 0, 2, 0, 3, 0, 0, 3, 0, 0, 2, 3, 0, 0, 7, 0, 3, 0, 0, 5, 5, 0, 3, 3, 0, 0, 2, 5, 0, 0, 0, 3, 2, 0, 2, 3, 0, 0, 0, 0, 2, 0, 0, 0, 7, 0, 5, 5, 0, 0, 0, 0, 3, 0, 2, 7, 2, 0, 0, 3, 0, 0, 3, 0, 0, 0, 0, 5, 0, 0, 5, 3, 0, 0, 2, 0, 5, 0 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,4 COMMENTS Differs from A046145 only for indices n = 2, 41, 109, 151, 229, ...; see A103335. - Jeppe Stig Nielsen, Mar 06 2020 LINKS Robert Israel, Table of n, a(n) for n = 0..10000 G. Martin, The Least Prime Primitive Root and the Shifted Sieve, Acta Arith. 80 (1997), no. 3, 277-288; arXiv:math/9807104 [math.NT], 1998. Eric Weisstein's World of Mathematics, Primitive Root. MAPLE F:= proc(n)   local r;   r:= numtheory:-primroot(n);   while r::integer and not isprime(r) do     r:= numtheory:-primroot(r, n);   od:   if r = FAIL then 0 else r fi end proc: seq(F(n), n=0..200); # Robert Israel, May 18 2015 MATHEMATICA a[n_] := SelectFirst[PrimitiveRootList[n], PrimeQ[#] && # < n&] /. Missing["NotFound"] -> 0; Table[a[n], {n, 0, 104}] (* Jean-François Alcover, Nov 15 2017 *) CROSSREFS Cf. A001918, A046144, A046145, A046146, A103310, A103335. Sequence in context: A005731 A132962 A046145 * A248207 A174621 A007967 Adjacent sequences:  A103306 A103307 A103308 * A103310 A103311 A103312 KEYWORD easy,nonn AUTHOR Harry J. Smith, Jan 29 2005 STATUS approved

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

Last modified June 13 00:57 EDT 2021. Contains 344980 sequences. (Running on oeis4.)