High-Performance Variance-Covariance Matrix Construction Using an Uncentered Gram Formulation
Felix Reichel

TL;DR
This paper introduces a novel method for constructing covariance matrices efficiently by leveraging an uncentered Gram formulation, significantly reducing computational complexity and improving runtime performance in high-dimensional data analysis.
Contribution
The authors extend Reichel's variance measure to covariance matrices using an uncentered Gram approach, eliminating the need for explicit centering and enabling faster computations.
Findings
Significant runtime improvements in Python benchmarks
Effective use of BLAS optimizations enhances performance
Optional use of RXTX routines further accelerates computation
Abstract
Reichel (2025) defined the bariance as a pairwise-difference measure that can be rewritten in linear time using only scalar sums. We extend this idea to the covariance matrix by showing that the standard matrix expression involving the uncentered Gram matrix and a correction term is algebraically identical to the pairwise-difference definition while avoiding explicit centering. The computation then reduces to one outer product of dimension p-by-p and a single subtraction. Benchmarks in Python show clear runtime gains, especially when BLAS optimizations are absent. Optionally faster Gram-matrix routines such as RXTX (Rybin et al., 2025) further reduce overall cost.
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.
Taxonomy
TopicsTensor decomposition and applications · Matrix Theory and Algorithms · Polynomial and algebraic computation
