[scilab-Users] carpet of frequencies over time - ideas or hints?

Mike Page Mike at Page-One.Waitrose.com
Wed Oct 13 20:19:03 CEST 2010


Hi Erhy,

Maybe what you want is a time-frequency transform.  The simplest is what is
called a short-time FFT (STFFT).  You just split the input vector into a
series of blocks (possibly overlapping) so that each is spaced apart by the
time resolution you want to see.  You then window and FFT each block to get
a set of power spectra.  You can visualise the spectra in a number of ways
such as plot3d, contour or surf (check out the help text for how to use
these functions).  A more advanced time-frequency transform is the Wigner
transform.  Again, the help text has details of this.

HTH,
Mike.


-----Original Message-----
From: Erhy [mailto:erhy-air at kabsi.at]
Sent: 13 October 2010 08:43
To: users at lists.scilab.org
Subject: [scilab-Users] carpet of frequencies over time - ideas or
hints?


Hello,

 for a music choir I want to generate

a 3D plot with spectral frequencies over time
and traces of the "should be" keynotes.

Thank you for discussion

Erhy

PS. My first steps of ftt over a piece of music:

stacksize('max')
w=loadwave("H:\temp\abc.wav")
y=w(2,:)  // take only one channel
clear w
// because mono, no channel select y=w(1,:);
Fs = 44100;                   // Sampling frequency
L = length(y);                 // Number of samples
NFFT = L + modulo(L,2);         // uprounded even number of samples
Y = fft(y)/L;                  //fft with array of L samples delivers array
of L complex values
f = Fs/2*linspace(0,1,NFFT/2+1);
p = 2*abs( Y(1:NFFT/2+1) );
plot(f,p)  // over all few
[m,i]=maxi(p(:));  // find index of the max.
scf(2);
plot(f((i-1000):(i+1000)),p((i-1000):(i+1000)))  // detail few



No virus found in this incoming message.
Checked by AVG - www.avg.com
Version: 9.0.862 / Virus Database: 271.1.1/3192 - Release Date: 10/12/10
07:34:00




More information about the users mailing list