Guest User

Untitled

a guest
Jul 17th, 2018
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. %desired filter length
  2. N = 51;
  3. f = [linspace(-1,-.18,164),linspace(-.1,.3,80),linspace(.38,1,124)];
  4. %frequency grid
  5. d = [zeros(1,164),ones(1,80),zeros(1,124)].*exp(-1i*pi*f*(N-1)/2);
  6. %desired frequency response
  7. w = [10*ones(1,164),ones(1,80),10*ones(1,124)];
  8. A = w(:,ones(1,N)) .* exp(-1i*pi*f*(0:N-1) );
  9. h = A (w.*d);
Add Comment
Please, Sign In to add comment