num::sparse_diagonal_similarity¶
Defined in header <linear/sparse/sparse.hpp>
Scale the rows and columns of a sparse matrix, keeping it sparse: \(D^{-1} A D\). The result has the pattern of A.
Exceptions¶
std::invalid_argument: If the dimensions disagree or a weight is not positive.