matriz 0.0.2

Zero allocation Rust linear algebra library
Documentation
  • Coverage
  • 11.11%
    1 out of 9 items documented1 out of 1 items with examples
  • Size
  • Source code size: 40.34 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 2.99 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 13s Average build duration of successful builds.
  • all releases: 13s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • reu/matriz
    3 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • reu

Matriz

Typesafe and simple linear algebra library, with no-std support.

Disclaimer: this library is intendend for educational porpouses. For production grade implementations just go with nalgebra.

Usage

Key feature is that matrices dimensions are encoded on the type, and transformations generate proper typed results.

use matriz::Matrix;

#[rustfmt::skip]
let m1 = Matrix::from_rows([
    [1, -2, 4],
    [5,  0, 3],
]);

#[rustfmt::skip]
let m2 = Matrix::from_rows([
    [ 1],
    [ 5],
    [-1],
]);

let output = Matrix::from_rows([
    [-13],
    [  2],
]);

assert_eq!(m1 * m2, output);