login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A100021
a(n) = 3*prime(n) - prime(n+1) - 3.
3
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,3
COMMENTS
Except for the initial term, a(n)==(1,5) mod 6.
LINKS
FORMULA
a(n) = A098764(n) - 3.
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 *)
PROG
(PARI) a(n) = 3*prime(n) - prime(n+1) - 3; \\ Michel Marcus, Jan 31 2023
CROSSREFS
Cf. A099389 for the primes arising in the sequence, A098764.
Sequence in context: A363752 A045318 A040102 * A099389 A099382 A163633
KEYWORD
nonn,less
AUTHOR
Giovanni Teofilatto, Nov 20 2004
EXTENSIONS
Corrected by Neven Juric (neven.juric(AT)apis-it.hr), rechecked by N. J. A. Sloane, Jun 13 2006
STATUS
approved