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.

A056208 Primes p+2^n arising in A056206.

Original entry on oeis.org

3, 5, 7, 11, 19, 37, 67, 131, 263, 523, 1031, 2053, 4099, 8209, 16421, 32771, 65539, 131101, 262147, 524341, 1048583, 2097169, 4194371, 8388619, 16777259, 33554473, 67108961, 134217757, 268435459, 536870923, 1073741827, 2147483659
Offset: 0

Views

Author

Labos Elemer, Oct 06 2000

Keywords

Examples

			n=13, 2^13+p=8192+p is not prime for p=2,3,5,7,11,13. At first, for p=17, 8209 is prime; Primes obtained also for many larger p, the next is 8221. So a(13)=8209, the smallest one.
		

Crossrefs

Cf. A056206.

Programs

  • Maple
    f:= proc(n) local p,q,t;
      t:= 2^n; p:= 1;
      do
        p:= nextprime(p);
        q:= p+t;
        if isprime(q) then return q fi
      od
    end proc:
    map(f, [$0..50]); # Robert Israel, Aug 22 2019
  • Mathematica
    a[n_] := Module[{p = 1, q, t = 2^n}, While[True, p = NextPrime[p]; q = p+t; If[PrimeQ[q], Return[q]]]];
    a /@ Range[0, 50] (* Jean-François Alcover, Jun 09 2020, after Maple *)

Extensions

a(0)=3 inserted by Robert Israel, Aug 22 2019