Le calcul de FFT peut être paramétré par la taille de la transformée, le choix du fenêtrage et le recouvrement entre les fenêtres.
Le fichier texte généré contient deux colonnes: fréquence et spectre. Le spectre ou la densité spectrale peuvent être calculés au choix, et exprimés sous forme d'amplitude, de puissance ou en dB.
$ fft -i test.txt -o out.txt -vvv -n 512 -O 2 -t dbs Reading file test.txt ... Read 4096 entries. 14 FFT will be averaged. Input data sample rate: 10.00 Hz FFT SETTINGS: fft size 512 (frequency resolution 0.0195 Hz) Apodization window: Hann, Overlap 50% Effective Noise Bandwidth 0.0293 Hz FFT output: Spectrum in dB Aberrant Limit 1.80e+308. Saving data to out.txt Done.
La version actuelle est 1.0.0.
Les sources et l'exécutable de fft peuvent être téléchargés par SVN anonyme à l'adresse :
https://anonsvn.loudet.org/fft/tags/
fftw (http://www.fftw.org/) doit être installée. Par exemple :
$ sudo apt-get install fftw3 fftw3-devLes étapes classique sont ensuite utilisées:
./configure, make, make install. Des détails sont dans le fichier INSTALL du package d'intallation.
]
[-i , --input=]
[-o , --output=]
[-n {128,256,512,1024,2048,4096,8192,16384,32768,65536,131072,
262144,524288}, --fft={...}]
[-w {none,rectangular,hann,hamming,gauss,blackman,nuttall,blackman-harris,
blackman-nuttall,flat-top}, --window={...}]
[-O {1,2,4,8,16}, --overlap={...}]
[-t {ps,psd,ls,lsd,dbs,dbsd}, --type={...}]
[-a , --aberrant=]
Options:
-h, --help
display this help and exit.
-v[v...], --verbose=
increase/set verbosity level.
-i , --input=
Input filename. Defaults to stdin.
File must contain two columns (x and y) of real data.
-o , --output=
Output filename. Defaults to stdout.
Output file contains the following columns:
-n {128,256,512,1024,2048,4096,8192,16384,32768,65536,131072,262144,524288}
--fft={...}
Set the size of the FFT. Default is 16384.
-w {none or rectangular,hann,hamming,gauss,blackman,nuttall,blackman-harris,
blackman-nuttall,flat-top},
--window= {...}
Set the apodization window. Default is hann.
-O {1,2,4,8,16}, --overlap={...}
Set the samples overlap: 1 (0%), 2 (50%), 4 (75%), 8 (87.5%), 16 (93.75%)
Default value is 2 (overlap = 50%).
-t {ps,psw,psd,psdw,ls,lsw,lsd}, --type={...}
Indicate the type of plot to calculate.
ps Power Spectrum V^2
psd Power Spectral Density V^2/Hz
ls Linear Spectrum V
lsd Linear Spectral Density V/sqrtHz
dbs Spectrum in dB dB [V]
dbsd Spectral Density in dB dB [V/sqrtHz]
Default is 'dbs' (spectrum in dB)
-a , --aberrant=
Threshold for aberrant values suppression. Difference between two
consecutive data must not exceed the specified value.
Aberrant values suppression is not enabled by default.
EXAMPLE:
fft -i test.txt -o out.txt -n 2048 -t dbs
Generate a spectrum in dB (-t) of data in file test.txt (-c), store it in
file out.txt, using a FFT width of 2048 (-n).
]]>
|
SID Monitoring Station de Lionel LOUDET est mis à disposition selon les termes de la licence Creative Commons Attribution - Pas d’Utilisation Commerciale - Partage dans les Mêmes Conditions 3.0 non transposé. |
| Dernière mise à jour : 16 Dec 2010 |
|
Apache/2.4.65 (Debian) |
|