Am I using yulewalk() correctly?
3 ビュー (過去 30 日間)
古いコメントを表示
I am trying to figure out if I am using the yulewalk function (signal processing toolbox) correctly.
In a basic example, I try to find the filter coefficients of a filter previously generated with MatLAB. I would expect yulewalk to generate a filter that exactly matches the original filter.
% Generate second-order Butterworth filter
[Bx, Ax]=butter(2, 0.13)
% Calculate frequency and magnitude vectors
[H, F]=freqz(Bx, Ax, 0:0.01:1, 2);
% Use yulewalk to generate a filter that should match Bx and Ax
[B, A] = yulewalk(2, F, abs(H))
However, [B, A] is completely different from [Bx, Ax].
Other, similar functions (invfreqz, stmcb) generate a filter that exacly matches the original, but they either work with complex amplitudes (invfreqz) or in the time domain (stmcb).
Is this a limitation of the Yule-Walker algorithm, or am I using the yulewalk function incorrectly?
0 件のコメント
回答 (1 件)
Michael Abboud
2016 年 9 月 27 日
The Yule-walker filter design does not use phase information for the design of the filter, so filters with different coefficients could give you the same magnitude response, but different phase and amplitude.
Also, order 2 is a rather low for such a system, and will likely lead to a rough approximation of the coefficients. However if you increase the order, e.g [B, A] = yulewalk(10, F, abs(H)); then you will obtain a response that has a very similar magnitude to the original system.
If you have any further questions, feel free to contact MathWorks Technical Support and somebody can work with you more closely about your specific use case.
参考
カテゴリ
Help Center および File Exchange で Spectral Measurements についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!