This site is supported by donations to The OEIS Foundation.

 Please make a donation to keep the OEIS running. We are now in our 55th year. In the past year we added 12000 new sequences and reached 8000 citations (which often say "discovered thanks to the OEIS"). We need to raise money to hire someone to manage submissions, which would reduce the load on our editors and speed up editing. Other ways to donate

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A214415 Numbers n such that prevprime(2^n) AND nextprime(2^n) = 1, where AND is the bitwise AND operator. 2
 2, 4, 6, 8, 12, 15, 16, 23, 25, 30, 37, 53, 55, 57, 67, 75, 76, 81, 82, 84, 95, 108, 129, 132, 135, 139, 143, 155, 160, 163, 180, 181, 188, 192, 203, 204, 210, 222, 244, 263, 273, 277, 280, 287, 289, 295, 297, 308, 315, 319, 325, 330, 341, 367, 370, 393, 394, 406 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,1 COMMENTS A007053(a(n)) are indices of 1's in A175330. That is, A175330(A007053(a(n)))=1. Conjecture: the sequence is infinite. LINKS EXAMPLE 4 is in the sequence because (prevprime(2^4) AND nextprime(2^4)) = 13 AND 17 = 1. MATHEMATICA ba1Q[n_]:=Module[{c=2^n}, BitAnd[NextPrime[c], NextPrime[c, -1]]==1]; Select[ Range[ 450], ba1Q] (* Harvey P. Dale, Dec 25 2012 *) PROG (Java) import java.math.BigInteger; public class A214415 {   public static void main (String[] args) {     BigInteger b1 = BigInteger.valueOf(1);     BigInteger b2 = BigInteger.valueOf(2);     for (int n=2; ; n++) {       BigInteger pwr = b1.shiftLeft(n);       BigInteger pm  = pwr.subtract(b1);       BigInteger pp  = pwr.add(b1);       while (true) {         if (pm.isProbablePrime(2)) {             if (pm.isProbablePrime(80)) break;         }         pm  = pm.subtract(b2);       }       while (true) {         if (pp.isProbablePrime(2)) {             if (pp.isProbablePrime(80)) break;         }         pp  = pp.add(b2);       }       if (pm.and(pp).equals(b1)) {         System.out.printf("%d, ", n);       }     }   } } (PARI) { for (n=2, 1000,  N = 2^n;     p1 = precprime(N-1);     p2 = nextprime(N+1);     ba = bitand(p1, p2);     if ( bitand( ba, ba-1 ) == 0, print1(n, ", ")); ); } /* Joerg Arndt, Aug 16 2012 */ CROSSREFS Cf. A007053, A175330. Sequence in context: A082742 A131197 A078327 * A094109 A090404 A015937 Adjacent sequences:  A214412 A214413 A214414 * A214416 A214417 A214418 KEYWORD nonn,base AUTHOR Alex Ratushnyak, Aug 07 2012 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified December 11 02:20 EST 2019. Contains 329910 sequences. (Running on oeis4.)