windowfunctions 0.1.0

Common window functions for apodization
Documentation
  • Coverage
  • 94.74%
    18 out of 19 items documented2 out of 5 items with examples
  • Size
  • Source code size: 32.59 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.73 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Links
  • Repository
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • HEnquist

WindowFunctions

Window functions for apodization.

Overview

The WindowFunctions library provides a variety of window functions used in signal processing to reduce spectral leakage. These window functions are essential for applications like spectrum analysis and filter design, where improving the frequency characteristics of the signal is crucial.

Example, print all the values from the window iterator

extern crate windowfunctions;
use windowfunctions::{WindowFunction, Symmetry, window};

fn main() {
    let length = 1024;
    let window_type = WindowFunction::Hamming;
    let symmetry = Symmetry::Symmetric;

    let window_iter = window::<f32>(length, window_type, symmetry);

    for value in window_iter {
        println!("{}", value);
    }
}

Example, store the window in a vector

extern crate windowfunctions;
use windowfunctions::{WindowFunction, Symmetry, window};

fn main() {
    let length = 1024;
    let window_type = WindowFunction::Hamming;
    let symmetry = Symmetry::Symmetric;

    let window_iter = window::<f32>(length, window_type, symmetry);

    let window_vec: Vec<f32> = window_iter.into_iter().collect();
}

License

This library is licensed under the MIT License. See the LICENSE file for more details.

Contributions

Contributions are welcome! Feel free to open issues or submit pull requests on the GitHub repository.