public class FIRFilter extends Object
FIR (finite impulse response) filter.
To compute the coefficients you might want to use Matlab or the free package Octave (with additional Octave-Forge packages needed for signals). E.g. for a low pass filter you could execute:
b = fir1(16,0.125)
Constructor and Description |
---|
FIRFilter(double[] coefficients) |
Modifier and Type | Method and Description |
---|---|
protected void |
addToDelayLine(double sample) |
static FIRFilter |
createFir1_29thOrderLowpass(int factor)
29th order Fir1 (Matlab/Octave) lowpass filter that lets
factor -th-Nyquist pass (ω=1/factor). |
boolean |
equals(Object o) |
protected double |
filter() |
float[] |
filter(float[] data) |
double[] |
getCoefficients() |
int |
hashCode() |
String |
toString() |
public double[] getCoefficients()
public float[] filter(float[] data)
protected void addToDelayLine(double sample)
protected double filter()
public static FIRFilter createFir1_29thOrderLowpass(int factor) throws IllegalArgumentException
factor
-th-Nyquist pass (ω=1/factor).
Supported factors are 2 to 10.factor
- factorIllegalArgumentException
- if the factor is not supported.Copyright © 2011–2018 tagtraum industries incorporated. All rights reserved.