Biquaternion Algebra with Bilinear Multiplication: A General, Elegant, and Computationally Advantageous Framework for Relativistic Electronic Structure Calculations on CPUs and GPUs
Sylvia Kaviraj, Stanislav Komorovsky, Trond Saue, Michal Repisky
Abstract
Quaternion algebra provides a natural representation of time-reversal-symmetric matrix structures in relativistic electronic-structure theory, whereas complementary time-reversal-antisymmetric structures extend this representation to complex quaternions, or biquaternions. Here, we explicitly exploit biquaternion algebra for fundamental objects, including operators, kinetically and magnetically balanced basis functions, and their expectation values, within a unified framework encompassing real, complex, and real quaternion subalgebras as special cases. To realize this framework computationally, we have developed HMATLIB, a biquaternion matrix library implemented within the ReSpect package for pure CPU and hybrid CPU/GPU execution. A key development is a bilinear algorithm for matrix-valued biquaternion multiplication that reduces the number of real matrix--matrix multiplications from 64 to 24 compared with the conventional component-wise approach, while the biquaternion representation effectively doubles the maximum accessible matrix dimension under the same 32-bit indexing constraint. Numerical benchmarks on modern CPU and GPU architectures demonstrate that the biquaternion formulation consistently outperforms its isomorphic complex-algebra counterpart. For the largest matrices reported, hybrid CPU/GPU execution accelerates bilinear matrix multiplication by approximately 5-8 times over pure CPU execution and matrix diagonalization by approximately 12 and 61 times relative to CPU oneAPI MKL and NVHPC OpenBLAS, respectively. These results establish biquaternion algebra as a general and computationally advantageous framework for modern relativistic electronic-structure calculations.
Create a lesson
Related papers
Low-Temperature Transport in Li-Ion Battery EC/EMC/FEC Electrolytes: Molecular Dynamics and Machine-Learning Modeling
İpek Yenda Çınar, Oguzhan Orhan, M. Oluş Özbek et al.
HiPoly: a hierarchical polymer-native AI framework for property prediction and generative design
Ge Sun, Gervasio Zaldivar, Yuan Tian et al.
Prototype-guided transfer of sparse literature knowledge for electrolyte additive discovery
Weixiang Hong, Hongting Du, Jiayue Tang et al.
A Generalized Approach for Incorporating Geometry and Directionality into Coarse-Grained Machine-Learned Potentials
Arthur Y. Lin, Tejas Dahiya, Rose K. Cersonsky
Latent unified smooth Hamiltonians for excited state chemistry
David Juergens, Martin Stöhr, Andreas E. Hillers-Bendtsen et al.
Dodecahydrogen uranium: an icosahedral f-electron superatom with 26-electron shell structure
Andrii Shyichuk, Eugeniusz Zych