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

A106483 Primes p such that 2*p^2 - 1 is also prime.

Original entry on oeis.org

2, 3, 7, 11, 13, 17, 41, 43, 59, 73, 109, 113, 127, 137, 157, 179, 181, 197, 199, 211, 251, 263, 277, 293, 311, 353, 367, 379, 409, 419, 433, 487, 563, 571, 577, 617, 619, 659, 701, 739, 743, 757, 797, 811, 827, 829, 839, 857, 937, 941, 1009, 1039, 1063
Offset: 1

Views

Author

Jonathan Vos Post, May 03 2005

Keywords

Crossrefs

Cf. A000040, A001358, A007588, A106482, A106484, A177104 (2p^3-1 prime), A182785 (2p^4-1 prime)
Cf. A092057 (2p^2 - 1).

Programs

  • Magma
    [p: p in PrimesUpTo(2500)|  IsPrime(2*p^2-1)]; // Vincenzo Librandi, Jan 29 2011
  • Maple
    q:= p-> andmap(isprime, [p, 2*p^2-1]):
    select(q, [$2..2000])[];  # Alois P. Heinz, Jun 21 2022
  • Mathematica
    Select[Table[Prime[n], {n, 500}], PrimeQ[2*#^2 - 1] &] (* Ray Chandler, May 03 2005 *)

Formula

a(n) is in this sequence iff A007588(a(n)) is an element of A001358.
a(n) is in this sequence iff A106482(a(n)) = 2.
a(n) is in this sequence iff a(n) is prime and 2*a(n)^2-1 is also prime.
a(n) = prime(A092058(n)). - R. J. Mathar, Aug 20 2019

Extensions

Extended by Ray Chandler, May 03 2005

A092058 Numbers n such that 2*prime(n)^2 - 1 is prime.

Original entry on oeis.org

1, 2, 4, 5, 6, 7, 13, 14, 17, 21, 29, 30, 31, 33, 37, 41, 42, 45, 46, 47, 54, 56, 59, 62, 64, 71, 73, 75, 80, 81, 84, 93, 103, 105, 106, 113, 114, 120, 126, 131, 132, 134, 139, 141, 144, 145, 146, 148, 159, 160, 169, 175, 179, 183, 185, 186, 188, 192, 212, 217, 220
Offset: 1

Views

Author

mohammed Bouayoun (mohammed.bouayoun(AT)sanef.com), Feb 19 2004

Keywords

Examples

			2*prime(1)^2 - 1 = 7 is prime so a(1)=1;
2*prime(2)^2 - 1 = 17 is prime so a(2)=2;
2*prime(3)^2 - 1 = 97 is not prime;
2*prime(4)^2 - 1 = 241 is prime so a(3)=4.
		

Crossrefs

Cf. A092057.

Programs

  • Magma
    [n: n in [1..220]| IsPrime(2*NthPrime(n)^2-1)]; // Vincenzo Librandi, Jan 18 2013
  • Mathematica
    Select[Range[500],PrimeQ[2Prime[#]^2-1]&] (* Harvey P. Dale, Dec 13 2010 *)
  • PARI
    for (i=1,300,if(isprime(2*prime(i)^2-1),print1(i,",")))
    

Formula

A106483(n) = prime(a(n)) . - R. J. Mathar, Aug 20 2019

A178490 Primes of the form 2*p^k-1, where p is prime and k >= 1.

Original entry on oeis.org

3, 5, 7, 13, 17, 31, 37, 53, 61, 73, 97, 127, 157, 193, 241, 277, 313, 337, 397, 421, 457, 541, 577, 613, 661, 673, 733, 757, 877, 997, 1093, 1153, 1201, 1213, 1237, 1249, 1321, 1381, 1453, 1621, 1657, 1753, 1873, 1933, 1993, 2017, 2137, 2341, 2473, 2557, 2593
Offset: 1

Views

Author

Keywords

Comments

Includes the Mersenne primes > 3 (A000668) and primes of the form 2p^2-1 (A092057) and 2p-1 (A005383) as subsequences; excluding the latter yields A178491.

Examples

			a(1) = 7 = 2*2^2-1 and a(2) = 17 = 2*3^2-1 are also in A092057, and a(3) = 31 = 2*2^4-1 = A000668(3), but a(4) = 53 = 2*3^3-1 is in neither of these subsequences.
		

Crossrefs

Programs

  • Maple
    filter:= n -> isprime(n) and nops(numtheory:-factorset((n+1)/2))=1:
    select(filter, [seq(i,i=3..10000,2)]); # Robert Israel, Feb 20 2024
  • Mathematica
    Select[Prime[Range[20000]],Length[FactorInteger[(#+1)/2]]==1&]
  • PARI
    is_A178490(n) = isprime(n) & omega((n+1)\2)==1

A178491 Primes of the form 2*p^k-1, where p is prime and k > 1.

Original entry on oeis.org

7, 17, 31, 53, 97, 127, 241, 337, 577, 1249, 3361, 3697, 4373, 4801, 6961, 8191, 10657, 13121, 23761, 25537, 31249, 32257, 33613, 37537, 49297, 59581, 64081, 65521, 77617, 79201, 89041, 126001, 131071, 138337, 153457, 159013, 171697, 193441
Offset: 1

Views

Author

Keywords

Comments

Includes the Mersenne primes > 3 (A000668) and primes of the form 2p^2-1 (A092057) as subsequences. Its union with A005383 gives A178490.

Examples

			a(1) = 7 = 2*2^2-1 and a(2) = 17 = 2*3^2-1 are also in A092057, and a(3) = 31 = 2*2^4-1 = A000668(3), but a(4) = 53 = 2*3^3-1 is in neither of these subsequences.
		

Crossrefs

Programs

  • Maple
    N:= 10^6: # for terms <= N
    P:= select(isprime,[2,seq(i,i=3..floor(sqrt((N+1)/2)),2)]):
    R:= NULL:
    for p in P do
      for k from 2 do
        v:= 2*p^k-1;
        if v > N then break fi;
        if isprime(v) then R:= R,v fi;
    od od:
    sort([R]); # Robert Israel, Feb 20 2024
  • Mathematica
    Select[Prime[Range[20000]],!PrimeQ[(#+1)/2]&&Length[FactorInteger[(#+1)/2]]==1&]
  • PARI
    is_A178491(n) = isprime(n) & ispower((n+1)/2,,&n) & isprime(n)

A092059 Primes in A092058.

Original entry on oeis.org

2, 5, 7, 13, 17, 29, 31, 37, 41, 47, 59, 71, 73, 103, 113, 131, 139, 179, 251, 257, 281, 283, 317, 337, 349, 353, 383, 397, 409, 421, 467, 487, 491, 599, 601, 607, 683, 727, 787, 857, 863, 907, 991, 997, 1009, 1021, 1061, 1091, 1097, 1129, 1151, 1193, 1217
Offset: 0

Views

Author

mohammed Bouayoun (mohammed.bouayoun(AT)sanef.com), Feb 19 2004

Keywords

Crossrefs

Programs

  • PARI
    for (i=1,1500,if(isprime(i) && isprime(2*prime(i)^2-1),print1(i,",")))

A152912 Primes p such that 2*p^2-1 is not prime.

Original entry on oeis.org

5, 19, 23, 29, 31, 37, 47, 53, 61, 67, 71, 79, 83, 89, 97, 101, 103, 107, 131, 139, 149, 151, 163, 167, 173, 191, 193, 223, 227, 229, 233, 239, 241, 257, 269, 271, 281, 283, 307, 313, 317, 331, 337, 347, 349, 359, 373, 383, 389, 397, 401, 421, 431, 439, 443
Offset: 1

Views

Author

Vincenzo Librandi, Dec 15 2008

Keywords

Comments

Primes not in A106483. Primes p such that 2p^2-1 is not in A092057. - R. J. Mathar, Dec 19 2008

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(500)|not IsPrime(2*p^2-1)]; // Vincenzo Librandi, Aug 30 2012
  • Maple
    a := proc (n) if isprime(n) = true and isprime(2*n^2-1) = false then n else end if end proc: seq(a(n), n = 1 .. 500); # Emeric Deutsch, Jan 02 2009
  • Mathematica
    Select[Prime[Range[100]], !PrimeQ[2 #^2 - 1] &] (* Vincenzo Librandi, Aug 30 2012 *)

Extensions

Definition clarified by R. J. Mathar, Dec 19 2008
Extended by Emeric Deutsch, Jan 02 2009

A220789 Numbers n such that 2*prime(n)^2 - 1 is not prime.

Original entry on oeis.org

3, 8, 9, 10, 11, 12, 15, 16, 18, 19, 20, 22, 23, 24, 25, 26, 27, 28, 32, 34, 35, 36, 38, 39, 40, 43, 44, 48, 49, 50, 51, 52, 53, 55, 57, 58, 60, 61, 63, 65, 66, 67, 68, 69, 70, 72, 74, 76, 77, 78, 79, 82, 83, 85, 86, 87, 88, 89, 90, 91, 92, 94, 95, 96, 97, 98, 99, 100
Offset: 1

Views

Author

Vincenzo Librandi, Jan 18 2013

Keywords

Crossrefs

Programs

  • Magma
    [n: n in [1..220]| not IsPrime(2*NthPrime(n)^2-1)];
  • Mathematica
    Select[Range[200], !PrimeQ[2Prime[#]^2 - 1]&]

A092060 Primes not in A092058.

Original entry on oeis.org

3, 11, 19, 23, 43, 53, 61, 67, 79, 83, 89, 97, 101, 107, 109, 127, 137, 149, 151, 157, 163, 167, 173, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 263, 269, 271, 277, 293, 307, 311, 313, 331, 347, 359, 367, 373, 379, 389, 401, 419, 431, 433, 439
Offset: 0

Views

Author

mohammed Bouayoun (mohammed.bouayoun(AT)sanef.com), Feb 19 2004

Keywords

Crossrefs

Programs

  • PARI
    for (i=1,1500,if(isprime(i) && !isprime(2*prime(i)^2-1),print1(i,",")))
Showing 1-8 of 8 results.