single_canceler.m
上传用户:szahd2008
上传日期:2020-09-25
资源大小:1275k
文件大小:0k
- function [resp] = single_canceler (fofr1)
- eps = 0.00001;
- fofr = 0:0.01:fofr1;
- arg1 = pi .* fofr;
- resp = 4.0 .*((sin(arg1)).^2);
- max1 = max(resp);
- resp = resp ./ max1;
- subplot(2,1,1)
- plot(fofr,resp,'k')
- xlabel ('Normalized frequency - f/fr')
- ylabel( 'Amplitude response - Volts')
- grid
- subplot(2,1,2)
- resp=10.*log10(resp+eps);
- plot(fofr,resp,'k');
- axis tight
- grid
- xlabel ('Normalized frequency - f/fr')
- ylabel( 'Amplitude response - dB')