Nitin400

FT

Aug 3rd, 2019
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.29 KB | None | 0 0
  1. clear all
  2. close all
  3. clc
  4. w1=-10:0.1:10
  5. t=-10:0.1:10
  6. x=exp(-t)
  7. subplot(1,2,1)
  8. plot(t,x)
  9. m=1
  10. for w=-10:0.1:10
  11.     i=1
  12.     sum=0
  13.     for t=-10:0.1:10
  14.         dt=0.1
  15.         sum=sum+(x(i).*(exp(-j*w*t).*dt))
  16. i=i+1
  17.     end
  18.     X(m)=sum
  19.     m=m+1
  20. end
  21. y1=abs(X)
  22. subplot(1,2,2)
  23. plot(w1,y1
Add Comment
Please, Sign In to add comment