OFFSET
1,1
FORMULA
a(n) = sum of primes between (prime(n))^2 and (prime(n+1))^2.
EXAMPLE
a(1)=12 because between (prime(1))^2=2^2=4 and (prime(2))^2=3^2=9 there are 2 primes {5,7} which sum to 12
a(2)=83 because between (prime(2))^2=9 and (prime(3))^2=25 there are 5 primes {11,13,17,19,23} which sum to 83
a(3)=228 because between 5^2=25 and 7^2=49 there are 6 primes {29,31,37,41,43,47} which sum to 228
a(4)=1265 because between 49 and 121 there are 15 primes {53..113} which sum to 1265
a(5)=1321 because between 121 and 169 there are 9 primes {127..167} which sum to 1321.
MATHEMATICA
Table[Total[Select[Range[Prime[n]^2, Prime[n+1]^2], PrimeQ]], {n, 60}]
Total[Select[Range[#[[1]], #[[2]]], PrimeQ]]&/@ Partition[Prime[ Range[ 40]]^2, 2, 1] (* Harvey P. Dale, Jul 13 2015 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Zak Seidov, Nov 12 2009
STATUS
approved