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.

A099382 Primes of the form 3p - q - 3, where p and q are consecutive primes.

Original entry on oeis.org

5, 7, 17, 19, 29, 31, 37, 53, 67, 79, 97, 113, 127, 137, 151, 157, 167, 197, 199, 211, 269, 293, 337, 349, 353, 379, 383, 389, 439, 449, 457, 547, 557, 569, 607, 617, 619, 653, 661, 691, 751, 757, 787, 829, 857, 877, 887, 907, 919, 947
Offset: 1

Views

Author

Giovanni Teofilatto, Nov 17 2004

Keywords

Crossrefs

Cf. A099389.

Programs

  • PARI
    v=List(); p=2; forprime(q=3,1e6, if(isprime(t=3*p-q-3), listput(v,t)); p=q); v=vecsort(Vec(v),,8)

Extensions

Edited and extended by Klaus Brockhaus, Nov 19 2004
Terms corrected by Charles R Greathouse IV, Feb 15 2011

A100021 a(n) = 3*prime(n) - prime(n+1) - 3.

Original entry on oeis.org

0, 1, 5, 7, 17, 19, 29, 31, 37, 53, 53, 67, 77, 79, 85, 97, 113, 113, 127, 137, 137, 151, 157, 167, 187, 197, 199, 209, 211, 209, 247, 253, 269, 265, 293, 293, 305, 319, 325, 337, 353, 349, 377, 379, 389, 383, 407, 439, 449, 451, 457, 473, 469, 493, 505, 517, 533, 533, 547
Offset: 1

Views

Author

Giovanni Teofilatto, Nov 20 2004

Keywords

Comments

Except for the initial term, a(n)==(1,5) mod 6.

Crossrefs

Cf. A099389 for the primes arising in the sequence, A098764.

Programs

  • Maple
    f:=n->3*ithprime(n)-ithprime(n+1)-3;
  • Mathematica
    3#[[1]]-#[[2]]-3&/@Partition[Prime[Range[80]],2,1] (* Harvey P. Dale, Oct 13 2018 *)
  • PARI
    a(n) = 3*prime(n) - prime(n+1) - 3; \\ Michel Marcus, Jan 31 2023

Formula

a(n) = A098764(n) - 3.

Extensions

Corrected by Neven Juric (neven.juric(AT)apis-it.hr), rechecked by N. J. A. Sloane, Jun 13 2006
Showing 1-2 of 2 results.