login
A262980
Number of ordered ways to write n as p + 2^k + pi(2^m), where p is prime, and k and m are nonnegative integers, and pi(x) denotes the number of primes not exceeding x.
2
0, 0, 1, 3, 4, 5, 6, 7, 7, 8, 8, 7, 9, 7, 12, 7, 10, 7, 12, 9, 14, 11, 12, 10, 15, 8, 13, 6, 12, 7, 12, 9, 13, 9, 14, 11, 15, 11, 18, 9, 14, 8, 14, 10, 18, 13, 11, 9, 18, 13, 17, 10, 13, 7, 15, 12, 14, 10, 10, 10, 15, 12, 19, 11, 15, 12, 16, 10, 20, 12, 13, 12, 20, 12, 23
OFFSET
1,4
COMMENTS
Conjecture: a(n) > 0 for all n > 2.
We have verified this for n up to 2*10^8.
In contrast with this conjecture, in 1971 R. Crocker proved that there are infinitely many positive odd numbers not of the form p + 2^k + 2^m, where p is prime, and k and m are positive integers.
LINKS
Roger Crocker, On the sum of a prime and of two powers of two, Pacific J. Math. 36 (1971), 103-107.
MAPLE
a(3) = 1 since 3 = 2 + 2^0 + pi(2^0) with 2 prime.
a(4) = 3 since 4 = 2 + 2^0 + pi(2) = 2 + 2 + pi(2^0) = 3 + 2^0 + pi(2^0) with 2 and 3 both prime.
MATHEMATICA
f[n_]:=PrimePi[2^n]
Do[r=0; Do[If[f[x]>=n, Goto[aa]]; Do[If[PrimeQ[n-f[x]-2^y], r=r+1], {y, 0, Log[2, n-f[x]]}]; Continue, {x, 0, n}]; Label[aa]; Print[n, " ", r]; Continue, {n, 1, 100}]
KEYWORD
nonn
AUTHOR
Zhi-Wei Sun, Oct 06 2015
STATUS
approved