A C implementation of the Smith massager algorithm
Ziwen Wang, Stavros Birmpilis, George Labahn, Arne Storjohann

TL;DR
This paper presents a highly efficient C implementation of a Smith normal form algorithm for integer matrices, achieving near-matrix multiplication speed through advanced optimization techniques.
Contribution
The authors introduce practical implementation strategies that significantly improve the performance of the Smith massager algorithm, bridging theory and real-world application.
Findings
Implementation scales proportionally to matrix multiplication time.
Optimization techniques enable collapsing multiple iterations into one.
Experimental results up to 10,007 dimensions demonstrate practical efficiency.
Abstract
We describe a C implementation of the Las Vegas algorithm of Birmpilis, Labahn and Storjohann from 2020 for computing the Smith normal form of a nonsingular integer matrix. The algorithm computes a Smith massager for the input matrix using bit operations, which is softly equivalent to the cost of multiplying two matrices of the same dimension and entry size. We describe the key implementation techniques that bridge the gap between the theoretical algorithm and practical performance, including BLAS-accelerated modular arithmetic via the Residue Number System and an adaptive batching scheme that collapses the theoretical iterations to in practice. Experiments on matrices of dimension up to show that the implementation's running time scales proportionally to that of a single BLAS matrix multiplication,…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
