Sparse matrix class using the ELLPACK format for storing the nonzeros. More...
#include <ell_matrix.hpp>
Public Types | |
typedef viennacl::backend::mem_handle | handle_type |
typedef scalar< typename viennacl::tools::CHECK_SCALAR_TEMPLATE_ARGUMENT < NumericT >::ResultType > | value_type |
typedef vcl_size_t | size_type |
Public Member Functions | |
ell_matrix () | |
ell_matrix (viennacl::context ctx) | |
void | clear () |
Resets all entries in the matrix back to zero without changing the matrix size. Resets the sparsity pattern. More... | |
vcl_size_t | internal_size1 () const |
vcl_size_t | internal_size2 () const |
vcl_size_t | size1 () const |
vcl_size_t | size2 () const |
vcl_size_t | internal_maxnnz () const |
vcl_size_t | maxnnz () const |
vcl_size_t | nnz () const |
vcl_size_t | internal_nnz () const |
handle_type & | handle () |
const handle_type & | handle () const |
handle_type & | handle2 () |
const handle_type & | handle2 () const |
Friends | |
template<typename CPUMatrixT , typename T , unsigned int ALIGN> | |
void | copy (const CPUMatrixT &cpu_matrix, ell_matrix< T, ALIGN > &gpu_matrix) |
Sparse matrix class using the ELLPACK format for storing the nonzeros.
This format works best for matrices where the number of nonzeros per row is mostly the same. Finite element and finite difference methods on nicely shaped domains often result in such a nonzero pattern. For a matrix
(1 2 0 0 0) (2 3 4 0 0) (0 5 6 0 7) (0 0 8 9 0)
the entries are layed out in chunks of size 3 as (1 2 5 8; 2 3 6 9; 0 4 7 0) Note that this is a 'transposed' representation in order to maximize coalesced memory access.
Definition at line 53 of file ell_matrix.hpp.
typedef viennacl::backend::mem_handle viennacl::ell_matrix< NumericT, AlignmentV >::handle_type |
Definition at line 56 of file ell_matrix.hpp.
typedef vcl_size_t viennacl::ell_matrix< NumericT, AlignmentV >::size_type |
Definition at line 58 of file ell_matrix.hpp.
typedef scalar<typename viennacl::tools::CHECK_SCALAR_TEMPLATE_ARGUMENT<NumericT>::ResultType> viennacl::ell_matrix< NumericT, AlignmentV >::value_type |
Definition at line 57 of file ell_matrix.hpp.
|
inline |
Definition at line 60 of file ell_matrix.hpp.
|
inline |
Definition at line 62 of file ell_matrix.hpp.
|
inline |
Resets all entries in the matrix back to zero without changing the matrix size. Resets the sparsity pattern.
Definition at line 77 of file ell_matrix.hpp.
|
inline |
Definition at line 100 of file ell_matrix.hpp.
|
inline |
Definition at line 101 of file ell_matrix.hpp.
|
inline |
Definition at line 103 of file ell_matrix.hpp.
|
inline |
Definition at line 104 of file ell_matrix.hpp.
|
inline |
Definition at line 94 of file ell_matrix.hpp.
|
inline |
Definition at line 98 of file ell_matrix.hpp.
|
inline |
Definition at line 88 of file ell_matrix.hpp.
|
inline |
Definition at line 89 of file ell_matrix.hpp.
|
inline |
Definition at line 95 of file ell_matrix.hpp.
|
inline |
Definition at line 97 of file ell_matrix.hpp.
|
inline |
Definition at line 91 of file ell_matrix.hpp.
|
inline |
Definition at line 92 of file ell_matrix.hpp.
|
friend |