Loading src/TNL/Matrices/CSR.h +9 −21 Original line number Diff line number Diff line Loading @@ -225,34 +225,22 @@ public: // The following getters allow us to interface TNL with external C-like // libraries such as UMFPACK or SuperLU, which need the raw data. Index* getRowPointers() const Containers::Vector< Index, Device, Index >& getRowPointers() const { return this->rowPointers.getData(); return this->rowPointers; } const Index* getRowPointers() const const Containers::Vector< Index, Device, Index >& getColumnIndexes() const { return this->rowPointers.getData(); return this->columnIndexes; } Index* getColumnIndexes() const Containers::Vector< Real, Device, Index >& getValues() const { return this->columnIndexes.getData(); } const Index* getColumnIndexes() const { return this->columnIndexes.getData(); } Real* getValues() { return this->values.getData(); } const Real* getValues() const { return this->values.getData(); return this->values; } protected: Loading src/TNL/Solvers/Linear/UmfpackWrapper_impl.h +9 −9 Original line number Diff line number Diff line Loading @@ -88,9 +88,9 @@ solve( const Vector& b, // symbolic reordering of the sparse matrix status = umfpack_di_symbolic( size, size, matrix->getRowPointers(), matrix->getColumnIndexes(), matrix->getValues(), matrix->getRowPointers().getData(), matrix->getColumnIndexes().getData(), matrix->getValues().getData(), &Symbolic, Control, Info ); if( status != UMFPACK_OK ) { std::cerr << "error: symbolic reordering failed" << std::endl; Loading @@ -98,9 +98,9 @@ solve( const Vector& b, } // numeric factorization status = umfpack_di_numeric( matrix->getRowPointers(), matrix->getColumnIndexes(), matrix->getValues(), status = umfpack_di_numeric( matrix->getRowPointers().getData(), matrix->getColumnIndexes().getData(), matrix->getValues().getData(), Symbolic, &Numeric, Control, Info ); if( status != UMFPACK_OK ) { std::cerr << "error: numeric factorization failed" << std::endl; Loading @@ -109,9 +109,9 @@ solve( const Vector& b, // solve with specified right-hand-side status = umfpack_di_solve( system_type, matrix->getRowPointers(), matrix->getColumnIndexes(), matrix->getValues(), matrix->getRowPointers().getData(), matrix->getColumnIndexes().getData(), matrix->getValues().getData(), x.getData(), b.getData(), Numeric, Control, Info ); Loading Loading
src/TNL/Matrices/CSR.h +9 −21 Original line number Diff line number Diff line Loading @@ -225,34 +225,22 @@ public: // The following getters allow us to interface TNL with external C-like // libraries such as UMFPACK or SuperLU, which need the raw data. Index* getRowPointers() const Containers::Vector< Index, Device, Index >& getRowPointers() const { return this->rowPointers.getData(); return this->rowPointers; } const Index* getRowPointers() const const Containers::Vector< Index, Device, Index >& getColumnIndexes() const { return this->rowPointers.getData(); return this->columnIndexes; } Index* getColumnIndexes() const Containers::Vector< Real, Device, Index >& getValues() const { return this->columnIndexes.getData(); } const Index* getColumnIndexes() const { return this->columnIndexes.getData(); } Real* getValues() { return this->values.getData(); } const Real* getValues() const { return this->values.getData(); return this->values; } protected: Loading
src/TNL/Solvers/Linear/UmfpackWrapper_impl.h +9 −9 Original line number Diff line number Diff line Loading @@ -88,9 +88,9 @@ solve( const Vector& b, // symbolic reordering of the sparse matrix status = umfpack_di_symbolic( size, size, matrix->getRowPointers(), matrix->getColumnIndexes(), matrix->getValues(), matrix->getRowPointers().getData(), matrix->getColumnIndexes().getData(), matrix->getValues().getData(), &Symbolic, Control, Info ); if( status != UMFPACK_OK ) { std::cerr << "error: symbolic reordering failed" << std::endl; Loading @@ -98,9 +98,9 @@ solve( const Vector& b, } // numeric factorization status = umfpack_di_numeric( matrix->getRowPointers(), matrix->getColumnIndexes(), matrix->getValues(), status = umfpack_di_numeric( matrix->getRowPointers().getData(), matrix->getColumnIndexes().getData(), matrix->getValues().getData(), Symbolic, &Numeric, Control, Info ); if( status != UMFPACK_OK ) { std::cerr << "error: numeric factorization failed" << std::endl; Loading @@ -109,9 +109,9 @@ solve( const Vector& b, // solve with specified right-hand-side status = umfpack_di_solve( system_type, matrix->getRowPointers(), matrix->getColumnIndexes(), matrix->getValues(), matrix->getRowPointers().getData(), matrix->getColumnIndexes().getData(), matrix->getValues().getData(), x.getData(), b.getData(), Numeric, Control, Info ); Loading