I'm completely new to the world of audio and signals. I noticed that when I opened Audacity and generated one second of silence (details below) and converted the raw WAVE file to a list of integers, that the silence wasn't a bunch of zeroes. (Yes, I was sure to convert the endianness.)
It was a series of seemingly random numbers from -7 to +7. (It was 16-bit signed PCM.)
- Open Audacity
- Click Generate > Silence...
- Set duration to 00h00m01.000s
- Click OK
- Click File > Export > Export as WAV
- Enter a file name
- Specify encoding as "signed 16-bit PCM"
- Click Save
- Open the generated file with a program that lists each chunk as a list of signed 16-bit integers
- (Optional) Convert little-endian words to big-endian words
My guess is that it is because a constant value, which is ideal DC, is equivalent to 0 Hz, and that's too low of a frequency for a speaker to produce, so it generates negligible noise instead.
Anyway, I was wondering, how does Audacity generate silence? Is it random number generation in [-7, +7]? Is there a mathematical formula for the noise?
What is the algorithm for producing that "silence", as a list of 16-bit integers? (which I can easily convert into a WAVE file)
- What algorithm does Audacity use / can I use to generate "silence"?