View
    Number sets

    More about the Polar number plot

    Polar number plot

    Put every whole number n at the point with radius n and angle n radians. The dots wind outward in a spiral. Color only the primes and they fall into a few arms, then 20 spiral arms, then 280 straight rays as you zoom out. Eighteen number sets each get their own color, from even and odd to semiprimes, abundant and happy numbers, and a table lists every number with its coordinates and sets. Every whole number n is a point at radius n and angle n. Switch number sets on to color them. Scroll or pinch to zoom, drag to move, double-click to fit, and point at a dot or tap it to read its sets. Table lists the same numbers with their coordinates.

    How it works

    1. Open the page: the primes up to 20,000 are plotted at radius n and angle n radians.
    2. Switch other number sets on, change how far to count, or pick an example: six arms, 710 rays, the sunflower of the golden angle, or 36 rays in degrees.
    3. Scroll or pinch to zoom and point at a dot to read its sets. Switch to Table for the coordinates and a count of every set, and save a PNG, a PDF or a CSV.

    Why spirals?

    One radian is about 57.3°, so each number turns a little more than the one before. After 6 numbers the dots have turned 6 radians, just short of a full turn of 2π ≈ 6.283, so every sixth number sits nearly on the same line and the dots form 6 slowly curving arms. Further out, 44 radians is almost exactly 7 full turns, so the numbers form 44 spiral arms. Further still, 710 radians is 113 turns to within 0.00001 of a turn: 710 straight rays. These come from 22/7 and 355/113, the famous fractions close to π.

    Why primes leave gaps

    In the 6-arm picture, arms 0, 2, 3 and 4 hold only multiples of 2 or 3, so no prime (above 3) can be there. All primes sit on the two arms of numbers 6k + 1 and 6k − 1. In the 44-arm picture the primes avoid every arm whose number shares a factor with 44, and keep the 20 arms coprime to 44. In the 710-ray picture they keep the 280 rays coprime to 710. That is Dirichlet's theorem on primes in arithmetic progressions, made visible.

    Eighteen sets in one picture

    Integers, even, odd, multiples of 7 and 10, primes, twin primes, composites, semiprimes, highly composite, abundant, perfect squares and cubes, powers of 2, triangular, Fibonacci, palindromic and happy numbers. Sparse sets are drawn on top with bigger dots. Change the angle to one degree and the multiples of 10 make 36 straight rays; choose the golden angle with r = √n and you get the seed pattern of a sunflower.

    Frequently asked questions

    What does the polar number plot show?

    Each whole number n is drawn at the point with polar coordinates (n, n): distance n from the center and angle n radians. In x and y that is (n cos n, n sin n). You can also use an angle of one degree per number, the golden angle, or a radius of √n.

    Why do the primes make spirals and rays?

    The spirals come from the angle: 6, 44 and 710 radians are each very close to a whole number of turns, so numbers that far apart line up. The primes then skip every arm or ray whose numbers share a factor with 6, 44 or 710, which leaves the gaps.

    Which number sets can I plot?

    Integers, even, odd, multiples of 7, multiples of 10, primes, twin primes, composites, semiprimes, highly composite, abundant, perfect squares, perfect cubes, powers of 2, triangular, Fibonacci, palindromic and happy numbers, each in its own color.

    Is there a table?

    Yes. Table shows how many numbers up to N are in each set, their share and the first members, and a paged list of every number with r, θ, x, y and its sets. Copy the summary or download the whole list as a CSV.

    How far can it count?

    Up to 200,000. All numbers are classified in your browser in a fraction of a second; nothing leaves your device.

    Ready to try it?

    Open PictorX in your browser — no install, no credit card required to start.

    Go to Editor