home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 10 / 10.iso / l / l460 / 3.ddi / DEMOS.DI$ / TFFUNC.M < prev    next >
Encoding:
Text File  |  1993-03-07  |  412 b   |  13 lines

  1. function [t,f,w,F] = tffunc(amp,freq)
  2. %TFFUNC    time and frequency domain versions of a cosine modulated Gaussian pulse.
  3. %    For use in Signal demo 2.
  4.  
  5. %    Author: L. Shure
  6. %    (c) Copyright 1984-93, by The MathWorks, Inc.
  7.  
  8.     sigma = 1;
  9.     t = -1:.01:1;
  10.     f = amp*cos(2*pi*freq*t).*exp(-pi*(sigma*t).^2);
  11.     w = -8:.1:8;
  12.     F = 2*sigma*amp*(exp(-pi*((w-freq)/sigma).^2)+exp(-pi*((w+freq)/sigma).^2));
  13.