Advertisement
Guest User

aoizdjoijdsfpoqskdfmlkpok kekekekeke

a guest
Apr 29th, 2016
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. fE = 20000;
  2. tMax = 1;
  3.  
  4. n = fE*tMax;
  5.  
  6. t = (0:n-1)/fE;
  7.  
  8. s = 3;
  9. m = 0;
  10.  
  11. r = 3 * randn(1, n) + m;
  12.  
  13. % figure(1);
  14. % plot(r);
  15. %
  16. % figure(2)
  17. % hist(r);
  18. %
  19. % m = mean(r); disp(m);
  20. % s = std(r); disp(s);
  21.  
  22. % cor = xcorr(r); plot(cor);
  23.  
  24. f = fE*(0:n)/n;
  25.  
  26. h = 0.05 * f / (f - 0.95);
  27.  
  28. ft = abs(fft(r)) .* h;% plot(t, ft);
  29.  
  30. r2 = fft(ft);
  31.  
  32. figure(3);
  33. clf;
  34. plot(t, r);
  35. hold on;
  36. %plot(t, r2, 'r');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement