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!)
A274021 Least positive x < n-1 such that x^y == -1 (mod n) for some y > 1, or 0 if no such x exist. 1
0, 0, 0, 0, 2, 0, 3, 0, 2, 3, 2, 0, 2, 3, 0, 0, 2, 5, 2, 0, 5, 7, 5, 0, 2, 5, 2, 3, 2, 0, 3, 0, 2, 3, 19, 11, 2, 3, 17, 0, 2, 5, 2, 7, 14, 5, 5, 0, 3, 3, 0, 23, 2, 5, 19, 31, 2, 3, 2, 0, 2, 3, 5, 0, 2, 17, 2, 0, 5, 19, 7, 23, 3, 3, 14, 3, 6, 17, 3, 0, 2, 3, 2, 47, 13, 3, 5, 7, 3, 29, 10 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,5
COMMENTS
Indices of nonzero terms are listed in A126949 (in this sense the present sequence can be seen as characteristic function of A126949), indices of zeros (except for n=1) are given in A178751. Without the restriction x < n-1, one would have a(n) = n-1 instead of the zeros, since (n-1)^3 = (-1)^3 = -1 (mod n) for all n.
LINKS
PROG
(PARI) A274021(n)={for(x=2, n-2, gcd(x, n)>1&&next; my(t=Mod(x, n)); while(abs(centerlift(t))>1, t*=x); t==-1&&return(x))}
CROSSREFS
Sequence in context: A355930 A229946 A127460 * A303711 A154109 A011374
KEYWORD
nonn
AUTHOR
M. F. Hasler, Jun 07 2016
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 July 16 19:40 EDT 2024. Contains 374358 sequences. (Running on oeis4.)