MCPcopy Create free account
hub / github.com/OriginQ/QPanda-2 / getSparseEigenRowVector

Method getSparseEigenRowVector

Applications/HHL_Algorithm/SparseQMatrix.h:380–386  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

378
379template<class Ty>
380Eigen::Matrix<Ty, Dynamic, 1> SparseQMatrix<Ty>::getSparseEigenRowVector(unsigned long x) {
381 Eigen::Matrix<Ty, Dynamic, 1> row_vector = Eigen::Matrix<Ty, Dynamic, 1>::Zero(size, 1);
382 for (int i = nnzcol_ptr[x]; i < nnzcol_ptr[x + 1]; i++) {
383 row_vector(nnzcol_ind[i]) = data[i];
384 }
385 return row_vector;
386}
387
388template<class Ty>
389Eigen::Matrix<Ty, Dynamic, 1> SparseQMatrix<Ty>::getCompressedEigenRowVector(unsigned long x) {

Callers 3

getSubMatrixFunction · 0.80
MprodcutAFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected