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!)
A240657 Least k such that 2^k == -1 (mod prime(n)), or 0 if no such k exists. 2
0, 1, 2, 0, 5, 6, 4, 9, 0, 14, 0, 18, 10, 7, 0, 26, 29, 30, 33, 0, 0, 0, 41, 0, 24, 50, 0, 53, 18, 14, 0, 65, 34, 69, 74, 0, 26, 81, 0, 86, 89, 90, 0, 48, 98, 0, 105, 0, 113, 38, 0, 0, 12, 25, 8, 0, 134, 0, 46, 35, 47, 146, 51, 0, 78, 158, 15, 0, 173, 174, 44, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
COMMENTS
The least k, if it exists, such that prime(n) divides 2^k + 1.
LINKS
FORMULA
a(n) = A014664(n)/2 if A014664(n) is even, otherwise 0.
MATHEMATICA
Table[p = Prime[n]; s = Select[Range[p/2], PowerMod[2, #, p] == p - 1 &, 1]; If[s == {}, 0, s[[1]]], {n, 100}]
CROSSREFS
Cf. A014664 (order of 2 mod prime(n)), A072936 (zero terms).
Sequence in context: A051111 A068558 A245058 * A262420 A240662 A188724
KEYWORD
nonn
AUTHOR
T. D. Noe, Apr 14 2014
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 June 27 20:20 EDT 2024. Contains 373753 sequences. (Running on oeis4.)