OFFSET
1,5
EXAMPLE
a(5) = 2 because the fifth prime of the form 6m - 1 is 29, there are three primes of the form 6m + 1 less than 29 (namely 7, 13, 19) and 5 - 3 = 2.
MATHEMATICA
s = Prime@Range@120 /. p_ /; Mod[p, 6] != 5 -> Nothing; Table[n - Count[Flatten@ Prime@ Range@ PrimePi@ Take[s, {n}], p_ /; Mod[p, 6] == 1], {n, 120}] (* Michael De Vlieger, Feb 10 2016 *)
CROSSREFS
KEYWORD
sign
AUTHOR
Gionata Neri, Jan 10 2016
STATUS
approved