# Noise from Integer Sequences

Headphones are strongly recommended for listening to the sounds on this page.

For a given integer sequence (by which I mean an increasing sequence of positive integers), we can make an audio file by creating audio events at times corresponding to the terms of the sequence.

If the sequence is {a1, a2, ...}, then we can create sound events at times {r a1, r a 2, ...} for some suitable scaling factor, r.

Depending on the value of r and the nature of the sound events created, many results are possible.

Here, I have taken this to an extreme. The sound events are one sample in length, of maximal amplitude, and r is 1/44,100 of a second, corresponding to the standard CD sound sampling rate.

Thus, the audio file created has samples that are merely "on" or "off". The n-th sample is on only if n appears in the sequence.

The result is "noise", in most cases, with characteristics which depend on the nature of the sequence.

A curious feature of this method is that the resulting sounds from a sequence, and from the complement of that sequence, sound identical, since one is the inverted waveform of the other. Harmonic components can appear due to the presence, or non-presence, of certain multiples.

When a sequence is not too "regular", and doesn't thin out too quickly (as, e.g., the squares sequence below illustrates), we may get something interesting.

• Primes less than 106 (23 sec.) This illustrates the randomness of the primes, and yet it also shows their consistency: it's noise, but it's essentially always the same noise.
• Primes from 1020 to 1020+106 (23 sec.) The primes do thin out, but it takes a long time to notice it. You can't actually hear the thinning at the rate these files are made, so we jump ahead to 1020, and we hear the noise is now more of a roar: a bit quieter, and more crackly, as the primes are less dense among the integers here.
• Semiprime numbers (i.e. numbers which are the product of two distinct primes) less than 106 (23 sec.) Semiprimes are more common than primes, so this is louder and smoother than the prime sounds. Strong harmonics include those at 44100/4=11025 and 44100/5 = 8820, since no multiples of 4 are in the sequence, and all prime multiples of 5 are.
• Abundant numbers less than 106 (23 sec.) Every multiple of 6 is abundant, so we hear harmonic peaks at 44100/6=7350, 7350/2=3675, 7350/3=2450, etc. This makes the sound less pure noise in a certain sense, and more of a buzz or machine type sound.
• Ten minutes of the abundant numbers (less than 27 million) (612 sec.)
• Square-free numbers less than 106 (23 sec.) Square-free numbers have a positive asymptotic density of 6/pi2, so they don't thin out. The sound is thick and quite stable. Since multiples of 4, 9, 25, 36, etc., are not among this sequence, there are harmonic peaks at 44100/4,44100/9,44100/25, etc., and multiples of these frequencies.
• Numbers whose number of divisors is a power of 2, less than 106 (23 sec.) If a number is square-free, then it has a number of divisors that is a power of 2. However, other numbers also have this property (27, for instance). This sound doesn't have quite as strong peaks as the square-free one; the most prominent below 11,000 is 5512=44100/8. Note that 8 times a square-free odd number is a number in this sequence.
• Numbers with exactly 6 divisors, less than 106 (23 sec.) Quite similar to the primes sound.
• Number with exactly 10 divisors, less than 106 (23 sec.) Also quite similar to the primes sound.
• Numbers which are equal to σ(n) for some n, less than 106 (23 sec.) The function σ(n) is the sum of divisors of n. For example, &sigma(4)=1+2+4=7. So 7 is part of this sequence. The number 5, however, is not: there is no number n such that σ(n)=5. This sequence is pretty uniformly noisy, but there is a peak at 7350 hz, since 44100/7350=6 and lots of values of σ(n) are multiples of 6.
• Ulam numbers (1, 2, 3, 4, 6, 8, 11, ...) less than 106 (23 sec.) This one has a strong harmonic peak at about 2040 hz (44100/2040 = 21.617...). The Ulam numbers have a known wavelike nature, with repeated clumps (see, for instance, the comments here).
• Happy numbers less than 106 (23 sec.) This one has a lot going on in it. Definitely one for headphones.
• Harshad numbers less than 106 (23 sec.) You can clearly hear the effect of this being a base-dependent sequence, with a distinct cycling every 100,000, and a weaker one every 10,000. A strong harmonic component at 4900=44100/9 hz.
• Palindromic numbers, less than 106 (23 sec.) Palindromes are rather rare, so the sound is mostly "clicking" rather than noise.
• Squares less than 10^6 (23 sec.) Illustrates what happens if the sequence has a very regular distribution. Not noisy at all.