# Noise cancellation using RLS filter

I am trying to create an adaptive noise canceller using the RLS algorithm. The dsp toolbox from matlab offers the RLS adaptive filter already implemented, so this saved me some trouble.

My goal is to filter out the hearth beat signal from the muscle signal, however, so far I have had zero to no success. After reading a decent amount of articles on the internet, I found out that the adaptive filters are suitable for this purpose as I have a reference signal of the electrocardiogram, which I want to remove. I chose the RLS algorithm, as it converges faster than the LMS algorithm, so it should be the better option. The filter order is set to 60 and the ForgettingFactor is 0.999, which according to multiple sources, should result the removal of the noise signal, however, in my case the hearth beat signal is still significantly noticeable.

From the attached images, you can see that the signal is not filtered. Should I process the signal before using the adaptive filter or is the method wrong (or badly implemented) and I should try something else?

• I don't know whether it'll be useful for anyone but let me restate that the adaptive filters are not just the type of filter & go systems. They require a great deal of fine tuning for succesful applications to any serious real world problem... And fine tuning requires a great deal of dsp engineering expertise... – Fat32 Aug 12 '17 at 11:35
• Can you explain what fine tuning means? I am relatively new to signal processing, so I have little to no knowledge in this area. It may have been naive from my side to think that I can simply use what is given from matlab and just tweak the order and ForgettingFactor parameters until I receive the wanted result. – filtfilt Aug 12 '17 at 11:59
• Fine tuning is an engineering terminology, not specific to dsp. Those two are very fundamental parameters. You can perform a parameter trace to see which combination gives the best result... Expertise relates to problem definition and proposed solution architectures. Anyway, this is a nice problem. In the mean time can you please upload those two signals in Matlab readable form? Lets see the answers... – Fat32 Aug 12 '17 at 12:16
• Well, I have over ten channels, so I am not sure, if I would be able to upload them all. What I find odd, is that the filter works for some of the channels and for others not. Furthermore, if I use a different reference signal, it works almost perfect for all channels. (e.g. if I use a moving weighted window with window size = 7` on my signal to get a reference signal). – filtfilt Aug 12 '17 at 16:10
• ok interesting. Lets see the responses. – Fat32 Aug 12 '17 at 16:43