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.

Previous Showing 11-20 of 20 results.

A119609 p^2-p-1 that is not prime, where p is prime.

Original entry on oeis.org

1, 155, 341, 505, 1331, 1639, 1805, 2755, 3421, 5255, 6161, 6805, 7831, 10505, 11341, 11771, 12655, 18631, 22649, 24491, 26405, 27721, 29755, 31861, 36289, 37055, 39401, 44309, 49505, 51301, 52211, 54055, 56881, 62749, 65791, 68905, 73169
Offset: 1

Views

Author

Alexander Adamchuk, Jul 27 2006

Keywords

Comments

All prime factors of a(n) {5,11,19,29,31,41,59,61,..} belong to A038872 Primes congruent to {0, 1, 4} mod 5. Also odd primes where 5 is a square mod p. A091568 Primes of the form p^2-p-1, where p is prime. A091567 Primes p such that p^2-p-1 is prime.

Crossrefs

Programs

  • Magma
    [q: p in PrimesUpTo(300) | IsPrime(p) and not IsPrime(q) where q is p^2 - p - 1] // Vincenzo Librandi, Sep 08 2012
  • Mathematica
    lst = {}; Do[If[PrimeQ[p] && ! PrimeQ[p^2 - p - 1], AppendTo[lst, p^2 - p -1]], {p, 300}]; lst (* Vincenzo Librandi, Sep 08 2012 *)

A137460 Prime numbers k such that k^2 +- (k+1) are primes.

Original entry on oeis.org

3, 5, 17, 71, 101, 131, 677, 839, 857, 1091, 1217, 2129, 2309, 2339, 2957, 3137, 3449, 3989, 4409, 6569, 6719, 6761, 7229, 8501, 8627, 8807, 9521, 9689, 9749, 10589, 10631, 11621, 11777, 11927, 12641, 13487, 13931, 14519, 15527, 15797, 16007
Offset: 1

Views

Author

Keywords

Examples

			3^2 +- 4 -> (5,13) primes,
5^2 +- 6 -> (19,31) primes.
		

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[800]], PrimeQ[ #^2 - (# + 1)] && PrimeQ[ #^2 + (# + 1)] &]

Formula

A053182 INTERSECT A091567. - R. J. Mathar, Apr 19 2009

Extensions

More terms from Karl Hovekamp, Jan 24 2009

A236173 Primes p such that p^2 - p - 1, p^3 - p - 1 and p^4 - p - 1 are all prime.

Original entry on oeis.org

11, 71, 11621, 28151, 32089, 37501, 39209, 45329, 66161, 76649, 114599, 122131, 136949, 154991, 202999, 228901, 243391, 270269, 296911, 313909, 318679, 333701, 343309, 359291, 369979, 371281, 371981, 373171, 373459
Offset: 1

Views

Author

Derek Orr, Jan 19 2014

Keywords

Comments

Primes in A236171. All primes appear to end in a 1 or a 9 (congruent to either 1 mod 10 or 9 mod 10).

Examples

			228901 is prime, 228901^2 - 228901 - 1 is prime, 228901^3 - 228901 - 1 is prime, and 228901^4 - 228901 - 1 is prime. So 228901 is a member of this sequence.
		

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[32000]],AllTrue[#^{2,3,4}-#-1,PrimeQ]&] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Apr 08 2019 *)
  • PARI
    s=[]; forprime(p=2, 400000, if(isprime(p^2-p-1) && isprime(p^3-p-1) && isprime(p^4-p-1), s=concat(s, p))); s \\ Colin Barker, Jan 20 2014
  • Python
    import sympy
    from sympy import isprime
    {print(p) for p in range(10**6) if isprime(p) and isprime(p**2-p-1) and isprime(p**3-p-1) and isprime(p**4-p-1)}
    

A238447 Primes p such that f(p) and f(f(p)) are both prime, where f(x) = x^2-x-1.

Original entry on oeis.org

3, 487, 617, 677, 751, 1201, 1289, 1579, 1747, 2027, 2267, 2269, 2309, 3259, 3947, 4457, 4567, 4621, 4637, 4799, 4951, 5701, 6029, 6991, 7151, 7687, 7867, 9187, 9209, 9341, 9587, 9829, 11321, 12301, 12541, 12781, 13177, 13649, 15919, 16349
Offset: 1

Views

Author

Derek Orr, Feb 26 2014

Keywords

Comments

Intersection of A230026 and A091567.
Note that f(f(f(p))) is always composite. - Zak Seidov, Nov 10 2014

Examples

			3 is prime, 3^2-3-1 = 5 is prime, and (3^2-3-1)^2-(3^2-3-1)-1 = 19 is prime. Thus, 3 is a member of this sequence.
		

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[2000]],AllTrue[Rest[NestList[#^2-#-1&,#,2]],PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Oct 03 2017 *)
  • Python
    import sympy
    from sympy import isprime
    def f(x):
      return x**2-x-1
    {print(p) for p in range(10**5) if isprime(p) and isprime(f(p)) and isprime(f(f(p)))}

A243544 Primes p such that p^2 - p + 1 is semiprime.

Original entry on oeis.org

5, 11, 29, 37, 41, 43, 53, 61, 71, 73, 83, 97, 109, 113, 127, 137, 149, 157, 167, 181, 191, 211, 223, 229, 241, 271, 277, 281, 307, 317, 331, 359, 389, 421, 433, 443, 461, 463, 487, 499, 547, 557, 571, 587, 601, 617, 631, 659, 661, 683, 691, 701, 709, 733, 757
Offset: 1

Views

Author

K. D. Bajpai, Jun 06 2014

Keywords

Comments

Intersection of A000040 and A180748.

Examples

			11 is in the sequence because 11 is prime and 11^2 - 11 + 1 = 111 = 3 * 37 is semiprime.
29 is in the sequence because 29 is prime and 29^2 - 29 + 1 = 813 = 3 * 271 is semiprime.
17 is not in the sequence though 17 is prime, because 17^2 - 17 + 1 = 273 = 3 * 7 * 13, has more than two prime factors.
		

Crossrefs

Programs

  • Maple
    with(numtheory): A243544 := proc() local a; a:=ithprime(n);  if bigomega(a^2-a+1)=2 then RETURN (a); fi; end: seq(A243544 (), n=1..200);
  • Mathematica
    c = 0; Do[k = Prime[n]; If[PrimeOmega[k^2 - k + 1] == 2, c++; Print[c, " ", k]], {n, 1, 30000}];
    Select[Prime[Range[150]],PrimeOmega[#^2-#+1]==2&] (* Harvey P. Dale, Oct 22 2024 *)
  • PARI
    s=[]; forprime(p=2, 800, if(bigomega(p^2-p+1)==2, s=concat(s, p))); s \\ Colin Barker, Jun 06 2014

A290767 Primes p such that p^2 +/- p +/- 1 are all nonprimes.

Original entry on oeis.org

23, 37, 43, 73, 107, 109, 113, 137, 157, 179, 211, 223, 227, 229, 239, 251, 257, 271, 277, 283, 311, 313, 317, 347, 353, 367, 389, 439, 443, 467, 503, 509, 521, 523, 547, 557, 563, 577, 587, 593, 601, 631, 653, 661, 719, 733, 757, 797, 811, 821, 823, 829, 853, 859, 877, 883
Offset: 1

Views

Author

Ralf Steiner, Aug 10 2017

Keywords

Crossrefs

Programs

  • Maple
    select(p -> isprime(p) and not ormap(isprime, [p^2+p+1,p^2+p-1,p^2-p+1,p^2-p-1]), [2,seq(i,i=3..1000,2)]); # Robert Israel, Aug 10 2017
  • Mathematica
    Select[Prime[Range[1000]], ! (PrimeQ[#^2 + # + 1] || PrimeQ[#^2 + # - 1] ||PrimeQ[#^2 - # + 1] || PrimeQ[#^2 - # - 1]) &]
    Select[Prime[Range[200]],NoneTrue[{#^2+#+1,#^2+#-1,#^2-#+1,#^2-#-1},PrimeQ]&] (* Harvey P. Dale, Oct 13 2024 *)
  • PARI
    is(n) = my(v=[n^2+n+1, n^2+n-1, n^2-n+1, n^2-n-1]); for(k=1, #v, if(ispseudoprime(v[k]), return(0))); 1
    forprime(p=1, 900, if(is(p), print1(p, ", "))) \\ Felix Fröhlich, Aug 10 2017

Formula

Intersection of the complements of A053184, A053182, A065508, and A091567 within the primes A000040.

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

Original entry on oeis.org

2, 13, 19, 23, 37, 41, 43, 53, 59, 73, 79, 83, 89, 103, 107, 109, 113, 137, 151, 157, 163, 167, 173, 179, 191, 193, 199, 211, 223, 227, 229, 233, 239, 251, 257, 263, 271, 277, 281, 283, 293, 311, 313, 317, 337, 347, 349, 353, 367, 373, 383, 389, 401, 431, 433
Offset: 1

Views

Author

Alexander Adamchuk, Jul 27 2006

Keywords

Crossrefs

Cf. A091567 (Primes p such that p^2-p-1 is prime),
A091568 (Primes of the form p^2-p-1, where p is prime).

Programs

  • Magma
    [p: p in PrimesUpTo(700)| not IsPrime(p^2-p-1)] // Vincenzo Librandi, Jan 29 2011
  • Mathematica
    Select[Prime[Range[250]], Not[PrimeQ[ #^2-#-1]]&]

A119964 Numerator of the n-th Artin product.

Original entry on oeis.org

1, 5, 19, 779, 84911, 2632241, 713337311, 1163866139, 587752400195, 476667196558145, 2856927907113011, 345688276760674331, 13819099649042566549, 4988694973304366524189, 10780569837310736058772429
Offset: 1

Views

Author

Alexander Adamchuk, Aug 03 2006

Keywords

Comments

Artin's constant (A005596) is equal to Product[1-1/(Prime[k]*(Prime[k]-1)),{k,1,Infinity}]. n-th Artin product is Product[1-1/(Prime[k]*(Prime[k]-1)),{k,1,n}].

Crossrefs

Programs

  • Mathematica
    Table[Numerator[Product[1-1/(Prime[k]*(Prime[k]-1)),{k,1,n}]],{n,1,20}]

Formula

a(n) = Numerator[ Product[ 1 - 1/(Prime[k]*(Prime[k]-1)), {k,1,n}]].

A119978 Denominator of the n-th Artin product.

Original entry on oeis.org

2, 12, 48, 2016, 221760, 6918912, 1881944064, 3079544832, 1558249684992, 1265298744213504, 7591792465281024, 919297051250393088, 36771882050015723520, 13282003796465679335424
Offset: 1

Views

Author

Alexander Adamchuk, Aug 03 2006

Keywords

Comments

Artin's constant (A005596) is equal to Product[1-1/(Prime[k]*(Prime[k]-1)),{k,1,Infinity}]. n-th Artin product is Product[1-1/(Prime[k]*(Prime[k]-1)),{k,1,n}].

Crossrefs

Programs

  • Mathematica
    Table[Denominator[Product[1-1/(Prime[k]*(Prime[k]-1)),{k,1,n}]],{n,1,20}]

Formula

a(n) = Denominator[ Product[ 1 - 1/(Prime[k]*(Prime[k]-1)), {k,1,n}]].

A268212 Numbers n of the form 2^k + 1 such that n^2 - n - 1 is a prime q (for k >= 0).

Original entry on oeis.org

3, 5, 9, 17, 65, 1025, 65537, 16777217, 67108865, 34359738369, 4503599627370497, 36028797018963969, 39614081257132168796771975169, 22300745198530623141535718272648361505980417
Offset: 1

Views

Author

Jaroslav Krizek, Jan 28 2016

Keywords

Comments

Conjecture: subsequence of prime terms (3, 5, 17, 65537, ...) is not the same as A249759.
Corresponding values of numbers k are in A098855 (numbers n such that 4^n + 2^n - 1 is prime).
Corresponding values of primes q: 5, 19, 71, 271, 4159, 1049599, 4295032831, ...
4 out of 5 known Fermat primes (3, 5, 17, 65537) are terms; corresponding values of primes q: 5, 19, 271, 4295032831.

Examples

			17  = 2^4 + 1 is a term because 17^2 - 17 - 1 = 271 (prime).
		

Crossrefs

Intersection of A002328 and A000051.

Programs

  • Magma
    [2^n + 1: n in [0..300] | IsPrime((2^n + 1)^2 - 2^n - 2)]
    
  • Mathematica
    2^# + 1 &@ Select[Range[0, 300], PrimeQ[#^2 - # - 1 &@ (2^# + 1)] &] (* Michael De Vlieger, Jan 29 2016 *)
  • PARI
    lista(nn) = {for (k=0, nn, n = 2^k+1; if (isprime(n^2-n-1), print1(n, ", ")););} \\ Michel Marcus, Mar 06 2016
Previous Showing 11-20 of 20 results.