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.

A096937 Least k such that k*P(n)#/2 - 2 and k*P(n)#/2 + 2 are both primes, where P(i)= i-th prime, P(i)# = i-th primorial.

Original entry on oeis.org

5, 3, 1, 1, 3, 1, 3, 41, 27, 3, 1, 171, 97, 19, 35, 13, 217, 57, 79, 133, 41, 219, 85, 43, 477, 205, 35, 455, 635, 275, 2081, 33, 513, 671, 427, 177, 997, 2671, 601, 123, 525, 1139, 411, 479, 363, 1311, 4685, 109, 159, 3367, 2761, 257, 161, 137, 49, 393, 3553, 1807
Offset: 1

Views

Author

Pierre CAMI, Aug 18 2004

Keywords

Examples

			1*2*3*5*7/2 - 2 = 103, 1*2*3*5*7/2 + 2 = 107, 103 and 107 are both primes, so for n=4, k=1.
		

Crossrefs

Cf. A060256.

Programs

  • Mathematica
    Primorial[n_] := Product[Prime[i], {i, 1, n}]; f[n_] := Block[{p = Primorial[n]/2, k = 1}, While[ !PrimeQ[k*p - 2] || !PrimeQ[k*p + 2], k++ ]; k]; Table[ f[n], {n, 50}] (* Robert G. Wilson v, Aug 19 2004 *)

Extensions

More terms from Robert G. Wilson v, Aug 19 2004