login
a(n) = |{0 < k < n: {6*k -1 , 6*k + 1} and {prime(n-k), prime(n-k) + 2} are both twin prime pairs}|.
10

%I #16 Apr 06 2014 10:49:32

%S 0,0,1,2,2,2,2,3,2,3,1,4,2,3,4,1,3,2,3,5,2,4,3,2,4,1,5,4,3,5,3,3,4,3,

%T 7,5,4,7,1,7,1,5,8,3,8,5,5,5,3,9,6,6,7,4,6,3,5,8,6,7,5,6,4,5,7,7,6,5,

%U 4,4,6,5,7,6,9,3,5,5,5,6,5,8,5,5,6,5,7,4,5,10,3,7,5,6,3,4,7,5,6,6

%N a(n) = |{0 < k < n: {6*k -1 , 6*k + 1} and {prime(n-k), prime(n-k) + 2} are both twin prime pairs}|.

%C Conjecture: (i) a(n) > 0 for all n > 2.

%C (ii) If n > 3 is neither 11 nor 125, then n can be written as k + m with k > 0 and m > 0 such that 6*k - 1, 6*k + 1, prime(m) + 2 and 3*prime(m) - 10 are all prime.

%C (iii) Any integer n > 458 can be written as p + q with q > 0 such that {p, p + 2} and {prime(q), prime(q) + 2} are both twin prime pairs.

%C This is much stronger than the twin prime conjecture. We have verified part (i) of the conjecture for n up to 2*10^7.

%H Zhi-Wei Sun, <a href="/A236531/b236531.txt">Table of n, a(n) for n = 1..10000</a>

%H Z.-W. Sun, <a href="http://arxiv.org/abs/1402.6641">Problems on combinatorial properties of primes</a>, arXiv:1402.6641, 2014

%e a(11) = 1 since {6*1 - 1, 6*1 + 1} = {5, 7} and {prime(10), prime(10) + 2} = {29, 31} are both twin prime pairs.

%e a(16) = 1 since {6*3 - 1, 6*3 + 1} = {17, 19} and {prime(13), prime(13) + 2} = {41, 43} are both twin prime pairs.

%t p[n_]:=PrimeQ[6n-1]&&PrimeQ[6n+1]

%t q[n_]:=PrimeQ[Prime[n]+2]

%t a[n_]:=Sum[If[p[k]&&q[n-k],1,0],{k,1,n-1}]

%t Table[a[n],{n,1,100}]

%Y Cf. A000040, A001359, A002822, A006512, A199920.

%K nonn

%O 1,4

%A _Zhi-Wei Sun_, Jan 27 2014