[music-dsp] Randomizing phase

Karl Nordstrom (UVic) knordstr at ece.uvic.ca
Wed Jun 23 01:39:27 EDT 2004


Hello, I did a little experiment with randomizing the phase of fft's of a
sound sample.  This is what I did:
 - read in the signal
 - windowed the data with a hanning window with 50% overlap
 - did an fft
 - multiplied the fft coefficients by e^(i*random number).  I made sure that
I "mirrored" the same random numbers above Nyquist.
 - did an ifft
 - listened to the result

The original file is sampled at 44.1 kHz.

With a window of 4096 points, the reconstruction sounds pretty much perfect.

With a window of 512 or lower, the voice sounds breathy, getting noisier
with smaller window sizes.  My theory is that the window is too small to
capture the peaks of the primary frequencies in the voice, blurring the
voice into noise.

With a window size of 16,384 points or higher, there is a lot of
reverberation and the timing of the music becomes slushy.  My theory is that
the fft is large enough that the phase changes mess with the timing of the
song itself.

Does anyone have any further insight into this.  I feel like I might be
missing something.

Karl




More information about the music-dsp mailing list