|
Arduino Filters
master
Filter library for Arduino
|
Filter design tools.
Collaboration diagram for Filter Design:Functions | |
| template<uint8_t N, class T = float> | |
| SOSCoefficients< T,(N+1)/2 > | butter_coeff (double f_n, bool normalize=true) |
| Compute Butterworth filter coefficients. More... | |
| template<uint8_t N, class T = float, class Implementation = BiQuadFilterDF1<T>> | |
| SOSFilter< T,(N+1)/2, Implementation > | butter (double f_n, bool normalize=true) |
| Create a Butterworth filter, implemented as Second Order Sections (SOS) filter. More... | |
| template<class T = float> | |
| FIRFilter< 3, T > | simpleNotchFIR (double f_n) |
| Create a very simple second-order FIR notch filter. More... | |
| template<class T , size_t N> | |
| TransferFunction< N *2+1, N *2+1, T > | sos2tf (const SOSCoefficients< T, N > &sos) |
| Convert Second Order Section (SOS) coefficients to an equivalent tranfer function representation. More... | |
| SOSCoefficients< T,(N+1)/2 > butter_coeff | ( | double | f_n, |
| bool | normalize = true |
||
| ) |
Compute Butterworth filter coefficients.
| N | Order of the filter. |
| f_n | Normalized cut-off frequency in half-cycles per sample. \( f_n = \frac{2 f_c}{f_s} \in \left[0, 1\right] \), where \( f_s \) is the sample frequency in \( \text{Hz} \), and \( f_c \) is the cut-off frequency in \( \text{Hz} \). |
| normalize | If true, normalize all coefficients such that \( a_0 = 1 \). |
| T | The type of the coefficients. |
Definition at line 26 of file Butterworth.hpp.
| SOSFilter< T,(N+1)/2, Implementation > butter | ( | double | f_n, |
| bool | normalize = true |
||
| ) |
Create a Butterworth filter, implemented as Second Order Sections (SOS) filter.
| N | Order of the filter. |
| f_n | Normalized cut-off frequency in half-cycles per sample. \( f_n = \frac{2 f_c}{f_s} \in \left[0, 1\right] \), where \( f_s \) is the sample frequency in \( \text{Hz} \), and \( f_c \) is the cut-off frequency in \( \text{Hz} \). |
| T | The type of filter values and coefficients. |
| normalize | If true, normalize all coefficients such that \( a_0 = 1 \). |
| Implementation | The BiQuad implementation to use. |
Definition at line 109 of file Butterworth.hpp.
| FIRFilter< 3, T > simpleNotchFIR | ( | double | f_n | ) |
Create a very simple second-order FIR notch filter.
\[ H(z) = \frac{z^2 - 2\cos\left(\omega_{c,d}\right)z + 1} {2 - 2\cos\left(\omega_{c,d}\right)} \]
where \( \omega_{c,d} = \pi f_n = 2\pi \frac{f_c}{f_n} \)
| f_n | Normalized notch frequency in half-cycles per sample. \( f_n = \frac{2 f_c}{f_s} \in \left[0, 1\right] \), where \( f_s \) is the sample frequency in \( \text{Hz} \), and \( f_c \) is the analog notch frequency in \( \text{Hz} \). |
| TransferFunction< N *2+1, N *2+1, T > sos2tf | ( | const SOSCoefficients< T, N > & | sos | ) |
Convert Second Order Section (SOS) coefficients to an equivalent tranfer function representation.
Definition at line 76 of file SOSFilter.hpp.