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 24 results. Next

A165218 Primes q of the form q=p^2+4 (p=prime) such that r=q^2+4 is also prime.

Original entry on oeis.org

13, 293, 10613, 18773, 76733, 97973, 458333, 552053, 1247693, 2647133, 4012013, 4592453, 11607653, 13520333, 20097293, 25877573, 34845413, 51509333, 53772893, 65399573, 65496653, 66373613, 72880373, 73496333, 86359853, 89737733
Offset: 1

Views

Author

Zak Seidov, Sep 08 2009

Keywords

Comments

Intersection of A062324 and A045637. Except of the first term, 13, all terms == 5 (mod 6) == 5 (mod 12) == 5 (mod 24) == 23 (mod 30)== 53 (mod 120). Values of primes p in A116886.

Examples

			Prime q=13=p^2+4 (p=3) and r=q^2+4=13^2+4=173 (prime).
Prime q=293=p^2+4 (p=17) and r=q^2+4=293^2+4=85853 (prime).
		

Crossrefs

Programs

  • Mathematica
    Reap[For[p = 2, p < 10^4, p = NextPrime[p], If[PrimeQ[q = p^2+4] && PrimeQ[q^2+4], Print[q]; Sow[q]]]][[2, 1]] (* Jean-François Alcover, Nov 07 2013 *)
    Select[Prime[Range[2000]]^2+4,AllTrue[{#,#^2+4},PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Mar 13 2018 *)

Formula

a(n) = (A116886(n))^2 + 4.

A116888 Primes p that remain prime through 4 iterations of the function f(p) = p^2 + 4.

Original entry on oeis.org

306167, 48639197, 64695713, 68252687, 87788237, 87813293, 160486967, 255974437, 283032247, 324609913, 361705873, 417684523, 449364197, 451995587, 454052213, 466037563, 536504713, 574746467, 596095613
Offset: 1

Views

Author

Giovanni Resta, Feb 27 2006

Keywords

Examples

			p = 306167, f(p) = 93738231893, f(f(p)) = 8786856118425842363453, f(f(f(p))) = 77208840445917661077402487029419236950083213 and the 88-digit number f(f(f(f(p)))) are all prime numbers.
		

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[9! ]],PrimeQ[ #^2+4]&&PrimeQ[(#^2+4)^2+4]&&PrimeQ[((#^2+4)^2+4)^2+4]&&PrimeQ[(((#^2+4)^2+4)^2+4)^2+4]&] (* Vladimir Joseph Stephan Orlovsky, Feb 26 2010 *)
    p4Q[p_]:=AllTrue[NestList[#^2+4&,p,4],PrimeQ]; Select[Prime[Range[312*10^5]],p4Q] (* Harvey P. Dale, Nov 20 2023 *)

A118941 Primes p such that (p^2-5)/4 is prime.

Original entry on oeis.org

5, 7, 11, 13, 17, 19, 23, 31, 41, 43, 53, 61, 71, 79, 83, 89, 97, 101, 107, 109, 113, 131, 137, 167, 173, 179, 193, 229, 241, 251, 263, 269, 277, 281, 283, 307, 311, 317, 349, 353, 373, 383, 419, 431, 439, 461, 463, 467, 563, 571, 577, 593, 607, 613, 619, 647
Offset: 1

Views

Author

T. D. Noe, May 06 2006

Keywords

Comments

For all primes q>2, we have q=4k+-1 for some k, which makes it easy to show that 4 divides q^2-5. Similar sequences, with p and (p^2+a)/b both prime, are A048161, A062324, A062326, A062718, A109953, A110589, A118915, A118918, A118939, A118940 and A118942.

Programs

  • Mathematica
    Select[Prime[Range[200]],PrimeQ[(#^2-5)/4]&]

A118942 Primes p such that (p^2-13)/12 is prime.

Original entry on oeis.org

7, 13, 17, 19, 23, 31, 37, 41, 53, 67, 71, 73, 89, 103, 107, 113, 131, 139, 157, 163, 181, 199, 211, 233, 239, 257, 269, 283, 307, 311, 337, 359, 373, 379, 401, 419, 463, 487, 491, 499, 509, 521, 577, 593, 607, 617, 631, 647, 653, 683, 701, 733, 761, 769, 787
Offset: 1

Views

Author

T. D. Noe, May 06 2006

Keywords

Comments

For all primes q>3, we have q=6k+-1 for some k, which makes it easy to show that 12 divides q^2-13. Similar sequences, with p and (p^2+a)/b both prime, are A048161, A062324, A062326, A062718, A109953, A110589, A118915, A118918, A118939, A118940 and A118941.

Programs

  • Mathematica
    Select[Prime[Range[200]],PrimeQ[(#^2-13)/12]&]

A132260 Array T(k,n) = n-th prime p such that 2^2^k + p^2^k is prime, k>2, read by antidiagonals.

Original entry on oeis.org

13, 89, 137, 29, 107, 223, 37, 59, 127, 331, 113, 53, 101, 139, 389, 113, 223, 181, 103, 173, 491, 13, 1223, 5279, 491, 109, 179, 563, 1151, 181, 1277, 7517, 547, 181, 229, 647, 43, 2153, 761, 1993, 8039, 619, 199, 233, 701, 53, 271, 3559, 4133, 2399, 9833, 661, 379, 349, 773
Offset: 3

Views

Author

Jonathan Vos Post, Aug 15 2007

Keywords

Comments

These were computed by Ignacio Larrosa Cañestro, who cautions that some are only probable primes. The k=3 row is A157950. The main diagonal is A132261.

Examples

			The array begins:
   n  |   1    2    3    4    5    6     7     8     9    10
  ----+--------------------------------------------------------
  k=3 |  13  137  223  331  389  491   563   647   701   773
  k=4 |  89  107  127  139  173  179   229   233   349   421
  k=5 |  29   59  101  103  109  181   199   379   769   881
  k=6 |  37   53  181  491  547  619   661   677   911   941
  k=7 | 113  223 5279 7517 8039 9833 12197 13757 21467 23447
  k=8 | 113 1223 1277 1993 2399 9349  9739 10211 10973 11059
		

Crossrefs

Extensions

More terms from Jinyuan Wang, Feb 01 2022

A157950 Primes p such that p^8 + 2^8 is prime.

Original entry on oeis.org

13, 137, 223, 331, 389, 491, 563, 647, 701, 773, 797, 1063, 1181, 1531, 1579, 1811, 2027, 2087, 2269, 2333, 2393, 2617, 2687, 2699, 2857, 3313, 3467, 3623, 3637, 3691, 3739, 3761, 3863, 3877, 4133, 4201, 4283, 4297, 4877, 5023, 5839, 5897, 6043, 6053
Offset: 1

Views

Author

Ulrich Krug (leuchtfeuer37(AT)gmx.de), Mar 10 2009

Keywords

Comments

17 divides p^8 + 2^8 if k is odd and p = 17k +- 6, 17k +- 10, 17k +- 12, 17k +- 14, so only 8 integers p in each interval of length 34 need to be tested for the primality of p and of p^8 + 2^8: those of the forms p = 17k +- 2 (which yield terms 223, 389, 491, 563, 797, 1579, 3313, 3623, 3691, ...), p = 17k +- 4 (which yield terms 13, 701, 2027, 2087, 2333, 2393, 2699, ...), p = 17k +-8 (which yield terms 331, 773, 1063, 1181, 1811, 2269, ...), and p = 17k +-16 (which yield terms 137, 647, 1531, 2617, 2687, 2857, 3467, 3637, ...).
It is conjectured that this sequence is infinite.

Examples

			n=11: 11^8 + 2^8 = 214359137 = 17 * 241 * 52321, not prime, so 11 is not a term;
n=13: 13^8 + 2^8 = 815730977 is prime, so 13 is a term.
		

References

  • Leonard E. Dickson, History of the Theory of Numbers.
  • Richard Guy, Unsolved Problems in Number Theory.

Crossrefs

Programs

  • Maple
    a := proc (n) if isprime(ithprime(n)^8+256) = true then ithprime(n) else end if end proc: seq(a(n), n = 1 .. 900); # Emeric Deutsch, Mar 14 2009

Extensions

Definition corrected by Emeric Deutsch, Mar 14 2009
Extended by Emeric Deutsch, Mar 14 2009
Edited by Jon E. Schoenfield, Jan 29 2019

A263721 The prime p in the Fouvry-Iwaniec prime k^2 + p^2 (A185086), or the larger of k and p if both are prime.

Original entry on oeis.org

2, 3, 5, 5, 7, 5, 3, 5, 3, 7, 11, 7, 11, 13, 7, 2, 13, 13, 5, 17, 13, 11, 5, 17, 7, 17, 19, 3, 17, 7, 19, 5, 11, 19, 13, 23, 5, 17, 19, 13, 23, 5, 2, 19, 17, 11, 5, 23, 29, 29, 23, 19, 29, 13, 31, 31, 23, 11, 3, 5, 31, 13, 2, 29, 5, 13, 31, 2, 11, 5, 31, 37, 23, 37, 3, 7, 23, 3, 13, 31, 19, 37, 41, 11
Offset: 1

Views

Author

Keywords

Comments

The sequence is well-defined by the uniqueness part of Fermat's two-squares theorem.
The sequence is infinite, since Fouvry and Iwaniec proved that A185086 is infinite.

Examples

			A185086(2) = 13 = 2^2 + 3^2 and A185086(6) = 61 = 5^2 + 6^2, so a(2) = 3 and a(6) = 5.
		

Crossrefs

Programs

  • Mathematica
    p = 2; lst = {}; While[p < 100, k = 1; While[k < 101, If[PrimeQ[k^2 + p^2], AppendTo[lst, {k^2 + p^2, If[PrimeQ@ k, Max[k, p], p]}]]; k++]; p = NextPrime@ p]; Transpose[Union@ lst][[2]]
  • PARI
    do(lim)=my(v=List(),p2,t); forprime(p=2, sqrtint(lim\=1), p2=p^2; for(k=1, sqrtint(lim-p2), if(isprime(t=p2+k^2), listput(v, [t, if(isprime(k),max(k,p),p)])))); v=vecsort(Set(v),1); apply(u->u[2], v) \\ Charles R Greathouse IV, Aug 21 2017

Formula

a(n)^2 = A185086(n) - k^2 for some integer k > 0.

A158477 Primes p with property that Q(p) = p^32+2^32 is prime.

Original entry on oeis.org

29, 59, 101, 103, 109, 181, 199, 379, 769, 881, 919, 977, 1097, 1213, 1303, 1583, 2099, 2113, 2441, 2521, 2617, 2777, 3067, 3739, 4133, 4289, 4519, 4931, 5039, 5113, 5227, 5417, 5743, 5783, 6143, 6373, 6691, 8053, 8209, 8287, 8513, 9109, 9203, 9689, 9787, 9923, 9941
Offset: 1

Views

Author

Ulrich Krug (leuchtfeuer37(AT)gmx.de), Mar 20 2009

Keywords

Comments

1) Q=(p^16)^2+(2^16)^2 only for Q=4k+1 because of Fermat/Euler/Lagrange theorem concerning prime as sum of two squares.
2) It is conjectured that sequence a(n) is infinite.
3) Note the twin prime: a(3)=101, a(4)=103.
The next set of twins is a(101)=30557, a(102)=30559. - Robert Israel, Apr 05 2016

Examples

			p=3: 3^32+2^32=1853024483819137 = 1153 x 1607133116929 no prime;
also for following primes p=5, 7, 11, 13, 17, 19, 23: Q(p) no prime;
p=29: 29^32+2^32=62623297589448778360828428329074752313100292737 is prime => a(1)=29.
		

References

  • Richard E. Crandall, Carl Pomerance, Prime Numbers: A Computational Perspective, Springer 2001.
  • Leonard E. Dickson, History of the Theory of Numbers, Dover Pub. Inc., 2005.

Crossrefs

Programs

  • Maple
    select(t -> isprime(t) and isprime(t^32 + 2^32), [seq(i,i=3..10000,2)]); # Robert Israel, Apr 05 2016
  • Mathematica
    With[{c=2^32},Select[Prime[Range[1300]],PrimeQ[#^32+c]&]] (* Harvey P. Dale, May 04 2018 *)
  • PARI
    isA158477(n) = isprime(n) && isprime(n^32+4294967296) \\ Michael B. Porter, Dec 17 2009
    
  • PARI
    lista(nn) = forprime(p=3, nn, if(ispseudoprime(p^32+2^32), print1(p, ", "))); \\ Altug Alkan, Apr 05 2016

Formula

n^32+2^32 and n to be prime.

A357426 Primes p such that p^2+4 is a prime times 5^k for some k >= 1.

Original entry on oeis.org

11, 19, 31, 41, 61, 71, 79, 89, 109, 131, 139, 149, 151, 181, 191, 239, 241, 251, 379, 389, 409, 421, 461, 499, 509, 541, 599, 631, 659, 661, 709, 719, 769, 811, 919, 1009, 1019, 1021, 1031, 1109, 1129, 1151, 1201, 1231, 1291, 1361, 1399, 1409, 1451, 1489, 1549, 1601, 1621, 1721, 1789, 1871, 1889, 1931, 2011, 2039, 2069, 2131, 2179, 2221, 2251, 2309, 2341, 2351
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Sep 27 2022

Keywords

Comments

All terms == 1 or 9 (mod 10).

Examples

			a(4) = 41 is a term because 41 is prime and 41^2+4 = 1685 = 337 * 5^1 where 337 is prime.
		

Crossrefs

Disjoint from A062324.

Programs

  • Maple
    filter:= proc(p) local v;
      if not isprime(p) then return false fi;
      v:= p^2+4;
      isprime(v/5^padic:-ordp(v,5))
    end proc:
    filter(11):= true:
    select(filter, [seq(seq(10*i+j, j= [1,9]),i=1..1000)]);
  • Mathematica
    q[p_] := (e = IntegerExponent[m = p^2 + 4, 5]) > 0 && (m==5^e || PrimeQ[m/5^e]); Select[Prime[Range[350]], q] (* Amiram Eldar, Sep 28 2022 *)

A153645 Primes p such that p^2 + 4 and p^2 + 4p + 2 are also prime.

Original entry on oeis.org

3, 5, 7, 13, 17, 47, 67, 73, 137, 167, 277, 307, 313, 487, 503, 593, 607, 613, 787, 823, 1117, 1123, 1237, 1523, 1543, 1637, 1987, 2777, 2887, 3037, 3163, 3433, 3457, 3463, 3797, 3853, 4093, 4283, 4583, 5113, 5297, 5323, 5683, 5953, 6047, 6577, 6803, 6823
Offset: 1

Views

Author

Vincenzo Librandi, Dec 30 2008

Keywords

Comments

Subsequence of A062324.

Examples

			For prime p = 3, p^2+4 = 13 and p^2+4p+2 = 23 are prime; for p = 67, p^2+4 = 4493 and p^2+4p+2 = 4759 are prime.
		

Crossrefs

Cf. A062324 (p and p^2+4 are both prime).

Programs

  • Magma
    [ p: p in PrimesUpTo(7000) | IsPrime(p^2+4) and IsPrime(p^2+4*p+2) ];
  • Maple
    a := proc (n) if isprime(n) = true and isprime(n^2+4) = true and isprime(n^2+4*n+2) = true then n else end if end proc: seq(a(n), n = 1 .. 7000); # Emeric Deutsch, Jan 02 2009
  • Mathematica
    Select[Prime[Range[10000]],PrimeQ[#^2+4]&&PrimeQ[#^2 +4#+2]&] (* Vincenzo Librandi, Jul 27 2012 *)

Extensions

Edited, corrected (three terms deleted) and extended beyond a(10) by Klaus Brockhaus, Jan 02 2009
Corrected and extended by Emeric Deutsch, Jan 02 2009
Previous Showing 11-20 of 24 results. Next