Sound waves are analog signals, meaning they are continuous. To understand this, we can use a sine wave as a simple example, since it is also a continuous signal.
So, the next question would be: how many samples are required? 30 samples per second? 40 samples per second? Or what’s the number? Let it be whatever, but this number of samples recorded per second is called the sample rate.
Now, to answer this question correctly, understand that there are many frequency components in a sound wave. That means, per second, there could be an irregular number of complete cycles. One particular instance may have a frequency of 2 Hz, and another may have 4 Hz. That’s what a wave signal is like in the natural world.
We need to pick the highest frequency component of all, and our sampling rate should be at least twice the highest frequency value. This number helps in reconstructing the signal perfectly, and this is the so-called Nyquist–Shannon Sampling Theorem. If the highest frequency component in the wave is 3 Hz, the sampling rate should be at least 2*3 Hz = 6 Hz.

Before we answer how this number is enough to represent the complete signal, we have to discuss what happens if we don’t follow the proper sampling rate. Let’s say we have a sampling rate that is lower than the highest frequency component. In such case, If there are 10 complete cycles per second (10 Hz), our sampling rate would represent only 5 complete cycles, making the computer think that the wave is a lower-frequency one. This phenomenon is called Aliasing and it brings us some fake tones, distortion and beating effect in the audio.
Waves from the natural world contain many high-frequency components, often higher than what our sampling system can handle. To avoid problems, we use a low-pass filter to remove those high frequencies before sampling. This ensures that aliasing-causing frequencies are removed.
You might wonder: “Won’t we lose some audio by filtering these frequencies?” The answer is: yes, but that’s okay. Humans can only hear roughly from 20 Hz to 20 kHz. CD audio uses a sampling rate of 44.1 kHz, which means the Nyquist frequency is 22.05 kHz. Any frequency above ~22 kHz is removed, but we cannot hear those frequencies anyway. So there is no audible loss at all.
Once we have enough sampling points and we remove high frequencies, the wave is forced to be smooth. Given these points, there is only one smooth wave that can pass through them. Any other wave would require sharp changes, which are not allowed by the filter.
Sampling gives us dots, and filtering forces smoothness. Together, they force the original wave to come back.
Comments