How to choose the appropriate low pass filter?
13 views (last 30 days)
Show older comments
I am working on a project in which I have obtained the following readings from the accelerometer in the form of three columns (x,y,z):
0 0 0
-0.2 1.3 -0.3
-0.3 2.7 -0.5
-0.5 4 -0.8
-0.4 4.1 -0.8
-0.4 4.1 -0.8
-0.4 4.1 -0.8
-0.4 4 -0.8
-0.4 4 -0.8
-0.5 4.1 -0.7
-0.5 4.1 -0.7
-0.4 4.1 -1
-0.8 4.4 -1.1
On these readings I did normalization by using x1=x/sqrt(g*height of person).
Therefore a new matrix was now obtained as (x1,y1,z1). Now I have to pass it through the low pass filter to remove the noise. But I am not able to decide which filter to use and how to select the parameters of the filter (i.e order, fs,fc). I am using fdatool for the filter design. Can anyone help me out?
0 Comments
Accepted Answer
Daniel kiracofe
on 18 Jul 2014
if you are new to filtering, and just want a simple low pass filter to remove noise, then start with a butterworth filter. It may not be the best, but it is easy to use. 4th order a is pretty good start.
Cutoff frequency depends on what you care about. i.e. what kind of noise you are trying to remove, how far away it is from the signal, what the signal looks like, etc. I'd suggest you just pick something, run it, and then plot the output versus your input data and see if it looks like what you want. If not, then try a different cutoff frequency.
0 Comments
More Answers (1)
Star Strider
on 18 Jul 2014
I did my best about a week ago in my answer to What is the MATLAB code for applying a low pass filter on the readings of accelerometer and gyroscope in a sensor tag?, but you didn’t reply to my comment.
I need your help in deciding what part of your signal you want to work with and what part is noise, and what your sampling frequency is. I don’t know enough about your experimental conditions to make those decisions myself.
See Also
Categories
Find more on Filter Analysis in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!