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!)
A214069 Least m>0 such that prime(n)+m and n-m are relatively prime. 1
2, 1, 2, 1, 2, 1, 2, 1, 2, 2, 6, 1, 2, 1, 2, 2, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 4, 2, 4, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 2, 2, 1, 2, 1, 2, 2, 6, 1, 2, 1, 2, 2, 6, 1, 2, 2, 2, 1, 4, 1, 2, 1, 2, 2, 4, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 2, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 2, 4, 1, 2, 1, 2 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
gcd(12,10) = 2 and gcd(13,9) = 1, so that a(11) = 2.
MATHEMATICA
Table[m = 1; While[GCD[Prime[n] + m, n - m] != 1, m++]; m, {n, 1, 140}]
PROG
(PARI) vector(100, n, m=1; while(gcd(prime(n)+m, n-m)!=1, m++); m) \\ Derek Orr, May 30 2015
CROSSREFS
Cf. A214052.
Sequence in context: A161058 A161262 A161287 * A167969 A245192 A235431
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Jul 26 2012
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 16 08:27 EDT 2024. Contains 371698 sequences. (Running on oeis4.)