Go back to previous page
Forum URL: http://www.cut-the-knot.org/cgi-bin/dcforum/forumctk.cgi
Forum Name: College math
Topic ID: 562
Message ID: 1
#1, RE: spectral analysis question
Posted by alexb on Mar-11-06 at 10:21 AM
In response to message #0
Have you tried to plot the function itself?

The problem my be in what Matlab sees when you tell it the function is a sine. There are at least three ways to extend the sine defined in half the usual period for positive t to the negative domain: making it either even or odd or zero. You'll get different spikes in the Fourier transform for each of the three.

I have a hunch that you problem has something to do with setting

dt = 0.002.

Have you tried dt = 0.001?

Also, why did not you take N = 512?