![]() |
LASP 1.0
Library for Acoustic Signal Processing
|
Author: J.A. More...
Functions | |
| peaking (fs, f0, Q, gain) | |
| Design of peaking biquad filter. | |
| notch (fs, f0, Q, gain=None) | |
| Notch filter, parameter gain not used. | |
| lowpass (fs, f0, Q, gain=None) | |
| Second order low pass filter, parameter gain not used. | |
| highpass (fs, f0, Q, gain=None) | |
| Second order high pass filter, parameter gain not used. | |
| highshelf (fs, f0, Q, gain) | |
| High shelving filter. | |
| lowshelf (fs, f0, Q, gain) | |
| Low shelving filter. | |
| LP1compensator (fs, f0o, f0n) | |
| Shelving type filter that, when multiplied with a first-order low-pass filter, alters the response of that filter to a different first-order low-pass filter. | |
| LP2compensator (fs, f0o, Qo, f0n, Qn) | |
| Shelving type filter that, when multiplied with a second-order low-pass filter, alters the response of that filter to a different second-order low-pass filter. | |
| HP1compensator (fs, f0o, f0n) | |
| Shelving type filter that, when multiplied with a first-order high-pass filter, alters the response of that filter to a different first-order high-pass filter. | |
| HP2compensator (fs, f0o, Qo, f0n, Qn) | |
| Shelving type filter that, when multiplied with a second-order high-pass filter, alters the response of that filter to a different second-order high-pass filter. | |
| biquadTF (fs, freq, sos) | |
| Computes the transfer function of the biquad. | |
Author: J.A.
de Jong - ASCEE V.O.F.
Description: Filter design implementation of common biquad filters that are often used in parametric equalizers.
Major source is Audio EQ Cookbook: https://archive.is/20121220231853/http://www.musicdsp.org/ files/Audio-EQ-Cookbook.txt
The definition of the BiQuad filter coefficients as coming out of these functions defines the filter as:
y[n] = 1/ba[3] * ( ba[0] * x[n] + ba[1] * x[n-1] + ba[2] * x[n-2] +
Note that all filters are normalized such that ba[3] is by definition equal to 1.0!
| lasp.filter.biquad.biquadTF | ( | fs, | |
| freq, | |||
| sos | |||
| ) |
| lasp.filter.biquad.highpass | ( | fs, | |
| f0, | |||
| Q, | |||
gain = None |
|||
| ) |
| lasp.filter.biquad.highshelf | ( | fs, | |
| f0, | |||
| Q, | |||
| gain | |||
| ) |
| lasp.filter.biquad.HP1compensator | ( | fs, | |
| f0o, | |||
| f0n | |||
| ) |
Shelving type filter that, when multiplied with a first-order high-pass filter, alters the response of that filter to a different first-order high-pass filter.
Args: fs: Sampling frequency [Hz] f0o: Cut-on frequency of the original filter [Hz]
f0n: Desired cut-on frequency [Hz]
| lasp.filter.biquad.HP2compensator | ( | fs, | |
| f0o, | |||
| Qo, | |||
| f0n, | |||
| Qn | |||
| ) |
Shelving type filter that, when multiplied with a second-order high-pass filter, alters the response of that filter to a different second-order high-pass filter.
Args: fs: Sampling frequency [Hz] f0o: Cut-on frequency of the original filter [Hz] Qo: Quality factor of the original filter (~inverse of bandwidth) f0n: Desired cut-on frequency [Hz] Qn: Desired quality factor(~inverse of bandwidth)
| lasp.filter.biquad.lowpass | ( | fs, | |
| f0, | |||
| Q, | |||
gain = None |
|||
| ) |
| lasp.filter.biquad.lowshelf | ( | fs, | |
| f0, | |||
| Q, | |||
| gain | |||
| ) |
| lasp.filter.biquad.LP1compensator | ( | fs, | |
| f0o, | |||
| f0n | |||
| ) |
Shelving type filter that, when multiplied with a first-order low-pass filter, alters the response of that filter to a different first-order low-pass filter.
Args: fs: Sampling frequency [Hz] f0o: Cut-off frequency of the original filter [Hz]
f0n: Desired cut-off frequency [Hz]
| lasp.filter.biquad.LP2compensator | ( | fs, | |
| f0o, | |||
| Qo, | |||
| f0n, | |||
| Qn | |||
| ) |
Shelving type filter that, when multiplied with a second-order low-pass filter, alters the response of that filter to a different second-order low-pass filter.
Args: fs: Sampling frequency [Hz] f0o: Cut-off frequency of the original filter [Hz] Qo: Quality factor of the original filter (~inverse of bandwidth) f0n: Desired cut-off frequency [Hz] Qn: Desired quality factor(~inverse of bandwidth)
| lasp.filter.biquad.notch | ( | fs, | |
| f0, | |||
| Q, | |||
gain = None |
|||
| ) |