PART II - Analysis of the Sound Signal
In this second part of the project, we use matlab code to compress a music track.
The Fast Fourier Transform (FFT) was used as the compression method in this part. Also, after data was sampled and then compressed using the FFT, we went ahead and zeroed out random frequencies. In this particular case, the algorithm used was: anything that was less than a certain (percent)x(the maximum value obtained from the audio file using wavread) was zeroed out. This allowed for different percentage amounts to produce various results.
We ran the compression algorithm 7 times on the original 'natara.wav' file to get 7 new files ranging from a 5% compression to a 95% compression with an increment of 15% each time.
We compared the original music file to those 7 files looking for differences in quality.
Here are all the files:natara 05%
natara 20%
natara 35%
natara 50%
natara 65%
natara 80%
natara 95%
natara
Subjectively, there is no real difference between the original file and the 65% to 95% files.
We felt a real loss of quality for the 35% and 50% files. We mainly observed a loss in bass. Moreover a strange background sound begins to be audible.
The 20% file is bad quality. We more or less observed the same loss as before.
The 5% file is terrible. Complete loss of bass, weird background sound and inaudible instruments are the main observations we got from this file.
Then we used this matlab code (Matlab - Part II) to output the error:

Weirdly, the 5% file has less error than the 20% one.