Eric Weeks
- personal pages - softwareAutocorrelation softwareC language source code for calculating the autocorrelation function |
weeks@physics.emory.edu |
For a brief description of what an autocorrelation function is,
click here. Note that my program is not the most efficient way
to compute autocorrelations; the best way involves FFT's.
Click here to download software. To compile, use "cc -o autocor autocor.c -lm".
To use the software, you can either specify the filename or pipe the data into the program:
or
There are three options. -h lists all the options with a brief comment to remind you what they do. -d (number) sets the maximum delay to calculate the autocorrelation for; the default is 100. This is delay in samples, independent of the other option, which is -t. -t (number) lets you set a time step so that the output is listed in (time lag, autocorrelation) rather than (sample lag, autocorrelation).
Thus, to generate the graph below, I typed:
If you have questions, please send me email (email address below).
The graph was made with a program I wrote, psdraw. This program is public domain. The program makes PostScript output which I then converted to GIF.