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

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A006879 Number of primes with n digits.
(Formerly M3577)
18
0, 4, 21, 143, 1061, 8363, 68906, 586081, 5096876, 45086079, 404204977, 3663002302, 33489857205, 308457624821, 2858876213963, 26639628671867, 249393770611256, 2344318816620308, 22116397130086627, 209317712988603747, 1986761935284574233, 18906449883457813088, 180340017203297174362 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,2

COMMENTS

Also, the number of primes between 10^(n-1) and 10^n. - Cino Hilliard (hillcino368(AT)hotmail.com), May 31 2008 (Corrected by Jon Schoenfield, Nov 29 2008)

REFERENCES

J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 21, pp 8, Ellipses, Paris 2008.

C. T. Long, Elementary Introduction to Number Theory. Prentice-Hall, Englewood Cliffs, NJ, 1987, p. 77.

P. Ribenboim, The Book of Prime Number Records. Springer-Verlag, NY, 2nd ed., 1989, p. 179.

D. Shanks, Solved and Unsolved Problems in Number Theory. Chelsea, NY, 2nd edition, 1978, p. 15.

N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

LINKS

Charles R Greathouse IV, Table of n, a(n) for n = 0..24

C. K. Caldwell, How Many Primes Are There?

Cino Hilliard Count,Sum primes in a range Win32 Gcc+Gmp.

Index entries for sequences related to numbers of primes in various ranges

FORMULA

a(n) = pi(10^n)-pi(10^(n-1)) where pi(10^(-1)) := 0 (cf. A000720).

EXAMPLE

As 2,3,5 and 7 are the only primes less than 10 the term a(1) = 4.

PROG

(PARI) a(n)=primepi(10^n)-primepi(10^(n-1)) \\ Charles R Greathouse IV, May 03 2012

(C) See Hilliard link.

CROSSREFS

First differences of A006880.

Sequence in context: A120368 A053482 A158577 * A163861 A006153 A183387

Adjacent sequences:  A006876 A006877 A006878 * A006880 A006881 A006882

KEYWORD

nonn,base,hard

AUTHOR

N. J. A. Sloane, Simon Plouffe

EXTENSIONS

11-th and 12th terms corrected by Jud McCranie and Enoch Haga; 19th term corrected and 20th term added by Paul.Zimmermann(AT)loria.fr (Paul Zimmermann).

a(21)-a(22) from Vladeta Jovovic, Nov 07 2001

STATUS

approved

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

Content is available under The OEIS End-User License Agreement .

Last modified June 19 19:50 EDT 2013. Contains 226416 sequences.