This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A278500 a(n) = largest k such that n+1 = a prime, n+2 = 2 * a prime, ..., n+k is k times a prime, a(n) = 0 if n+1 is not a prime. 4
 1, 2, 0, 2, 0, 1, 0, 0, 0, 1, 0, 3, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 3, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,2 COMMENTS First 4 occurs at n=12720, first 5 occurs at n=19440. See A074200. LINKS Antti Karttunen, Table of n, a(n) for n = 1..21000 EXAMPLE a(12) = 3 as 13 = 1*prime, 14 = 2*prime, 15 = 3*prime. MATHEMATICA Table[If[CompositeQ[n + 1], 0, k = 1; While[Times @@ Boole@ Map[PrimeQ, MapIndexed[#1/First@ #2 &, (n + Range@ k)]] == 1, k++]; k - 1], {n, 120}] (* Michael De Vlieger, Dec 01 2016 *) PROG (PARI) A278500(n) = { my(k=1); while((!((n+k)%k) && isprime((n+k)/k)), k = k+1); (k-1); } for(n=1, 2^20, write("b278500.txt", n, " ", A278500(n))); (Scheme) (define (A278500 n) (let loop ((k 1)) (let ((h (/ (+ n k) k))) (if (or (not (integer? h)) (zero? (A010051 h))) (- k 1) (loop (+ 1 k)))))) CROSSREFS Cf. A072668 (positions of zeros), A006093 (nonzeros), A089965 (positions of terms >= 2), A278583 (of terms >= 3), A278585 (of terms >= 4). Cf. A074200 (position of the first term >= n). Sequence in context: A283978 A002655 A064891 * A035211 A324735 A219495 Adjacent sequences:  A278497 A278498 A278499 * A278501 A278502 A278503 KEYWORD nonn AUTHOR Antti Karttunen, Nov 30 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 | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified May 23 13:13 EDT 2019. Contains 323514 sequences. (Running on oeis4.)