Code covered by the BSD License  

Highlights from
DFiltNyquist

image thumbnail
from DFiltNyquist by Peter Kabal
DFiltNyquist designs Nyquist (M'th band) filters

tDFiltNyquist (LogFile)
function tDFiltNyquist (LogFile)

% $Id: tDFiltNyquist.m,v 1.4 2011/07/20 15:32:46 pkabal Exp $

addpath('..');
addpath('../../DFiltFIR');

if (nargin == 0)
  LogFile = [];
end
CheckDiaryFile = StartDiaryFile(LogFile, 'tDFiltNyquist.ref');

fprintf('==================================\n');
fprintf('NYQ01\n');
clear B
SFreq = 16000;
M = 2;
NCof = 15;
B.Freq   = [4500 8000];
B.Weight = [1, 10];
h = DFiltNyquist(M, NCof, B, SFreq);
PrMatrix(h');
freqz(h, 1);

fprintf('==================================\n');
fprintf('NYQ02\n');
clear B
SFreq = 8000;
M = 2;
NCof = 17;
B.Freq   = [2250 4000];
B.Weight = [1, 10];
h = DFiltNyquist(M, NCof, B, SFreq);
PrMatrix(h');

% ----------
CheckDiaryFile();

return

Contact us at files@mathworks.com