1
$\begingroup$

Is there any way I could utilise findpeaks in conjunction with fvtool? I would like to know where on the frequency axis the maximum and minimum of my frequency response happens.

enter image description here

$\endgroup$
1
$\begingroup$

fvtool is interactive so it doesn't let you recover an data in a script. Fortunately you can use the freqz function to get the same frequency response. Something like this might work:

[h,w] = freqz(b,a);  % h is frequency response, w normalized frequency
mag = 20*log10(abs(h));
[minval,minidx] = min(mag);
minfreq = w(minidx); 
[maxval,maxidx] = max(mag);
maxfreq = w(mcxidx);
| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.