A073610 Number of primes of the form n-p where p is a prime.
0, 0, 0, 1, 2, 1, 2, 2, 2, 3, 0, 2, 2, 3, 2, 4, 0, 4, 2, 4, 2, 5, 0, 6, 2, 5, 0, 4, 0, 6, 2, 4, 2, 7, 0, 8, 0, 3, 2, 6, 0, 8, 2, 6, 2, 7, 0, 10, 2, 8, 0, 6, 0, 10, 2, 6, 0, 7, 0, 12, 2, 5, 2, 10, 0, 12, 0, 4, 2, 10, 0, 12, 2, 9, 2, 10, 0, 14, 0, 8, 2, 9, 0, 16, 2, 9, 0, 8, 0, 18, 2, 8, 0, 9, 0, 14, 0, 6
Offset: 1
Keywords
Examples
a(16) = 4 as there are 4 primes 3,5,11 and 13 such that 16-3,16-5,16-11and 16-13 are primes.
Links
- T. D. Noe, Table of n, a(n) for n=1..10000
Programs
-
Maple
for i from 1 to 500 do a[i] := 0:j := 1:while(ithprime(j)
-
Mathematica
nn=20;a[x]:=Sum[x^i,{i,Table[Prime[n],{n,1,nn}]}];Drop[CoefficientList[a[x]^2,x],1] (* Geoffrey Critzer, Nov 22 2012 *)
-
PARI
Vec(sum(i=1,100,x^prime(i),O(x^prime(101)))^2) \\ Charles R Greathouse IV, Jan 21 2015
Formula
G.f.: (Sum_{k>0} x^prime(k))^2. - Vladeta Jovovic, Mar 12 2005
Self-convolution of characteristic function of primes (A010051). - Graeme McRae, Jul 18 2006
Extensions
Corrected and extended by Vladeta Jovovic and Sascha Kurz, Aug 06 2002
Comments