pub fn sparse_matrix_trace<F>(a: &CsrMatrix<F>) -> Fwhere F: Float + NumAssign + Sum + SparseElement + Debug + 'static,
Compute the trace of a sparse matrix (sum of diagonal elements).