Advertisement
Guest User

Untitled

a guest
Jan 18th, 2019
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.33 KB | None | 0 0
  1. clc
  2. close all
  3. clear all
  4.  
  5. phi=20 ;%en degrés
  6. rau=0.9;
  7. N=100;
  8. noise=normrnd(0,1,1,N);
  9.  
  10. a1=-2*cosd(phi)*rau;
  11. a2=rau^2;
  12. %filterAR = filt(1,[1,a1,a2]); % Le filtre AR
  13. traj=zeros(1,N);
  14. for k =3:N
  15.     traj(k)=noise(k)-a1*traj(k-1)-a2*(traj(k-2));
  16. end
  17.  
  18. %filterAR;
  19. plot(traj) % Affichage de trajectoire
  20. hold on
  21. figure
  22. plot(noise)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement