24 n_loc_rows_(PETSC_DECIDE),
25 n_loc_cols_(mat_opt.n_local_cols)
42 n_loc_rows_(PETSC_DECIDE),
43 n_loc_cols_(mat_opt.n_local_cols)
59 n_loc_rows_(A.n_loc_rows_),
60 n_loc_cols_(A.n_loc_cols_),
61 start_rank_(A.start_rank_),
62 end_rank_(A.end_rank_)
117 const PetscViewerFormat vw_format)
Declaration of class PETScMatrix, which provides an interface to PETSc matrix routines.
Wrapper class for PETSc matrix routines for matrix.
PetscInt n_loc_cols_
Number of the local columns.
PETScMatrix & operator=(PETScMatrix const &A)
void create(const PetscInt d_nz, const PetscInt o_nz)
Create the matrix, configure memory allocation and set the related member data.
void set(const PetscInt i, const PetscInt j, const PetscScalar value)
Set a single entry with a value.
PetscInt end_rank_
Ending index in a rank.
void finalizeAssembly(const MatAssemblyType asm_type=MAT_FINAL_ASSEMBLY)
Perform MPI collection of assembled entries in buffer.
PetscInt n_loc_rows_
Number of the local rows.
PetscInt nrows_
Number of the global rows.
void setRowsColumnsZero(std::vector< PetscInt > const &row_pos)
Set the specified rows to zero except diagonal entries, i.e. , where This function must be called b...
PetscInt ncols_
Number of the global columns.
void viewer(const std::string &file_name, const PetscViewerFormat vw_format=PETSC_VIEWER_ASCII_MATLAB)
PetscInt start_rank_
Starting index in a rank.
bool finalizeMatrixAssembly(MAT_T &)
This a struct data containing the configuration information to create a PETSc type matrix.