Skip to main content

band_pass_zero_phase

Function band_pass_zero_phase 

Source
pub fn band_pass_zero_phase(
    samples: &[f64],
    rate: SampleRate,
    lo: Hz,
    hi: Hz,
) -> Result<Vec<f64>, FilterError>
Expand description

Band-passes a signal with a fourth-order Butterworth high-pass at lo and low-pass at hi, each run forward and backward, so the band has no delay.

Both edges get the ends of low_pass_zero_phase: an odd reflection of three periods of lo and steady-state starts.

ยงErrors

Returns a FilterError when an edge is zero or not below the Nyquist frequency.