🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: sci.engr.control
Article #14

Question on FFT

#14
From: John Vorwald
Date: Tue, 03 Nov 1992 22:09
30 lines
1261 bytes
Hi

  Can someone explain the relationship between an FFT and an Fourier
Transform.  I am using the FFT command in MatrixX on the following problem:

  x(t) = sin(10*2*Pi*t) + 2*cos(20*2*Pi*t) + 3*sin(30*2*Pi*t)  0 < t < 10.23

and the discrete FFT has magnitudes of 245, 532, and 799 at the 
frequencies 10, 20, and 30 Hz.  If I divide by the number of data points, the
magnitudes drop to .24, .52, and .78.  I would like to recover the magnitudes
of 1, 2, and 3.  Any suggestions, the MatrixX commands are listed below.

J. Vorwald
vorwald@oasys.dt.navy.mil

======================
MatrixX commands
======================
rand('norm');
rand('seed',0);
iend=1024;
tend=10.23;
dt=tend/(iend-1);
t=[0:iend-1]'*dt;
x=sin(10*2*pi*t) ...
  +2*cos(20*2*pi*t) ...
  +3*sin(30*2*pi*t);
xf=fft(x,'hamm')/iend;
hz=[0:iend/2-1]/tend;
plot(hz,abs(xf(1:iend/2)));
Technical Details
Message-ID: <27128@oasys.dt.navy.mil>
Path: arc1-ca.pugleaf.net!sparky!uunet!spool.mu.edu!caen!saimiri.primate.wisc.edu!relay!dtix!oasys!vorwald

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!spool.mu.edu!caen!saimiri.primate.wisc.edu!relay!dtix!oasys!vorwald
From: vorwald@oasys.dt.navy.mil (John Vorwald)
Newsgroups: sci.engr.control
Subject: Question on FFT
Message-ID: <27128@oasys.dt.navy.mil>
Date: 3 Nov 92 22:09:23 GMT
Reply-To: vorwald@oasys.dt.navy.mil (John Vorwald)
Organization: Carderock Division, NSWC, Bethesda, MD
Lines: 30