84
D. Rocchesso: Sound Processing
sonogram
spectrogram
waterfall plot
where f
1
= 0.2F
s
and f
2
= 0.23F
s
, using N = R = 64. See the effects of halfing
and doubling N = R, and observe the presence of leakage. Finally, repeat the
exercise with R = 32, and N = 64 or N = 128.
4.1.4
Representations
One of the most useful visual representations of audio signals is the sonogram,
also called spectrogram, that is a color- or grey-scale rendition of the magnitude
of the STFT, on a 2D plane where time and frequency are the orthogonal axes.
Figure 6 shows the sonogram of the signal analyzed in exercise 28. Time
is on the horizontal axis and frequency is on the vertical axis. Another useful
visualization is the 3D plot, also called waterfall plot in sound analysis programs,
when the analysis frames are presented one after the other from back to front.
Figure 7 shows the 3D representation of the same signal analysis of figure 6.
Figure 6: Sonogram representation of the signal (15). N = 128 and R = 64.
The Matlab signal processing toolbox, as well as the octave-forge project
(see the appendix B), provide a function specgram that can be used to provide
plots similar to those of figures 6 and 7. Specifically, these figures have been
obtained by means of the octave script:
Fs = 44100;
f1 = 0.2 * Fs;
f2 = 0.23 * Fs;
NMAX = 4096;
n = [1:NMAX];
x1 = 0.8 * sin (2*pi*f1/Fs*n);
x2 = sin (2*pi*f2/Fs*n);
y = x1 + x2;
N = 128;
R = 64;
[S,f,t] = specgram(y, N, Fs, hanning(R), R/2);
S = abs(S(2:N/2,:));
# magnitude in Nyquist range
S = S/max(S(:));
# normalize magnitude so that max is 0 dB.
Next Page >>
<< Previous Page
Back to the Table of Contents