Opm::Accelerator::Matrix Class Reference

#include <Matrix.hpp>

Public Member Functions

 Matrix (int N_, int nnzs_)
 
 Matrix (int N_, int M_, int nnzs_)
 

Public Attributes

std::vector< double > nnzValues
 
std::vector< int > colIndices
 
std::vector< int > rowPointers
 
int N
 
int M
 
int nnzs
 

Detailed Description

This struct resembles a csr matrix, only doubles are supported The data is stored in contiguous memory, such that they can be copied to a device in one transfer.

Constructor & Destructor Documentation

◆ Matrix() [1/2]

Opm::Accelerator::Matrix::Matrix ( int  N_,
int  nnzs_ 
)
inline

Allocate square Matrix and data arrays with given sizes

Parameters
[in]Nnumber of rows
[in]nnzsnumber of nonzeros

References colIndices, N, nnzs, nnzValues, and rowPointers.

◆ Matrix() [2/2]

Opm::Accelerator::Matrix::Matrix ( int  N_,
int  M_,
int  nnzs_ 
)
inline

Allocate rectangular Matrix and data arrays with given sizes

Parameters
[in]Nnumber of rows
[in]Mnumber of columns
[in]nnzsnumber of nonzeros

References M.

Member Data Documentation

◆ colIndices

std::vector<int> Opm::Accelerator::Matrix::colIndices

Referenced by Matrix().

◆ M

int Opm::Accelerator::Matrix::M

Referenced by Matrix().

◆ N

int Opm::Accelerator::Matrix::N

Referenced by Matrix().

◆ nnzs

int Opm::Accelerator::Matrix::nnzs

Referenced by Matrix().

◆ nnzValues

std::vector<double> Opm::Accelerator::Matrix::nnzValues

Referenced by Matrix().

◆ rowPointers

std::vector<int> Opm::Accelerator::Matrix::rowPointers

Referenced by Matrix().


The documentation for this class was generated from the following file: