Skip to main content

generate_centered_sinc

Function generate_centered_sinc 

Source
pub fn generate_centered_sinc(n: usize, cut_off: f64) -> Vec<f64>
Expand description

n samples of sinc(cut_off · t) (or of the normalised sinc for generate_centered_sinc_normalized) at points t spaced 1/n apart and centred on zero, so t spans about [−1/2, 1/2]. The result is a smooth taper whose width depends on cut_off (for cut_off ≤ 2 every value is positive), used as a smoothing kernel; it is not the impulse response of a low-pass filter with that cutoff, for which see firwin.