$ account dimforge
nalgebra is a high-performance linear algebra library for Rust, providing generic static and dynamic matrices/vectors, geometric transformations (rotations, isometries, quaternions, dual quaternions), and a comprehensive set of matrix decompositions (LU, QR, Cholesky, SVD, eigenvalue, Schur, Hessenberg, and more) implemented in pure Rust or backed by LAPACK via the nalgebra-lapack subcrate. The core library emphasizes type-safe dimensions at compile time, generic storage abstractions that support stack-allocated, heap-allocated, and view-based memory, and SIMD acceleration through the simba crate. Additional subcrates extend functionality: nalgebra-sparse handles CSR/CSC/COO sparse matrix formats with operations and IO (Matrix Market), nalgebra-glm provides a GLM-compatible graphics API, and nalgebra-macros offers procedural macros for ergonomic matrix construction. The library is production-grade, with extensive unit and property-based tests (proptest), benchmarks, and CI covering no-std and WASM targets. Its architecture is modular: the base module defines the core matrix type, storage traits, and dimension system; geometry module provides high-level wrappers; linalg module implements decompositions; and each subcrate is independently versioned and tested. The design exhibits strong engineering practices—clean trait boundaries, careful use of unsafe code (documented invariants), and macro-driven operator overloading to reduce boilerplate. While some modules (sparse, GLM) are less mature than the core, the library remains actively maintained and widely adopted in robotics, graphics, and scientific computing. Notable reusable components include the SparsityPattern structure for CSR/CSC index management, the Matrix Market parser (PEG-based), and the procedural macros for compile-time validated matrix literals. These components encapsulate non-trivial domain logic and could be adapted for other Rust linear algebra libraries with minimal modification.