Saturday, September 21, 2019

Mathematical Proof of Complementary Filter?


Having found some unofficial sources on Complementary Filter (Thousand Thoughts Sensor Fusion and The Balance Filter by Shane Colton), I wish to work out its rigorous mathematical proof.


The Complementary Filter, $$y=\alpha \times y+(1-\alpha) \times x$$ where $\alpha$ is the filter parameter, usually chosen to be ~0.98, is named as such, because effectively the filter highpasses $y$ and lowpasses $x$.


With this setup ($\alpha=0.98$), man claims that the filter can filter out the low-frequency part of $y$ and meanwhile the high-frequency part of $x$.


What is the mathematical proof here?



There is no rigorous proof so far available. All the sources simply take it as granted and validates it with experiment data, which is unacceptable in scientific validation.



Answer



This is a first order, low pass infinite impulse response filter (IIR). It is some times called the exponentially weighted moving average. You can find the derivation on Wikipedia. Orfanidis' Introduction to Signal Processing gives a nice description as well.


Picture from Orfanidis, page 573.


Don't think of it as high passing y and low passing x, this will lead to confusion. It is weighting y more heavily than x, the consequence is short time variations of x have a small effect on y, therefore removing higher frequencies.


Also looking at your other questions, it appears that you think that this is a high pass filter as well. This is not the case. α is valid from 0 to 1, so you can see that you will get a lot of low pass filtering (High time constant, limited by your digital precision) or no filtering where y = x ( In the case of x = 0). Read up on high pass filters if you need one, wikipedia gives the difference equation (you have provided the low pass one) for a single order high pass filter.


No comments:

Post a Comment

digital communications - Understanding the Matched Filter

I have a question about matched filtering. Does the matched filter maximise the SNR at the moment of decision only? As far as I understand, ...