home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!usc!elroy.jpl.nasa.gov!news.claremont.edu!ucivax!gateway
- From: kibler@turing.ICS.UCI.EDU (Dennis Kibler)
- Subject: Primes
- Message-ID: <9208171021.aa01492@Paris.ics.uci.edu>
- Newsgroups: sci.math
- Lines: 39
- Date: 17 Aug 92 17:36:15 GMT
-
- In mathematica the number of primes less than n or equal to n
- is given by PrimePi[n].
-
- The following took about 1 second to compute.
-
-
-
- Do[Print[i," ",PrimePi[2^i]],{i,30}]
- 1 1
- 2 2
- 3 4
- 4 6
- 5 11
- 6 18
- 7 31
- 8 54
- 9 97
- 10 172
- 11 309
- 12 564
- 13 1028
- 14 1900
- 15 3512
- 16 6542
- 17 12251
- 18 23000
- 19 43390
- 20 82025
- 21 155611
- 22 295947
- 23 564163
- 24 1077871
- 25 2063689
- 26 3957809
- 27 7603553
- 28 14630843
- 29 28192750
- 30 54400028
-
-