cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-2 of 2 results.

A257466 Smallest prime number p such that p + pps(1), p + pps(2), ..., p + pps(n) are all prime but p + pps(n+1) is not, where pps(n) is the partial primorial sum (A060389(n)).

Original entry on oeis.org

2, 17, 11, 5, 3, 101, 19469, 38669, 191459, 191, 59, 3877889, 494272241, 360772331, 6004094833991, 41320119600341
Offset: 0

Views

Author

Fred Schneider, Apr 25 2015

Keywords

Comments

The n-th member in the sequence m is the smallest prime with exactly n prime terms starting from m + 2.

Examples

			For prime 3: 3+2, 3+8, 3+38, 3+248 are all prime. 3+2558 = 13 * 197 is not. So a(4)= 3. (3 is the smallest prime that has exactly 4 terms.)
2 has zero terms because 2+2 is composite, so a(0)=2.
		

Crossrefs

Programs

  • PARI
    pps(n)=my(s, P=1); forprime(p=2, prime(n), s+=P*=p); s;
    isokpps(p, n) = {for (k=1, n, if (!isprime(p+pps(k)), return (0));); if (!isprime(p+pps(n+1)), return (1));}
    a(n) = {my(p = 2); while (!isokpps(p,n), p = nextprime(p+1)); p;} \\ Michel Marcus, May 02 2015

Extensions

a(15) from Fred Schneider, May 15 2015

A258035 Smallest prime number p such that p + pssq(1), p + pssq(2), ... p + pssq(n) are all prime but p+pssq(n+1) is not, where pssq(n) is the partial sum of the square of the proper terms of the primorial (A189997(n)-1).

Original entry on oeis.org

2, 37, 3, 7, 13, 277, 2617, 43, 2924263, 300999679, 631112173, 1368737917, 4428230508349
Offset: 0

Views

Author

Fred Schneider, May 16 2015

Keywords

Examples

			a(3) = 7 because 7 + 4, 7 + 40 and 7 + 940 are primes, but 7 + 45040 = 107 * 421 is not.
		

Crossrefs

Cf. A257466 (analog for partial primorial sum), A257467 (analog for primorial squared).
Showing 1-2 of 2 results.