{"id":35004498,"url":"https://github.com/domohuhn/filter","last_synced_at":"2026-05-04T17:31:14.582Z","repository":{"id":204987261,"uuid":"500200897","full_name":"domohuhn/filter","owner":"domohuhn","description":"Design and use digital filters with multiple programming languages.","archived":false,"fork":false,"pushed_at":"2026-03-11T20:14:27.000Z","size":1642,"stargazers_count":1,"open_issues_count":2,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-03-12T00:10:12.443Z","etag":null,"topics":["c","cpp","embedded","fir-filters","iir-filters","javascript"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/domohuhn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2022-06-05T20:09:10.000Z","updated_at":"2026-03-11T20:14:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"badaa35e-71d8-481a-8e9f-0aacccd72905","html_url":"https://github.com/domohuhn/filter","commit_stats":null,"previous_names":["domohuhn/filter"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/domohuhn/filter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/domohuhn%2Ffilter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/domohuhn%2Ffilter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/domohuhn%2Ffilter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/domohuhn%2Ffilter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/domohuhn","download_url":"https://codeload.github.com/domohuhn/filter/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/domohuhn%2Ffilter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32617610,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-04T10:08:07.713Z","status":"ssl_error","status_checked_at":"2026-05-04T10:08:02.005Z","response_time":58,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c","cpp","embedded","fir-filters","iir-filters","javascript"],"created_at":"2025-12-27T04:31:17.233Z","updated_at":"2026-05-04T17:31:14.576Z","avatar_url":"https://github.com/domohuhn.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Filter library for C\n\n[![Build Desktop](https://github.com/domohuhn/filter/actions/workflows/build-desktop.yml/badge.svg)](https://github.com/domohuhn/filter/actions/workflows/build-desktop.yml)\n[![codecov](https://codecov.io/gh/domohuhn/filter/branch/main/graph/badge.svg?token=29BG0GTON3)](https://codecov.io/gh/domohuhn/filter)\n\nThis repository contains a C-library that can be used to both design digital filters, as well as use them.\nThe library also provides bindings to various other programming languages, like C++ and Javascript via emscripten.\n\nYou can try out the library [online on github pages](https://domohuhn.github.io/filter/design_filter.html).\n\nThe following filter types are supported:\n\n| Name     |      Type     | Characteristics | Examples \n|----------|:-------------:|:-------------:|------------\n| Moving average | FIR     | lowpass, highpass | n/a\n| exponential    | FIR     | lowpass | n/a\n| exponential    | IIR     | lowpass | n/a\n| butterworth    | IIR     | lowpass, highpass, bandpass, bandstop | n/a\n| chebyshev (type 1)    | IIR     | lowpass, highpass, bandpass, bandstop | n/a\n| chebyshev (type 2)    | IIR     | lowpass, highpass, bandpass, bandstop | n/a\n| brickwall    | FIR     | lowpass, highpass, bandpass, bandstop | n/a\n\nThe filters are designed using the bilinear z-transform.\nIn broad terms, you start with the frequency response of the analog filter and compute its poles and zeros. These values are transformed via a bilinear z-transform and expanded into a polynomial. The polynomial is normalized for gain 1 at 0 or the middle of the pass band.\nHere is a [Presentation](https://spinlab.wpi.edu/courses/ece503_2014/10-3bilinear_transform.pdf) explaining the process.\n\n[MIT Signal processing continuous and discrete course](https://ocw.mit.edu/courses/2-161-signal-processing-continuous-and-discrete-fall-2008/pages/lecture-notes/)\n\n## Build and run\n\nHere is a quick start on how to build the code in this repo. On linux systems, you should be able to copy these command into bash.\n```bash\ngit clone https://github.com/domohuhn/filter.git\nmkdir -p filter/build\ncd filter/build\ncmake -DCMAKE_BUILD_TYPE='Release' ..\ncmake --build .\n# run the unit tests\nctest\n# use the example program to design a chebyshev bandstop\n# -o: order 4\n# -c: cutoff 15 hz and 35 Hz\n# -s: sampling rate 100 Hz\n# -r: ripple 3 dB\n# -g: generate graphs\n./design-filter -p chebyshev -t bandstop -o 4 -c 15,35 -s 100 -r -3 -g \n```\n\n## Documentation\n\nThe API Documentation is generated with doxygen and can read online on [github pages](https://domohuhn.github.io/filter/).\n\n## License\nAll code in this repository is licensed with the MIT license, see file \"LICENSE\".\n\n## Dependencies\n\nThe library itself has no dependencies. However the tests, examples and documentation have the following dependencies:\n\n - [Catch 2](https://github.com/catchorg/Catch2) is used for the test cases.\n - [cxxopts](https://github.com/jarro2783/cxxopts) parses the command line options in the examples.\n - [Doxygen Awesome](https://github.com/jothepro/doxygen-awesome-css) for the css styles of the api documentation.\n - [Chart.js](https://www.chartjs.org/) to render the graphs in the documentation.\n\n## Issues\n\nPlease report issues and bugs using the [issue tracker](https://github.com/domohuhn/filter/issues).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdomohuhn%2Ffilter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdomohuhn%2Ffilter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdomohuhn%2Ffilter/lists"}