A238459 Number of primes p < n with q(n-p) + 1 prime, where q(.) is the strict partition function (A000009).
0, 0, 1, 2, 2, 3, 2, 3, 3, 2, 3, 2, 5, 3, 5, 4, 4, 3, 4, 4, 6, 2, 4, 3, 5, 2, 4, 1, 4, 5, 6, 5, 5, 4, 5, 3, 4, 3, 5, 6, 5, 6, 3, 8, 6, 5, 6, 4, 6, 7, 5, 6, 4, 6, 7, 6, 7, 7, 6, 6, 7, 5, 6, 5, 6, 5, 5, 5, 7, 7, 6, 5, 7, 9, 8, 6, 5, 5, 7, 6, 8, 6, 5, 8, 7, 8, 7, 4, 8, 7, 7, 7, 6, 6, 6, 6, 6, 7, 6, 9
Offset: 1
Keywords
Examples
a(3) = 1 since 2 and q(3-2) + 1 = 1 + 1 = 2 are both prime. a(28) = 1 since 17 and q(28-17) + 1 = q(11) + 1 = 12 + 1 = 13 are both prime.
Links
- Zhi-Wei Sun, Table of n, a(n) for n = 1..10000
- Zhi-Wei Sun, Problems on combinatorial properties of primes, arXiv:1402.6641, 2014.
Programs
-
Mathematica
q[n_,k_]:=PrimeQ[PartitionsQ[n-Prime[k]]+1] a[n_]:=Sum[If[q[n,k],1,0],{k,1,PrimePi[n-1]}] Table[a[n],{n,1,100}]
Comments