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-10 of 21 results. Next

A005574 Numbers k such that k^2 + 1 is prime.

Original entry on oeis.org

1, 2, 4, 6, 10, 14, 16, 20, 24, 26, 36, 40, 54, 56, 66, 74, 84, 90, 94, 110, 116, 120, 124, 126, 130, 134, 146, 150, 156, 160, 170, 176, 180, 184, 204, 206, 210, 224, 230, 236, 240, 250, 256, 260, 264, 270, 280, 284, 300, 306, 314, 326, 340, 350, 384, 386, 396
Offset: 1

Views

Author

Keywords

Comments

Hardy and Littlewood conjectured that the asymptotic number of elements in this sequence not exceeding n is approximately c*sqrt(n)/log(n) for some constant c. - Stefan Steinerberger, Apr 06 2006
Also, nonnegative integers such that a(n)+i is a Gaussian prime. - Maciej Ireneusz Wilczynski, May 30 2011
Apparently Goldbach conjectured that any a > 1 from this sequence can be written as a=b+c where b and c are in this sequence (Lemmermeyer link below). - Jeppe Stig Nielsen, Oct 14 2015
No term > 2 can be both in this sequence and in A001105 because of the Aurifeuillean factorization (2*k^2)^2 + 1 = (2*k^2 - 2*k + 1) * (2*k^2 + 2*k + 1). - Jeppe Stig Nielsen, Aug 04 2019

References

  • Harvey Dubner, "Generalized Fermat primes", J. Recreational Math., 18 (1985): 279-280.
  • R. K. Guy, "Unsolved Problems in Number Theory", 3rd edition, A2.
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers, 5th ed., Oxford Univ. Press, 1979, p. 15, Thm. 17.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Other sequences of the type "Numbers k such that k^2 + i is prime": this sequence (i=1), A067201 (i=2), A049422 (i=3), A007591 (i=4), A078402 (i=5), A114269 (i=6), A114270 (i=7), A114271 (i=8), A114272 (i=9), A114273 (i=10), A114274 (i=11), A114275 (i=12).
Cf. A010051, A259645, A295405 (characteristic function).

Programs

  • Haskell
    a005574 n = a005574_list !! (n-1)
    a005574_list = filter ((== 1) . a010051' . (+ 1) . (^ 2)) [0..]
    -- Reinhard Zumkeller, Jul 03 2015
    
  • Magma
    [n: n in [0..400] | IsPrime(n^2+1)]; // Vincenzo Librandi, Nov 18 2010
    
  • Mathematica
    Select[Range[350], PrimeQ[ #^2 + 1] &] (* Stefan Steinerberger, Apr 06 2006 *)
    Join[{1},2Flatten[Position[PrimeQ[Table[x^2+1,{x,2,1000,2}]],True]]]  (* Fred Patrick Doty, Aug 18 2017 *)
  • PARI
    isA005574(n) = isprime(n^2+1) \\ Michael B. Porter, Mar 20 2010
    
  • PARI
    for(n=1, 1e3, if(isprime(n^2 + 1), print1(n, ", "))) \\ Altug Alkan, Oct 14 2015
    
  • Python
    from sympy import isprime; [print(n, end = ', ') for n in range(1, 400) if isprime(n*n+1)] # Ya-Ping Lu, Apr 23 2025

Formula

a(n) = A090693(n) - 1.
a(n) = 2*A001912(n-1) for n > 1. - Jeppe Stig Nielsen, Aug 04 2019

A000068 Numbers k such that k^4 + 1 is prime.

Original entry on oeis.org

1, 2, 4, 6, 16, 20, 24, 28, 34, 46, 48, 54, 56, 74, 80, 82, 88, 90, 106, 118, 132, 140, 142, 154, 160, 164, 174, 180, 194, 198, 204, 210, 220, 228, 238, 242, 248, 254, 266, 272, 276, 278, 288, 296, 312, 320, 328, 334, 340, 352, 364, 374, 414, 430, 436, 442, 466
Offset: 1

Views

Author

Keywords

References

  • Harvey Dubner, Generalized Fermat primes, J. Recreational Math., 18 (1985): 279-280.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Magma
    [n: n in [0..800] | IsPrime(n^4+1)]; // Vincenzo Librandi, Nov 18 2010
  • Mathematica
    Select[Range[10^2*2], PrimeQ[ #^4+1] &] (* Vladimir Joseph Stephan Orlovsky, May 01 2008 *)
  • PARI
    {a(n) = local(m); if( n<1, 0, for(k=1, n, until( isprime(m^4 + 1), m++)); m)};
    
  • PARI
    list(lim)=my(v=List([1])); forstep(k=2,lim,2, if(isprime(k^4+1), listput(v,k))); Vec(v) \\ Charles R Greathouse IV, Mar 31 2022
    

Formula

1+a(n)^4 = A037896(n).

A006313 Numbers k such that k^16 + 1 is prime.

Original entry on oeis.org

1, 2, 44, 74, 76, 94, 156, 158, 176, 188, 198, 248, 288, 306, 318, 330, 348, 370, 382, 396, 452, 456, 470, 474, 476, 478, 560, 568, 598, 642, 686, 688, 690, 736, 774, 776, 778, 790, 830, 832, 834, 846, 900, 916, 946, 956, 972, 982, 984, 1018, 1044, 1078
Offset: 1

Views

Author

Keywords

References

  • Dubner, Harvey. "Generalized Fermat primes." J. Recreational Math., 18 (1985): 279-280.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

Extensions

More terms from Hugo Pfoertner, Jun 22 2003

A006314 Numbers k such that k^8 + 1 is prime.

Original entry on oeis.org

1, 2, 4, 118, 132, 140, 152, 208, 240, 242, 288, 290, 306, 378, 392, 426, 434, 442, 508, 510, 540, 542, 562, 596, 610, 664, 680, 682, 732, 782, 800, 808, 866, 876, 884, 892, 916, 918, 934, 956, 990, 1022, 1028, 1054, 1106, 1120, 1174, 1224, 1232, 1256, 1284
Offset: 1

Views

Author

Keywords

References

  • Dubner, Harvey. "Generalized Fermat primes." J. Recreational Math., 18 (1985): 279-280.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

Formula

A258805(n) = a(n)^8+1. - R. J. Mathar, Jun 05 2025

Extensions

More terms from James Sellers, May 03 2000

A056994 Numbers k such that k^128 + 1 is prime.

Original entry on oeis.org

1, 120, 190, 234, 506, 532, 548, 960, 1738, 1786, 2884, 3000, 3420, 3476, 3658, 4258, 5788, 6080, 6562, 6750, 7692, 8296, 9108, 9356, 9582, 9706, 10238, 10994, 11338, 11432, 11466, 11554, 11778, 12704, 12766, 13082, 13478, 13700
Offset: 1

Views

Author

Robert G. Wilson v, Sep 06 2000

Keywords

References

  • Dubner, Harvey. "Generalized Fermat primes." J. Recreational Math., 18 (1985): 279-280.

Crossrefs

Programs

  • Mathematica
    Do[ k = 1; While[ PowerMod[ n, 128, 2*k*128 + 1 ] != 2*k*128 && k < 10^3, k++ ]; If[ k == 10^3 && PrimeQ[ n^128 + 1 ], Print[ n ] ], {n, 2, 15000, 2} ]
  • PARI
    isA056994(n) = isprime(n^128+1) \\ Michael B. Porter, Mar 30 2010

A006315 Numbers n such that n^32 + 1 is prime.

Original entry on oeis.org

1, 30, 54, 96, 112, 114, 132, 156, 332, 342, 360, 376, 428, 430, 432, 448, 562, 588, 726, 738, 804, 850, 884, 1068, 1142, 1198, 1306, 1540, 1568, 1596, 1678, 1714, 1754, 1812, 1818, 1878, 1906, 1960, 1962, 2046, 2098, 2118, 2142, 2330, 2418, 2434, 2654, 2668
Offset: 1

Views

Author

Keywords

References

  • Dubner, Harvey. "Generalized Fermat primes." J. Recreational Math., 18 (1985): 279-280.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

Extensions

More terms from Hugo Pfoertner, Jun 22 2003

A056993 a(n) is the smallest k >= 2 such that k^(2^n)+1 is prime, or -1 if no such k exists.

Original entry on oeis.org

2, 2, 2, 2, 2, 30, 102, 120, 278, 46, 824, 150, 1534, 30406, 67234, 70906, 48594, 62722, 24518, 75898, 919444
Offset: 0

Views

Author

Robert G. Wilson v, Sep 06 2000

Keywords

Comments

Smallest base value yielding generalized Fermat primes. - Hugo Pfoertner, Jul 01 2003
The first 5 terms correspond with the known (ordinary) Fermat primes. A probable candidate for the next entry is 62722^131072+1, discovered by Michael Angel in 2003. It has 628808 decimal digits. - Hugo Pfoertner, Jul 01 2003
For any n, a(n+1) >= sqrt(a(n)), because k^(2^(n+1))+1 = (k^2)^(2^n)+1. - Jeppe Stig Nielsen, Sep 16 2015
Does the sequence contain any perfect squares? If a(n) is a perfect square, then a(n+1) = sqrt(a(n)). - Jeppe Stig Nielsen, Sep 16 2015
If for a particular n, a(n) exists, then a(i) exist for all i=0,1,2,...,n. No proof is known that this sequence is infinite. Such a result would clearly imply the infinitude of A002496. - Jeppe Stig Nielsen, Sep 18 2015
919444 is a candidate for a(20). See Zimmermann link. - Serge Batalov, Sep 02 2017
Now PrimeGrid has tested and double checked all b^(2^20) + 1 with b < 919444, so we have proof that a(20) = 919444. - Jeppe Stig Nielsen, Dec 30 2017

Examples

			The primes are 2^(2^0) + 1 = 3, 2^(2^1) + 1 = 5, 2^(2^2) + 1 = 17, 2^(2^3) + 1 = 257, 2^(2^4) + 1 = 65537, 30^(2^5) + 1, 102^(2^6) + 1, ....
		

Crossrefs

Programs

  • Mathematica
    f[n_] := (p = 2^n; k = 2; While[cp = k^p + 1; !PrimeQ@cp, k++ ]; k); Do[ Print[{n, f@n}], {n, 0, 17}] (* Lei Zhou, Feb 21 2005 *)
  • PARI
    a(n)=my(k=2);while(!isprime(k^(2^n)+1),k++);k \\ Anders Hellström, Sep 16 2015

Formula

a(n) = A085398(2^(n+1)). - Jianing Song, Jun 13 2022

Extensions

1534 from Robert G. Wilson v, Oct 30 2000
62722 from Jeppe Stig Nielsen, Aug 07 2005
24518 and 75898 from Lei Zhou, Feb 01 2012
919444 from Jeppe Stig Nielsen, Dec 30 2017

A006316 Numbers k such that k^64 + 1 is prime.

Original entry on oeis.org

1, 102, 162, 274, 300, 412, 562, 592, 728, 1084, 1094, 1108, 1120, 1200, 1558, 1566, 1630, 1804, 1876, 2094, 2162, 2164, 2238, 2336, 2388, 2420, 2494, 2524, 2614, 2784, 3024, 3104, 3140, 3164, 3254, 3278, 3628, 3694, 3738, 3750, 4000, 4030, 4058, 4166
Offset: 1

Views

Author

Keywords

References

  • Harvey Dubner, Generalized Fermat primes, J. Recreational Math., 18 (1985): 279-280.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

Extensions

More terms from Hugo Pfoertner, Jun 22 2003

A057002 Numbers n such that n^1024 + 1 is prime (a generalized Fermat prime).

Original entry on oeis.org

1, 824, 1476, 1632, 2462, 2484, 2520, 3064, 3402, 3820, 4026, 6640, 7026, 7158, 9070, 12202, 12548, 12994, 13042, 15358, 17646, 17670, 18336, 19564, 20624, 22500, 24126, 26132, 26188, 26240, 29074, 29658, 30778, 31126, 32244, 33044, 34016
Offset: 1

Views

Author

Robert G. Wilson v, Sep 09 2000

Keywords

Comments

This sequence is infinite under Bunyakovsky's conjecture. - Charles R Greathouse IV, Apr 26 2012

Crossrefs

Other sequences of numbers n such that n^(2^k)+1 is prime for fixed k: A005574, A000068, A006314, A006313, A006315, A006316, A056994, A056995, A057465, A088361, A088362, A226528, A226529, A226530, A251597, A253854, A244150, A243959, A321323.
Cf. A006093.

Programs

  • Mathematica
    Do[ k = 1; While[ PowerMod[ n, 1024, 2*k*1024 + 1 ] != 2*k*1024 && k < 2*10^6, k++ ]; If[ k == 2*10^6 && PrimeQ[ n^1024 + 1 ], Print[ n ] ], {n, 2, 13954, 2} ]
    Do[If[PrimeQ[n^1024 + 1], Print[n], ## &[]], {n, 1, 100}] (* Includes first term and runs faster, Daniel Jolly, Nov 04 2014 *)
  • PARI
    isA057002(n) = isprime(n^1024+1) \\ Michael B. Porter, Apr 03 2010

Extensions

More terms from Jeppe Stig Nielsen, Sep 27 2003
Edited at the suggestion of T. D. Noe by N. J. A. Sloane, May 14 2008

A056995 Numbers k such that k^256 + 1 is prime.

Original entry on oeis.org

1, 278, 614, 892, 898, 1348, 1494, 1574, 1938, 2116, 2122, 2278, 2762, 3434, 4094, 4204, 4728, 5712, 5744, 6066, 6508, 6930, 7022, 7332, 8524, 8644, 8762, 8808, 9024, 9142, 9412, 10892, 12206, 13220, 13222, 13246, 13370, 13738, 14114, 14930
Offset: 1

Views

Author

Robert G. Wilson v, Sep 06 2000

Keywords

References

  • Harvey Dubner, Generalized Fermat primes, J. Recreational Math., 18 (1985): 279-280.

Crossrefs

Programs

  • Mathematica
    Do[ k = 1; While[ PowerMod[ n, 256, 2*k*256 + 1 ] != 2*k*256 && k < 10^3, k++ ]; If[ k == 10^3 && PrimeQ[ n^256 + 1 ], Print[ n ] ], {n, 2, 15000, 2} ]
  • PARI
    isA056995(n) = isprime(n^256+1) \\ Michael B. Porter, Apr 01 2010
Showing 1-10 of 21 results. Next