Prime numbers: introduction to Python

We can introduce many of the features of the Python language by writing a program to generate prime numbers. We can also test some cool mathematical predictions of the asymptotic density of primes...

Links


James P. Sethna,

Last modified: August 24, 2006

Statistical Mechanics: Entropy, Order Parameters, and Complexity, now available at Oxford University Press (USA, Europe).