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!)
A064367 a(n) = 2^n mod prime(n), or 2^n = k*prime(n) + a(n) with integer k. 6
0, 1, 3, 2, 10, 12, 9, 9, 6, 9, 2, 26, 33, 1, 9, 28, 33, 27, 13, 48, 8, 36, 47, 4, 95, 20, 76, 62, 23, 4, 8, 117, 68, 25, 138, 64, 150, 43, 61, 10, 72, 156, 40, 12, 73, 51, 48, 41, 24, 26, 71, 48, 32, 16, 128, 173, 74, 110, 118, 59, 30, 247, 202, 208, 284, 53, 128, 32, 139 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
COMMENTS
Below the exponent n=10000, some integers (like 5,7,14,17,19,22,...,44, etc.) are not yet present among residues. Will they appear later?
For a(n) with n <= 10^6, the following residues have not yet appeared: {19, 22, 46, 52, 57, 65, 70, 77, 81, 85, 88, 90, 91, 103, 104, 106, 108, 115, 120, 122, 123, 125, ..., 15472319} (14537148 terms). - Michael De Vlieger, Jul 16 2017
Heuristically, the probability of 2^n mod prime(n) taking a given value is approximately 1/prime(n) for large n. Since the sum of 1/prime(n) diverges, we should expect each positive integer to appear infinitely many times in the sequence. However, since the sum diverges very slowly, the first n where it appears may be very large. - Robert Israel, Jul 17 2017
LINKS
FORMULA
a(n) = A000079(n) mod A000040(n).
MAPLE
seq(2 &^ n mod ithprime(n), n=1..100); # Robert Israel, Jul 17 2017
MATHEMATICA
Array[PowerMod[2, #, Prime@ #] &, 69] (* Michael De Vlieger, Jul 16 2017 *)
PROG
(PARI) { p=1; for (n=1, 1000, write("b064367.txt", n, " ", (p*=2) % prime(n)) ) } \\ Harry J. Smith, Sep 12 2009
CROSSREFS
Sequence in context: A367300 A103245 A019242 * A113980 A095675 A340806
KEYWORD
nonn
AUTHOR
Labos Elemer, Sep 27 2001
EXTENSIONS
Definition corrected by Harry J. Smith, Sep 12 2009
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 April 25 08:27 EDT 2024. Contains 371964 sequences. (Running on oeis4.)