π€ AI Summary
Existing Julia ecosystems lack libraries for typed, extensible test matrix management, hindering efficient selection of matrices by mathematical properties (e.g., symmetry, positive definiteness) and preventing seamless integration of user-defined matrix types. To address this, we introduce the first matrix collection library built natively on Juliaβs type system: it leverages parametric types and multiple dispatch to enable compile-time property inference, implements a type-driven classification and registration mechanism, and provides zero-overhead abstract interfaces. The library includes dozens of standardized test matrices and a uniform access protocol conforming to established conventions. It significantly enhances reproducibility, type safety, and extensibility in linear algebra algorithm verification. The design ensures full compatibility with Juliaβs generic programming model, enabling automatic dispatch based on matrix structure and semantics. This library has been adopted by several major Julia scientific computing packages, serving as a foundational tool for robust numerical testing.
π Abstract
TypedMatrices.jl is a Julia package to organize test matrices. By default, the package comes with a number of built-in matrices and interfaces to help users select test cases based on their properties. The package is designed to be extensible, allowing users to define their own matrix types. We discuss the design and implementation of the package and demonstrate its usage with a number of examples.