20#ifndef OPM_BLOCKED_MATRIX_HPP
21#define OPM_BLOCKED_MATRIX_HPP
40 : nnzValues(new double[nnzbs_*block_size_*block_size_]),
41 colIndices(new int[nnzbs_*block_size_*block_size_]),
42 rowPointers(new int[Nb_+1]),
45 block_size(block_size_),
53 : nnzValues(new double[M.nnzbs*M.block_size*M.block_size]),
54 colIndices(M.colIndices),
55 rowPointers(M.rowPointers),
58 block_size(M.block_size),
70 BlockedMatrix(
int Nb_,
int nnzbs_,
unsigned int block_size_,
double *nnzValues_,
int *colIndices_,
int *rowPointers_)
71 : nnzValues(nnzValues_),
72 colIndices(colIndices_),
73 rowPointers(rowPointers_),
76 block_size(block_size_),
97 unsigned int block_size;
109void sortRow(
int *colIndices,
int *data,
int left,
int right);
117void blockMultSub(
double *a,
double *b,
double *c,
unsigned int block_size);
125void blockMult(
double *mat1,
double *mat2,
double *resMat,
unsigned int block_size);
This struct resembles a blocked csr matrix, like Dune::BCRSMatrix.
Definition: BlockedMatrix.hpp:31
BlockedMatrix(const BlockedMatrix &M)
Allocate BlockedMatrix, but copy sparsity pattern instead of allocating new memory.
Definition: BlockedMatrix.hpp:52
BlockedMatrix(int Nb_, int nnzbs_, unsigned int block_size_, double *nnzValues_, int *colIndices_, int *rowPointers_)
Allocate BlockedMatrix, but let data arrays point to existing arrays.
Definition: BlockedMatrix.hpp:70
BlockedMatrix(int Nb_, int nnzbs_, unsigned int block_size_)
Allocate BlockedMatrix and data arrays with given sizes.
Definition: BlockedMatrix.hpp:39
This file contains a set of helper functions used by VFPProd / VFPInj.
Definition: BlackoilPhases.hpp:27