Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stateful FIRFilter #459

Open
TacHawkes opened this issue Feb 18, 2022 · 1 comment
Open

Stateful FIRFilter #459

TacHawkes opened this issue Feb 18, 2022 · 1 comment

Comments

@TacHawkes
Copy link

I am having troubles setting up the stateful FIRFilter with the information given in the docs.
How can I properly construct a FIRFilter from a designed filter using e.g. Lowpass and design method Butterworth? Could someone provide an example?

Thanks!

@martinholters
Copy link
Member

Butterworth yields an IIR filter, but FIRFilter is for FIR filters, as the name suggests. You can use remez to design an FIR filter. E.g.:

h = remez(100, [(0, 0.45) => 1, (0.55, 1) => 0]; Hz=2)
H = FIRFilter(h)
y = filt(H, x) # for whatever input x

Better documentation would obviously be welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants