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.

A215808 Primes of the form 2*prime(k) - prime(k+1).

Original entry on oeis.org

3, 3, 17, 41, 47, 67, 151, 167, 199, 227, 251, 257, 347, 367, 557, 587, 601, 607, 641, 647, 727, 941, 971, 1051, 1091, 1097, 1117, 1181, 1217, 1277, 1361, 1427, 1447, 1447, 1487, 1487, 1499, 1607, 1697, 1741, 1747, 1741, 1777, 1877, 1901, 2087, 2143, 2281
Offset: 1

Views

Author

Zak Seidov, Sep 06 2012

Keywords

Comments

Corresponding values of k: 3, 4, 9, 15, 16, 21, 37, 40, 47, 51, 55, 56, 71, 74, 103 (A216075).

Examples

			k=3: 2*5-7=3, k=4: 2*7-11=3, k=9: 2*23-29=17.
		

Crossrefs

Programs

  • Mathematica
    pr=Prime[Range[1000]]; s=Select[2*Most[pr]-Rest[pr],PrimeQ]
    Select[2#[[1]]-#[[2]]&/@Partition[Prime[Range[500]],2,1],PrimeQ] (* Harvey P. Dale, Feb 25 2017 *)

A228374 Numbers n such that 2*prime(n) - prime(n+1) is not prime.

Original entry on oeis.org

1, 2, 5, 6, 7, 8, 10, 11, 12, 13, 14, 17, 18, 19, 20, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 38, 39, 41, 42, 43, 44, 45, 46, 48, 49, 50, 52, 53, 54, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 72, 73, 75, 76, 77, 78, 79, 80, 81, 82
Offset: 1

Views

Author

Vincenzo Librandi, Aug 21 2013

Keywords

Comments

Complement of A216075.

Examples

			7 is in the sequence because 2*17-19=15 and 15 is not prime.
		

Crossrefs

Cf. A216075.

Programs

  • Magma
    [n: n in [1..100]| not IsPrime(2*NthPrime(n) - NthPrime(n+1))];
  • Mathematica
    f[n_]: = (2 Prime[n] - Prime[n + 1]); Select[Range[110], ! PrimeQ[f[#]]&]
    Flatten[Position[2#[[1]]-#[[2]]&/@Partition[Prime[Range[100]],2,1],?(!PrimeQ[#]&)]] (* _Harvey P. Dale, Jan 12 2016 *)
Showing 1-2 of 2 results.