OFFSET
1,1
COMMENTS
It is only conjectured (see Cino Hilliard's comment at A094076) that this sequence is defined for all n.
FORMULA
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 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Leroy Quet, May 19 2008
EXTENSIONS
More terms from R. J. Mathar, May 20 2008
STATUS
approved