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!)
A273775 Smallest prime p > n + 1 where a base b exists with abs(b - p) = n such that b^(p-1) == 1 (mod p^2). 1
257, 23, 13, 229, 11, 13, 13, 599, 29, 109, 541, 29, 83, 4099, 2011, 23, 47, 2042851, 115981 (list; graph; refs; listen; history; text; internal format)
OFFSET
4,1
COMMENTS
Smallest p = prime(i) such that at least one of p-n or p+n occurs in the i-th row of A244249.
a(2) = 5. a(3) and a(23) are larger than 10^8 if they exist.
a(3) > 10^10, a(23) > 75*10^8. - Robert G. Wilson v, Dec 16 2016
LINKS
EXAMPLE
For n = 4: p = 257 satisfies b^(p-1) == 1 (mod p^2) for b = p+4 = 261, i.e., 261^256 == 1 (mod 257^2) and is the smallest such p, so a(4) = 257.
MATHEMATICA
f[n_] := Block[{p = NextPrime[n +1]}, While[ PowerMod[p - n, p -1, p^2] != 1 && PowerMod[p + n, p -1, p^2] != 1, q = p = NextPrime@ p]; p] (* Robert G. Wilson v, Dec 14 2016 *)
PROG
(PARI) a(n) = forprime(p=n+2, , my(b=p-n, c=p+n); if(Mod(b, p^2)^(p-1)==1 || Mod(c, p^2)^(p-1)==1, return(p)))
CROSSREFS
Cf. A244249.
Sequence in context: A004217 A351309 A051333 * A182912 A276233 A252726
KEYWORD
nonn,hard,more
AUTHOR
Felix Fröhlich, Dec 11 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 August 7 21:19 EDT 2024. Contains 375017 sequences. (Running on oeis4.)