login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A054272 Number of primes in the interval [prime(n), prime(n)^2]. 13
2, 3, 7, 12, 26, 34, 55, 65, 91, 137, 152, 208, 251, 270, 315, 394, 471, 502, 591, 656, 685, 790, 864, 977, 1139, 1227, 1268, 1354, 1395, 1494, 1847, 1945, 2109, 2157, 2455, 2512, 2693, 2878, 3005, 3202, 3396, 3471, 3826, 3902, 4045, 4119, 4581, 5059 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

These primes are candidates for fortunate numbers (A005235).

These are precisely the primes available for the solution of Aguilar's conjecture or Haga's conjecture in Carlos Rivera's The Prime Puzzles and Problems Connection, (conjecture 26). Aguilar's conjecture states that at least one prime will be available for placement on each row and column of a p X p square array. Haga's conjecture states that just p primes are required for such placement in any p X p array. - Enoch Haga, Jan 23 2002

Also number of times p_n (the n-th prime) occurs as the least prime factor (A020639) among numbers in range [(p_n)+1, ((p_n)^3)-1]. For n=1, p_1 = 2 and there are two even numbers in range [3, 7], namely 4 and 6, so a(1) = 2. See also A250474. - Antti Karttunen, Dec 05 2014

The number of consecutive primes after the leading 1 in the prime(n)-rough numbers. - Benedict W. J. Irwin, Mar 24 2016

LINKS

Antti Karttunen, Table of n, a(n) for n = 1..5000

Carlos Rivera, Conjecture 26. The Calendar-like square Conjecture, The Prime Puzzles and Problems Connection.

FORMULA

a(n) = A000879(n) - n + 1.

From Antti Karttunen, Dec 05-08 2014: (Start)

a(n) = A250473(n) - 1 = A250474(n) - 2.

a(n) = sum_{d | A002110(n)} moebius(d) * floor((p_n)^2 / d). [Where p_n is the n-th prime (A000040(n)) and A002110(n) gives the product of the first n primes. Because the latter is always squarefree, one could also use Liouville's lambda (A008836) instead of Moebius mu (A008683).]

The ratio (a(n) * A002110(n)) / (A001248(n) * A005867(n)) stays near 1, which follows from the above summation formula. See also A249747.

(End)

EXAMPLE

n=4, the zone in question is [7,49] and encloses a(4)=12 primes, as follows: {7,11,13,17,19,23,29,31,37,41,43,47}.

MATHEMATICA

a[n_] := PrimePi[Prime[n]^2] - n + 1; Array[a, 50] (* Jean-François Alcover, Dec 07 2015 *)

PROG

(PARI)

\\ A fast version:

default(primelimit, 2^31 + 2^30);

A054272(n) = 1 + primepi(prime(n)^2) - n;

for(n=1, 5000, write("b054272.txt", n, " ", A054272(n)));

\\ The following mirrors the given new formula. It is far from an optimal way to compute this sequence:

allocatemem(234567890);

A002110(n) = prod(i=1, n, prime(i));

A054272(n) = { my(p2); p2 = prime(n)^2; sumdiv(A002110(n), d, moebius(d)*floor(p2/d)); };

for(n=1, 22, print1(A054272(n), ", ")); \\ Antti Karttunen, Dec 05 2014

CROSSREFS

One less than A250473, two less than A250474.

First differences: A251723.

Cf. A000040, A000879, A001248, A002110, A005235, A005867, A008683, A008836, A020639, A078898, A249747.

Sequence in context: A108742 A018240 A090596 * A259593 A129016 A099163

Adjacent sequences:  A054269 A054270 A054271 * A054273 A054274 A054275

KEYWORD

nonn

AUTHOR

Labos Elemer, May 05 2000

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified January 20 10:36 EST 2018. Contains 297960 sequences.