Solving wiener hopf equation for optimal filter coefficients

28 ビュー (過去 30 日間)
Randy82
Randy82 2013 年 6 月 30 日
Hello @all!
I hope you can help me about my problem. I coded some program to estimate the filter-coefficients of an unknown system, e.g. that has 6 filter-coefficients. There are a lot of algorithms to estimate this coefficients like LMS and whatever.
But now, I would like to get the optimal coefficients through solving the wiener hopf equation. That works with an estimate of the autocorrelation-matrix (e.g. i would get it through corrmtx in MATLAB) and the cross-correlation-vector. For getting the cross-correlation vector I must use "xcorr".
And there, there is my question about: Over how many lags do i have to use xcorr? I've got a white noise signal as input for my unknown system. When I chose my lag as same as number of filter-coefficients i got a 6x6 autocorrelation matrix and a 6 length cross-correlation vector. When I use them in the wiener hopf equation I got not the optimal filter coefficients...

回答 (3 件)

Pourya Alinezhad
Pourya Alinezhad 2013 年 6 月 30 日
編集済み: Pourya Alinezhad 2013 年 6 月 30 日
the problem you are facing is how to choose the length of the filter M. in the absence of a priori information ,we compute the optimal coefficients ,starting from a small reasonable number.As you increase the number,you check the MMSE (minimum mean square error) ,and if it's value is small enough ,e.g,MMSE<0.01, we accept the corresponding number of the coefficients. :)
  1 件のコメント
Pourya Alinezhad
Pourya Alinezhad 2013 年 6 月 30 日
編集済み: Pourya Alinezhad 2013 年 6 月 30 日
also notice that length of X(t) (input to filter) is assumed to be infinite.but you have to provide enough data at input. obviously with a 6 tap filter you will have first output signal with 6 input samples. for more info take a look at "Adaptive_Filtering_Matlab_Poularikas" chapter 4 :wiener filters you can also find good information in "Adaptive filters theory and applications" by farhang-broujeny.

サインインしてコメントする。


Randy82
Randy82 2013 年 6 月 30 日
Ok, i can follow so far... Normally, I would have no a priori information for estimating an unknown system, there you are right.
At the moment, I estimate the system by an adaptive (LMS) algorithm. As I know, that my unknown filter has exactly 6 coefficients, I set my lenght M to 6. There I can see how the coefficients are adapting.
But what do I do then with the so called optimum Wiener filter coefficients...? Where are they then good for if I not know the length of my filter? For calculating the wiener solution I need the autocorrelation matrix of my input. I found out, that my autocorrelation matrix is exactly 6x6 if I only let calculate with 6 lags...But with 6 lags of my input signal I get a very bad solution... Is there a recommended lag size for calculating the autocorrelation?
Would increasing the number of filter coefficients and than check the MMSE the same way for noise cancellation?
  4 件のコメント
Pourya Alinezhad
Pourya Alinezhad 2013 年 7 月 1 日
exactly.and if you choose lags=7 then one of them will be zero. if you set lags=5 then it will be an estimate of the main system.
Randy82
Randy82 2013 年 7 月 1 日
Ok, than "lags" in the autocorrelation is an amount of how many samples the signal x(t) is shifted over itself? So therefore I normally get rxx(0) = 1 if i use white noise, because only when the signal lays over itself it will be maximum equal with itself...
In my program I do not get zeros when I increase the lag size...I do:
b = [0.3, 0.05, 0.1, 0.5, 1.5, 4]; a = [1]; x is randn(1,10000) and d is filter(b,a,x)
Now, when I calculate xcorr with e. g. 15 lags xcorr(x, x, 15, 'biased'); , I do not get any zeros in my autocorrelation-function... I seems, that I do not understand that really.
Whit understanding this so far I tried the example on page 25. There I get the autocorrelation function. But then, on page 39 in example 3.7.1 there is the autocorrelation matrix built with R = toeplitz(rx(1, 1:6). Thats not the same as i use corrmtx(rx,6).

サインインしてコメントする。


Randy82
Randy82 2013 年 6 月 30 日
I looked in Chapter 4... And there are some examples for 2 taps, e. g. example 4_3_1. The autocorrelation function there is calculated with a function called "aasamplebiasedautoc". Is that the same as I would use xcorr(x,x,'biased')? And then, the crosscorrelation is calculated with matlab "xcorr". But why is then the crosscorrelationvector only the 19th and 20th element?
  2 件のコメント
Pourya Alinezhad
Pourya Alinezhad 2013 年 6 月 30 日
編集済み: Pourya Alinezhad 2013 年 7 月 1 日
for asamplebiasedautoc function you can use what you mentioned:xcorr(x,x,'biased') . it will work correctly as you can find in page 25 of the aforesaid book.
Pourya Alinezhad
Pourya Alinezhad 2013 年 6 月 30 日
and we just use 19 and 20 element because we have tow tap weights.... w=R/rdx; MATRIX DIMINUTIONS AND SIZES MUST AGREE.

サインインしてコメントする。

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by