Design of Generic Direct Sparse Linear System Solver in C++ for Power System Analysis

This article presents the design of the generic linear system solver (LSS) for a class of large sparse symmetric matrices over real and complex numbers. These matrices correspond to one of the following: (1) symmetric positive definite (SPD) matrices, (2) complex Hermitian matrices, or (3) complex matrices with SPD real and imaginary matrices. Such matrices arise in various power system analysis applications like load flow analysis and short circuit analysis. A template facility of C++ is used to write a generic program on float, double, and complex data types. The design of the algorithm guarantees numerical stability and efficient sparsity implementation. A reusable class SET is defined to cater to graph theoretic computations. LSS problems with matrices up to 20,000 nodes have been tested. Another feature of the proposed LSS is the implementation of associative array, which allows subscripting an array with character strings, such as bus names. This helps in making the four power system analysis software user friendly. The proposed LSS reflects an important development towards a truly object-oriented four power system analysis software.