Skip to content

Commit

Permalink
[PETScMatrix] Forward declaration of PETScVector
Browse files Browse the repository at this point in the history
and one comment change
  • Loading branch information
wenqing authored and endJunction committed Nov 20, 2024
1 parent 259dffc commit 9190e82
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions MathLib/LinAlg/PETSc/PETScMatrix.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@

#include "PETScMatrix.h"

#include "PETScVector.h"

namespace MathLib
{
PETScMatrix::PETScMatrix(const PetscInt nrows, const PETScMatrixOption& mat_opt)
Expand Down
5 changes: 3 additions & 2 deletions MathLib/LinAlg/PETSc/PETScMatrix.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@

#include "MathLib/LinAlg/RowColumnIndices.h"
#include "PETScMatrixOption.h"
#include "PETScVector.h"

typedef Mat PETSc_Mat;

namespace MathLib
{
class PETScVector;
/*!
\brief Wrapper class for PETSc matrix routines for matrix.
*/
Expand Down Expand Up @@ -173,7 +173,8 @@ class PETScMatrix
\param row_pos The global indices of the rows of the dense sub-matrix.
\param col_pos The global indices of the columns of the dense
sub-matrix.
\param sub_mat A dense sub-matrix to be added.
\param sub_mat A dense sub-matrix to be added. Its data of which must
be row oriented stored.
*/
template <class T_DENSE_MATRIX>
void add(std::vector<PetscInt> const& row_pos,
Expand Down

0 comments on commit 9190e82

Please sign in to comment.