login
Smallest k>=1 such that the n-th semiprime + or - k are both primes, or a(n)=0 if there is no such k.
2

%I #30 Jun 01 2014 02:16:11

%S 1,1,2,3,3,2,2,9,6,3,4,3,6,9,2,15,12,8,12,4,15,9,6,2,15,6,15,12,3,14,

%T 12,4,15,6,3,2,12,9,12,18,9,14,2,6,3,10,15,6,6,33,18,9,8,12,15,12,4,

%U 15,10,6,6,3,10,9,24,6,27,18,14,15,18,6,21,8,30,3

%N Smallest k>=1 such that the n-th semiprime + or - k are both primes, or a(n)=0 if there is no such k.

%C If the sequence has no zeros at least for sufficiently large n, then one can believe that, for a pair of sufficiently large semiprimes of the same parity {r,s}, there is a number k=k(r,s) such that either {r-k, s+k} or {r+k, s-k} is a pair of primes. Then, if a representation 2*n = r+s with, say, min{r,s} > log(n) is considered, then, at least for sufficiently large n, it is reduced to the Goldbach representation 2*n = p+q with primes p,q. It is natural to think that a Goldbach-like conjecture that at least every sufficiently large even number is a sum of two semiprimes could be proved more easily than the classic Goldbach conjecture (cf. Chen's theorem).

%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Chen&#39;s_theorem">Chen's theorem</a>

%o (PARI)

%o list(lim) = my(v=List(), t); forprime(p=2, sqrt(lim), t=p; forprime(q=p, lim\t, listput(v, t*q))); vecsort(Vec(v)) \\ From A001358

%o sp = list(1000); vector(#sp, n, k=1; while(!isprime(sp[n]+k) || !isprime(sp[n]-k), k++); k) \\ _Colin Barker_, May 31 2014

%Y Cf. A001358, A241531, A241533, A241535, A241536.

%K nonn

%O 1,3

%A _Vladimir Shevelev_, Apr 25 2014

%E More terms from _Peter J. C. Moses_, Apr 28 2014