%I #13 Mar 16 2014 19:46:10
%S 0,0,0,1,1,2,2,3,3,2,4,2,5,3,3,4,1,3,4,4,5,4,4,4,4,3,3,5,5,5,3,6,8,5,
%T 5,3,5,6,4,4,7,6,4,4,3,5,3,4,3,5,4,4,3,3,4,2,4,2,4,4,3,4,9,3,7,4,6,4,
%U 5,5,7,4,9,9,7,7,11,7,8,8
%N Number of odd primes p <= n with pi(n*(p+1)/2) - pi(n*(p-1)/2) prime, where pi(x) denotes the number of primes not exceeding x.
%C Conjecture: a(n) > 0 for all n > 3, and a(n) = 1 only for n = 4, 5, 17.
%C We have verified this for n up to 3*10^5.
%H Zhi-Wei Sun, <a href="/A239330/b239330.txt">Table of n, a(n) for n = 1..10000</a>
%H Zhi-Wei Sun, <a href="http://arxiv.org/abs/1402.6641">Problems on combinatorial properties of primes</a>, arXiv:1402.6641, 2014.
%e a(4) = 1 since 3 and pi(4*(3+1)/2) - pi(4*(3-1)/2) = pi(8) - pi(4) = 4 - 2 = 2 are both prime.
%e a(5) = 1 since 5 and pi(5*(5+1)/2) - pi(5*(5-1)/2) = pi(15) - pi(10) = 6 - 4 = 2 are both prime.
%e a(17) = 1 since 11 and pi(17*(11+1)/2) - pi(17*(11-1)/2) = pi(102) - pi(85) = 26 - 23 = 3 are both prime.
%t p[n_,k_]:=PrimeQ[PrimePi[n*(Prime[k]+1)/2]-PrimePi[n*(Prime[k]-1)/2]]
%t a[n_]:=Sum[If[p[n,k],1,0],{k,2,PrimePi[n]}]
%t Table[a[n],{n,1,80}]
%Y Cf. A000040, A000720, A237578, A238278, A239328.
%K nonn
%O 1,6
%A _Zhi-Wei Sun_, Mar 16 2014