Ulam Spiral

The Ulam spiral is a graphical depiction of prime numbers first popularised by mathematician Stanislaw Ulam in 1963. A Ulam spiral is created by creating a spiral of numbers and then highlighting the prime numbers.

Here is a spiral of all numbers from 1 to 99. Follow the increasing numbers from the red centre as it spirals outward to 99.

Sample Ulam Spiral

Here is the same spiral with only the prime numbers displayed.

Ulam Spiral

Create Your Own Ulam Spiral

If you want to create your own Ulam spiral then click here .

Try a starting value of 41 and note the number of prime numbers appearing on the diagonal.

You can re-load the spiral page at anytime to try new values.