25 #include <opm/simulators/linalg/bda/BlockedMatrix.hpp>
30 #define MAX_COLORS 256
45 template <
unsigned int block_size>
46 int colorBlockedNodes(
int rows,
const int *CSRRowPointers,
const int *CSRColIndices,
const int *CSCColPointers,
const int *CSCRowIndices, std::vector<int>& colors,
int maxRowsPerColor,
int maxColsPerColor);
54 template <
unsigned int block_size>
55 void reorderBlockedMatrixByPattern(BlockedMatrix<block_size> *mat,
int *toOrder,
int *fromOrder, BlockedMatrix<block_size> *rmat);
65 void colorsToReordering(
int Nb, std::vector<int>& colors,
int numColors,
int *toOrder,
int *fromOrder, std::vector<int>& rowsPerColor);
74 template <
unsigned int block_size>
75 void reorderBlockedVectorByPattern(
int Nb,
double *vector,
int *fromOrder,
double *rVector);
83 bool canBeStarted(
const int rowIndex,
const int *rowPointers,
const int *colIndices,
const std::vector<bool>& doneRows);
96 void findLevelScheduling(
int *CSRColIndices,
int *CSRRowPointers,
int *CSCRowIndices,
int *CSCColPointers,
int Nb,
int *numColors,
int *toOrder,
int* fromOrder, std::vector<int>& rowsPerColor);
111 template <
unsigned int block_size>
112 void findGraphColoring(
const int *CSRColIndices,
const int *CSRRowPointers,
const int *CSCRowIndices,
const int *CSCColPointers,
int Nb,
int maxRowsPerColor,
int maxColsPerColor,
int *numColors,
int *toOrder,
int *fromOrder, std::vector<int>& rowsPerColor);
122 void csrPatternToCsc(
int *CSRColIndices,
int *CSRRowPointers,
int *CSCRowIndices,
int *CSCColPointers,
int Nb);