numra-signal
Digital signal processing for the Numra workspace — IIR (Butterworth, Chebyshev I) and FIR filter design, zero-phase filtering, resampling, Hilbert transform, and peak detection.
Re-exposed at the umbrella level as numra::dsp. SOS filter representation, FFT-based resampling and Hilbert transform (via numra-fft), and peak detection with height / distance / prominence constraints.
Example
use ;
// Design a 4th-order Butterworth lowpass at 10 Hz, sampled at 100 Hz
let sos = butter.unwrap;
// Generate a noisy 3-Hz signal contaminated with 40-Hz noise
let pi2 = 2.0 * PI;
let x: = .map.collect;
// Zero-phase filter and detect peaks
let y = filtfilt;
let peaks = find_peaks;
assert!;
What's in this crate
- Filter design:
butter(Butterworth),cheby1(Chebyshev Type I) — both return second-order-section coefficients - FIR design:
fir_filter,firwin(windowed-sinc) - Filter application:
sosfilt(forward),filtfilt(zero-phase forward-backward),SosFilter - Resampling:
resample(FFT-based, non-integer ratios) - Hilbert transform:
hilbert(analytic signal),envelope,instantaneous_frequency - Peak detection:
find_peakswithPeakOptions(height, distance, prominence) SignalError— DSP-specific error reporting
Composes with
numra-fft— FFT backbone forresample,hilbert, and convolution-based filteringnumra-ode— peak detection on time-domain ODE solutionsnumra-sde— filtering noisy SDE realizations before peak detectionnumra-stats— descriptive statistics on detected peak heights and inter-peak spacings
See interop workflows for the verified ODE → FFT → signal-processing → peak-detection workflow.
Install
[]
= "0.1"
Or via the umbrella crate (re-exported as numra::dsp):
[]
= "0.1"
Documentation
- API: https://docs.rs/numra-signal
- Book: Filtering signals · Filter design · Hilbert transform · Resampling and peaks
- Source: https://github.com/moussaoutlook/numra-rs/tree/main/numra-signal
License
Numra Academic & Research License (Non-Commercial). Academic and research use is free; commercial use requires a separate license — contact contact@spectralautomata.com. See LICENSE.