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

A176616 Primes of the form x^2 + 7*y^2, where x and y=x+1 are consecutive natural numbers.

Original entry on oeis.org

7, 29, 67, 191, 277, 379, 631, 947, 1129, 1327, 2017, 2557, 2851, 4561, 4951, 5779, 6217, 8647, 9181, 12721, 13367, 14029, 15401, 16111, 17579, 20707, 21529, 22367, 24091, 24977, 31627, 36857, 37951, 42487, 43661, 44851, 47279, 53629, 58997
Offset: 1

Views

Author

Giovanni Teofilatto, Apr 22 2010

Keywords

Comments

Primes of the form 8*n^2+14*n+7 = (2*n+2)*(4*n+3)+1 = A000384(2*n+2)+1. - Vincenzo Librandi, Apr 25 2010

Crossrefs

Cf. A176608.
A285790 is an almost identical sequence.

Programs

  • Magma
    [ a: n in [0..250] | IsPrime(a) where a is 8*n^2+14*n+7 ] // Vincenzo Librandi, Apr 25 2010
  • Mathematica
    Select[Table[x^2+7(x+1)^2,{x,0,100}],PrimeQ] (* Harvey P. Dale, May 03 2024 *)

Extensions

Definition made more accurate by R. J. Mathar, May 04 2010
Corrected (inserted 7) and extended by Vincenzo Librandi, Apr 25 2010
Offset corrected by Mohammed Yaseen, May 20 2023

A285792 Primes equal to an octagonal number plus 1.

Original entry on oeis.org

2, 41, 97, 281, 409, 937, 1409, 2297, 4721, 5209, 6257, 8009, 8641, 12161, 14561, 18097, 21001, 23057, 24121, 26321, 27457, 37409, 42961, 50441, 52009, 55217, 56857, 60209, 70841, 76481, 90481, 139537, 147409, 152777, 161009, 169457, 172321, 227977, 238009
Offset: 1

Views

Author

Colin Barker, Apr 26 2017

Keywords

Comments

Primes in A056105. - Omar E. Pol, Apr 26 2017

Crossrefs

Programs

  • Mathematica
    Select[PolygonalNumber[8,Range[300]]+1,PrimeQ] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Oct 22 2017 *)
  • PARI
    pg(m, n) = (n^2*(m-2)-n*(m-4))/2 \\ n-th m-gonal number
    maxk=300; L=List(); for(k=1, maxk, if(isprime(p=pg(8, k) + 1), listput(L, p))); Vec(L)

A285789 Primes equal to a pentagonal number plus 1.

Original entry on oeis.org

2, 13, 23, 71, 211, 331, 853, 1163, 1427, 2381, 2753, 3433, 3877, 5923, 6113, 6701, 7741, 8627, 9323, 11311, 12377, 14653, 14951, 17443, 18427, 23003, 27271, 31033, 32341, 32783, 34127, 38321, 43777, 52361, 55201, 56941, 57527, 62323, 64171, 64793, 69877
Offset: 1

Views

Author

Colin Barker, Apr 26 2017

Keywords

Crossrefs

Programs

  • Mathematica
    Select[PolygonalNumber[5,Range[300]]+1,PrimeQ] (* Harvey P. Dale, Dec 04 2024 *)
  • PARI
    pg(m, n) = (n^2*(m-2)-n*(m-4))/2 \\ n-th m-gonal number
    maxk=300; L=List(); for(k=1, maxk, if(isprime(p=pg(5, k) + 1), listput(L, p))); Vec(L)

A285791 Primes equal to a heptagonal number plus 1.

Original entry on oeis.org

2, 19, 113, 149, 541, 617, 971, 1289, 1783, 2357, 3011, 3187, 5689, 6427, 7481, 7757, 9829, 12497, 12853, 14327, 15881, 17099, 18793, 21023, 24851, 28463, 30637, 31193, 45361, 50909, 54539, 60607, 63761, 66179, 69473, 70309, 83449, 88079, 90917, 91873, 94771
Offset: 1

Views

Author

Colin Barker, Apr 26 2017

Keywords

Crossrefs

Programs

  • PARI
    pg(m, n) = (n^2*(m-2)-n*(m-4))/2 \\ n-th m-gonal number
    maxk=300; L=List(); for(k=1, maxk, if(isprime(p=pg(7, k) + 1), listput(L, p))); Vec(L)
    
  • Python
    from sympy import isprime
    def heptagonal(n): return n*(5*n-3)//2
    def aupto(limit):
      alst, n, hn = [], 1, heptagonal(1)
      while hn < limit:
        if isprime(hn+1): alst.append(hn+1)
        n, hn = n+1, heptagonal(n+1)
      return alst
    print(aupto(94771)) # Michael S. Branicky, Feb 19 2021
Showing 1-4 of 4 results.