# Ulam spiral

The Ulam spiral (or Ulam cloth) consists of integers, starting from a given $n$ at the center, written in a spiral with the prime numbers highlighted or emphasized in some way. For example, writing a spiral with 42 at the center,

 90 89 88 87 86 85 67 68 69 70 71 72 66 51 52 53 54 73 65 50 43 44 55 74 64 49 42 45 56 75 63 48 47 46 57 76 62 61 60 59 58 77 83 82 81 80 79 78

and then simply blanking the composites, we obtain

 67 71 89 53 73 43 47 61 59 83 79

Carrying on this process in more layers will show that most of the primes tend to fall on certain diagonals and not others.

This formation was first pondered by Stanisław Ulam with 1 at the center. He tried carrying out the process much further, and also tried different center values, but in each case the primes would cluster on certain diagonals and sparsely populate others. Because almost all primes are odd, it is easy to explain why they would tend to form diagonals, but much more difficult to explain why they fall on certain diagonals.

## References

• 1 Gardner, M. “Mathematical Recreations: The Remarkable Lore of the Prime Number” Scientific American 210 3: 120 - 128
Title Ulam spiral UlamSpiral 2013-03-22 16:45:41 2013-03-22 16:45:41 PrimeFan (13766) PrimeFan (13766) 4 PrimeFan (13766) Definition msc 11A41 Ulam cloth Ulam spiral