|
use freqz() to view the frequency response of your filter. That's how
you'll know if is good or not. Try changing the filter order and see
how that affects the magnitude and phase response. Also you might
compare fir1() to butter() or ellip() or other IIR filters to
determine if you really want an FIR or IIR filter.
I'm not an expert on FIR filters, but I think that a very large
filter order won't have much negative effect except that the
computation time will be increased. The coefficients with very high
delays should end up being very small (which is the whole
justification for being able to use FIR in the first place). Having
too small of a filter order will give you problems.
On Aug 19, 6:05 pm, "Tyler " <tyler.r...@seagate.com.remove> wrote:
> I have laser displacement data measuring vibrations (3s at 4000hz). I want to apply a high-pass filter (>2hz) to reduce noise that I know is related to other things not of interest. I've been doing this as follows
>
> flt = fir1(1000,2/2000,'high');
> dataFilt = filtfilt(flt,1,data);
>
> The resulting FFT spectrum looks as expected but I'm unsure of what filter order I should be using, e.g. data fitting with a higher order function always fits the sampled data better than low order functions but isn't necessarily the best description of the physics....am I doing that here and fooling myself with such a high filter order? Are there other side effects of higher order?
>
> My main output is to compare relative vibration levels at different points on the machine (for measurement and placement accuracy).
>
> Tyler
|