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-6 of 6 results.

A139803 A033875(n) + 2^a(n) = A033875(n+1).

Original entry on oeis.org

0, 1, 1, 2, 1, 2, 1, 2, 3, 4, 5, 2, 7, 4, 1, 2, 3, 4, 9, 2, 955, 468
Offset: 1

Views

Author

Johan Särnbratt, May 22 2008

Keywords

Comments

a(23) > 10^4. - Zak Seidov, Jan 24 2017
a(23) > 30000 (if it exists). - Pontus von Brömssen, Jan 08 2023

Examples

			a(10) = 4 because A033875(10) = 31, 31 + 2^4 = 47, which is prime.
		

Crossrefs

Skipping from prime to prime by least powers of 2: A033875.

Programs

  • Mathematica
    p = 2; n = 0; While[true, x = 0; While[ ! PrimeQ[p + 2^x], x++ ]; p = p + 2^x; Print[x]; n++ ]

Formula

a(n) = A067760((A033875(n)-1)/2) for n >= 2. - Pontus von Brömssen, Jan 08 2023

A059661 Like A059459, but each term must be greater than the previous ones.

Original entry on oeis.org

2, 3, 7, 23, 31, 4127, 4159, 20543, 134238271, 134238527, 167792959, 1241534783, 3389018431, 72108495167, 72108503359, 72108765503, 2722258935367507707706996859526254457151, 2722258935367507707708149781030861304127, 13611294676837538538536137218847444070719
Offset: 1

Views

Author

Antti Karttunen, Feb 03 2001

Keywords

Crossrefs

Programs

  • Maple
    flip_primes_asc_search := proc(a,upto_bit,upto_length) local i,n,t; if(nops(a) >= upto_length) then RETURN(a); fi; t := a[nops(a)]; for i from 0 to upto_bit do n := XORnos(t,(2^i)); if(isprime(n) and (n > t)) then print([op(a), n]); RETURN(flip_primes_asc_search([op(a), n],upto_bit,upto_length)); fi; od; RETURN([op(a),`and no more`]); end;
    flip_primes_asc_search([2],512,21);
  • Mathematica
    uptobit = 512; uptolength = 17; Clear[f]; f[a_] := f[a] = Module[{n, i, t}, If[Length[a] >= uptolength, Return[a]]; t = a[[-1]]; For[i = 0, i <= uptobit, i++, n = BitXor[t, 2^i]; If[PrimeQ[n] && n > t, Return[f[Append[ a, n]]]]]]; A059661 = f[{2}] (* Jean-François Alcover, Mar 07 2016, adapted from Maple *)
  • Python
    from sympy import isprime
    from itertools import islice
    def agen():
        an, bit = 2, 1
        while True:
            yield an
            while an&bit or not isprime(an+bit): bit <<= 1
            an += bit; bit = 1
    print(list(islice(agen(), 17))) # Michael S. Branicky, Oct 01 2022

Formula

a(n) = 2 + Sum_{k=1..n-1} 2^A059662(k). - Pontus von Brömssen, Jan 07 2023

A087592 Primes whose successive differences are increasing power of 2: a(1) = 2, a(n+1) = a(n) + 2^k; a(n+1) prime, k minimal and greater than the index for the previous term.

Original entry on oeis.org

2, 3, 5, 13, 29, 61, 317, 829, 1073742653
Offset: 1

Views

Author

Amarnath Murthy, Sep 18 2003

Keywords

Comments

Next term a(9) has 292 digits and is too large to include.

Crossrefs

Extensions

Corrected and extended by Ray Chandler, Sep 25 2003

A139758 a(n) is the smallest prime such that (a(n) - the n-th prime) is a power of 2.

Original entry on oeis.org

3, 5, 7, 11, 13, 17, 19, 23, 31, 31, 47, 41, 43, 47, 79, 61, 61, 317, 71, 73, 89, 83, 211, 97, 101, 103, 107, 109, 113, 241, 131, 139, 139, 1163, 151, 167, 173, 167, 199, 181, 181, 197, 193, 197, 199, 263, 227, 227, 229, 233, 241, 241, 257, 283, 769, 271, 271
Offset: 1

Views

Author

Leroy Quet, May 19 2008

Keywords

Comments

It is only conjectured (see Cino Hilliard's comment at A094076) that this sequence is defined for all n.

Crossrefs

Programs

  • Maple
    A094076 := proc(n) local k,p ; k := 0 ; p := ithprime(n) ; while not isprime(p+2^k) do k := k+1 ; od: k ; end: A139758 := proc(n) ithprime(n)+2^A094076(n) ; end: seq(A139758(n),n=1..80) ; # R. J. Mathar, May 20 2008
  • Mathematica
    sp2[n_]:=Module[{p=Prime[n],k},k=NextPrime[p];While[!IntegerQ[Log[2,k-p]],k=NextPrime[k]];k]; Array[sp2,60] (* Harvey P. Dale, Dec 27 2019 *)

Formula

a(n) = A000040(n) + 2^A094076(n). - R. J. Mathar, May 20 2008

Extensions

More terms from R. J. Mathar, May 20 2008

A102635 Skipping from prime to prime by least powers of 2 using 53 as the seed.

Original entry on oeis.org

53, 61, 317, 349, 353, 134218081
Offset: 1

Views

Author

Lei Zhou, Jan 20 2005

Keywords

Comments

By skipping least power of 2, the numbers in sequence A033875 jump up rapidly and leave most of the primes behind. The first skipped prime is 29 but it joins the sequence by 29+2^1=31. So does 37. Then comes 53, it makes the second sequence in this row to an enormous number. Thereafter 67 goes back to the original sequence at 241. The next candidate sequence head is 127, which is in A102636

Examples

			53+2^3 = 61 is prime
134218081+2^392 is prime
		

Crossrefs

Formula

a(1) = 53, a(n+1) = a(n) + 2^k; a(n+1) prime, k minimal.

Extensions

The next term is too large to include.

A102636 Skipping from prime to prime by least powers of 2 using 127 as the seed.

Original entry on oeis.org

127, 131, 139, 1163, 1171, 1187, 1699, 263843, 265891, 269987, 33824419, 33824423, 33824431, 33889967, 33889969, 33890033, 33892081, 33892337, 220855883097298041197912187592864814478435487109452369765200775195469809
Offset: 1

Views

Author

Lei Zhou, Jan 21 2005

Keywords

Comments

By skipping least power of 2, the numbers in sequence A033875 reaches an enormous element at n=22. The next not merged sequence starts from 53 and gets to a big number at n=7 (A102635). Can this sort of sequence with relatively more small primes? The next sequence seeded 127 (this sequence). It gets 19 elements within n<1000.

Examples

			127+2^2 = 131 is prime
33892081+2^8 = 33892337 is prime
		

Crossrefs

Formula

a(1) = 127, a(n+1) = a(n) + 2^k; a(n+1) prime, k minimal.
Showing 1-6 of 6 results.