From: Greg Heath on
On Jun 17, 8:58 am, "Peng Liang" <madokaauk...(a)hotmail.com> wrote:
>
-----SNIP
> clear;
> fs = 8000;
> t = [0.000125:1/fs:1];

I repeat:

%Not consistent with

t = dt*(0:N-1); % dt = 1/fs
t = 0:dt:T-dt; % T = N*dt
t = linspace(0,T-dt,N);

Therefore, your transform will have an
unintentional phase shift.

Hope this helps.

Greg
From: Peng Liang on
Greg Heath <heath(a)alumni.brown.edu> wrote in message <ec4a7003-481b-4b5e-b8f0-ed24a43130fa(a)3g2000vbf.googlegroups.com>...
> On Jun 17, 8:58 am, "Peng Liang" <madokaauk...(a)hotmail.com> wrote:
> >
> -----SNIP
> > clear;
> > fs = 8000;
> > t = [0.000125:1/fs:1];
>
> I repeat:
>
> %Not consistent with
>
> t = dt*(0:N-1); % dt = 1/fs
> t = 0:dt:T-dt; % T = N*dt
> t = linspace(0,T-dt,N);
>
> Therefore, your transform will have an
> unintentional phase shift.
>
> Hope this helps.
>
> Greg

Thank you, Greg and Wayne.

Its grateful to have you guys helps.