The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A341716 a(n) = smallest k such that the decimal concatenation n||n+1||n+2||...||n+k is prime, or -1 if no such prime exists. 9
0, 0, 3, 0, 1, 0, 1, 178 (list; graph; refs; listen; history; text; internal format)
OFFSET
2,3
COMMENTS
These are the values of k from A341715. See that entry for more information.
From Chai Wah Wu, Feb 22 2021: (Start)
Theorem: For n > 1, a(n)+n is odd. If a(n) > 0, then a(n) !== 2 (mod 3) and a(n)+2n !== 0 (mod 3).
Proof: For n > 1, n||n+1||...||n+k needs to be odd to be prime, i.e., n+k is odd. n||n+1||...||n+k can be written as x+y where x = n||n||...||n||n and y = 1||0...2||...||0...k. The only exception is when n+i has more decimal digits than n for some i <= k in which case there are some extra zeros inserted into x and y.
In any case x is divisible by n and by 10..10..1 whose digit sum is k+1, i.e., x == n*(k+1) (mod 3).
Similarly the sum of digits of y mod 3 == Sum_{i=1..k} (i mod 3) == (Sum_{i=1..k} i) == k(k+1)/2 (mod 3). This means that x+y == (k+1)(k+2n)/2 (mod 3). If either k+1 or k+2n is a multiple of 3, then x+y is a multiple of 3. We know x+y > 3 since a(n) > 0 and thus x+y is not a prime.
Corollary: Suppose n > 3. If n == 0 (mod 6), then a(n) == 1 (mod 6). If n == 1 (mod 6), then a(n) == 0 (mod 6). If n == 2 (mod 6), then a(n) == 1 or 3 (mod 6). If n == 3 (mod 6), then a(n) == 4 (mod 6). If n == 4 (mod 6), then a(n) == 3 (mod 6). If n == 5 (mod 6), then a(n) == 0 or 4 (mod 6).
(End)
LINKS
FORMULA
a(n) = 0 iff n is prime, otherwise a(n) = A084559(n)-n. - M. F. Hasler, Feb 22 2021
CROSSREFS
Sequence in context: A325268 A232630 A331569 * A216600 A356679 A356681
KEYWORD
nonn,base,more
AUTHOR
N. J. A. Sloane, Feb 22 2021
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 May 16 15:21 EDT 2024. Contains 372554 sequences. (Running on oeis4.)