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-3 of 3 results.

A040040 Average of twin prime pairs (A014574), divided by 2. Equivalently, 2*a(n)-1 and 2*a(n)+1 are primes.

Original entry on oeis.org

2, 3, 6, 9, 15, 21, 30, 36, 51, 54, 69, 75, 90, 96, 99, 114, 120, 135, 141, 156, 174, 210, 216, 231, 261, 285, 300, 309, 321, 330, 405, 411, 414, 429, 441, 510, 516, 525, 531, 546, 576, 615, 639, 645, 651, 660, 714, 726, 741, 744, 804, 810, 834, 849, 861, 894
Offset: 1

Views

Author

Keywords

Comments

Intersection of A005097 and A006254. - Zak Seidov, Mar 18 2005
The only possible pairs for 2a(n)+-1 are prime/prime (this sequence), not prime/not prime (A104278), prime/notprime (A104279) and not prime/prime (A104280), ... this sequence + A104280 + A104279 + A104278 = the odd numbers.
These numbers are never k mod (2k+1) or (k+1) mod (2k+1) with 2k+1 < a(n). - Jon Perry, Sep 04 2012
Excluding the first term, all remaining terms have digital root 3, 6 or 9. - J. W. Helkenberg, Jul 24 2013
Positive numbers x such that the difference between x^2 and adjacent squares are prime (both x^2-(x-1)^2 and (x+1)^2-x^2 are prime). - Doug Bell, Aug 21 2015

Crossrefs

Cf. A001359, A006512, A014574, A054735, A111046, A045753 (even terms halved), A002822 (terms divided by 3).
Cf. A221310.

Programs

  • Haskell
    a040040 = flip div 2 . a014574  -- Reinhard Zumkeller, Nov 17 2015
  • Maple
    P := select(isprime,[$1..1789]): map(p->(p+1)/2, select(p->member(p+2,P),P)); # Peter Luschny, Mar 03 2011
  • Mathematica
    Select[Range[900], And @@ PrimeQ[{-1, 1} + 2# ] &] (* Ray Chandler, Oct 12 2005 *)
  • PARI
    p=2; forprime(b=3, 1e4, if(b-p==2, print1((p+1)/2", ")); p=b) \\ Altug Alkan, Nov 10 2015
    

Formula

a(n) = A014574(n)/2 = A054735(n+1)/4 = A111046(n+1)/8.
For n > 1, a(n) = 3*A002822(n-1). - Jason Kimberley, Nov 06 2015
A260689(a(n),1) = A264526(a(n)) = 1. - Reinhard Zumkeller, Nov 17 2015
From Michael G. Kaarhus, Aug 19 2022: (Start)
a(n) = (A001359(n) + 1)/2.
a(n) = (A006512(n) - 1)/2.
For n > 1, a(n) = A167379(n-1) * 3/2. (End)

Extensions

More terms from Cino Hilliard, Oct 21 2002
Title corrected by Daniel Forgues, Jun 01 2009
Edited by Daniel Forgues, Jun 21 2009
Comment corrected by Daniel Forgues, Jul 12 2009

A177139 Numbers n such that (3*n-4, 3*n-2) is a twin prime pair.

Original entry on oeis.org

3, 5, 7, 11, 15, 21, 25, 35, 37, 47, 51, 61, 65, 67, 77, 81, 91, 95, 105, 117, 141, 145, 155, 175, 191, 201, 207, 215, 221, 271, 275, 277, 287, 295, 341, 345, 351, 355, 365, 385, 411, 427, 431, 435, 441, 477, 485, 495, 497
Offset: 1

Views

Author

Roger L. Bagula, May 03 2010

Keywords

Programs

  • Mathematica
    Flatten[Table[If[PrimeQ[3*n - 2] && PrimeQ[3*n - 4], n, {}], {n, 1, 500}]]
    Select[Range[500],And@@PrimeQ[3#-{4,2}]&] (* Harvey P. Dale, Jun 21 2012 *)

Formula

a(n) = (A001359(n+1)+4)/3 = 1+A014574(n+1)/3 = 1+A167379(n). [Eds., May 03 2010]

Extensions

Formula added by the Assoc. Eds. of the OEIS, May 03 2010.

A285983 Prime numbers p such that 3*p has distance <= 2 from the nearest twin prime number.

Original entry on oeis.org

2, 3, 5, 7, 11, 13, 19, 23, 37, 47, 59, 61, 67, 79, 89, 103, 139, 173, 191, 199, 269, 271, 277, 293, 349, 353, 383, 409, 431, 433, 439, 541, 557, 643, 677, 709, 757, 769, 863, 887, 911, 929, 991, 1039, 1087, 1109, 1123, 1129, 1153, 1181, 1187
Offset: 1

Views

Author

Dimitris Valianatos, Apr 29 2017

Keywords

Comments

Also prime numbers distance <= 1 from an element of A167379. - Danny Rorabaugh, May 04 2017

Crossrefs

Programs

  • Mathematica
    fQ[n_] := (PrimeQ[3n -4] && PrimeQ[3n -2]) || (PrimeQ[3n +2] && PrimeQ[3n +4]); Join[{2}, Select[ Prime@ Range@ 200, fQ]] (* Robert G. Wilson v, Apr 30 2017 *)
  • PARI
    {
    print1(2", ");
    forprime(n=3,1000,
             p3=3*n;
             if((isprime(p3+2)&&isprime(p3+4))||(isprime(p3-2)&&isprime(p3-4)),
                 print1(n", ")
               )
            )
    }
Showing 1-3 of 3 results.