now i have used kaiserrord command but now its giving error that stop band frequency should be zero.how should i fix it?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
now i have used kaiserrord command but now its giving error that stop band frequency should be zero.how should i fix it?(i-e ??? Error using ==> kaiserord at 81 Stopbands must be zero.Error in ==> kieser at 26 [N,Wn,beta,ftype] = kaiserord(Fc,mags,devs,fsamp);)
following is code with kaiserrord command
As=40;
passbandfreq=0.01;
transitionwidth=500;
fsamp=10000;
Fn=fsamp/2
fc=1200;
fc1=fc+normalizedtransitionwidth/2
fc2=fc-normalizedtransitionwidth/2
Fc1=fc1/Fn
Fc2=fc2/Fn
Fc=[Fc1,Fc2]
fcn=Fc/Fn
mags1=1+passbandfreq
mags2=1-passbandfreq
mags=[mags1,mags2]
normalizedtransitionwidth=500/Fn
passbandfreq=10^(passbandfreq/20)-1
stopbandfreq=10^(-As/20)
delta=min(passbandfreq,stopbandfreq)
A=-20*log10(delta)
N=A-7.95/14.36*normalizedtransitionwidth
%%for A>50dB
beta=0.1102*(A-8.7)
devs = [0.05 0.01];
[N,Wn,beta,ftype] = kaiserord(Fc,mags,devs,fsamp);
hh = fir1(n,Wn,ftype,kaiser(N+1,beta),'noscale');
freqz(hh)
0 Kommentare
Antworten (0)
Siehe auch
Kategorien
Mehr zu Kaiser finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!