OFFSET
1,1
LINKS
Indranil Ghosh, Table of n, a(n) for n = 1..1000
Vladimir Shevelev, A classification of the positive integers over primes
FORMULA
For n>1, a(n) = pi(prime(n+1)^2/prime(n))-n +1, where pi(x) is the prime counting function (cf. A000720). - Vladimir Shevelev, Sep 28 2014
EXAMPLE
For n=2, using the formula, we have a(2)=pi(25/3)-1=3.
MATHEMATICA
a[1] = 3; a[n_] := PrimePi[Prime[n + 1]^2 / Prime[n]] - n + 1; Table[a[n], {n, 1, 87}] (* Indranil Ghosh, Mar 09 2017 *)
PROG
(PARI) for (n=1, 87, print1(if(n==1, 3, primepi(prime(n + 1)^2 / prime(n)) - n + 1), ", ")) \\ Indranil Ghosh, Mar 09 2017
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Shevelev, Sep 18 2014
EXTENSIONS
More terms from Peter J. C. Moses, Sep 18 2014
STATUS
approved