#2, RE: spectral analysis question
Posted by alan on Mar-11-06 at 12:44 PM
In response to message #1
The function doesn't seem to care whether N is a power of two or not, and when I change it to 512 there isn't any discernible difference. Changing dt to .001 just changes the scale of the frequency axis, and the three spikes go to 1000-50, 1000-75, 1000-125. The signal function itself looks as I expect it to look. For a signal sin(f*t), this algorithm should produce a spike at +f and -f, correct? I think those three spikes must be the negative frequencies, plotted in the wrong place somehow. Either that or a sampling artifact, but they remain no matter what the sample rate is.
|