source/utilities_basic/csr_matrix.cc File Reference

Compressed sparse row (CSR) matrix functionality. More...

#include <cmath>
#include <cstdlib>
#include <cstdio>
#include <cassert>
#include <stdexcept>
#include "csr_matrix.h"
#include "output.h"
#include "memorymanag.h"
#include "mat_gblas.h"

Classes

struct  csr_index_pair_struct

Functions

static int csr_compare_index_pairs_for_qsort (const void *p1, const void *p2)
int ergo_CSR_create (csr_matrix_struct *csr, int symmetryFlag, int n, long nnz, const std::vector< int > &rowind, const std::vector< int > &colind)
int ergo_CSR_destroy (csr_matrix_struct *csr)
int ergo_CSR_copy (csr_matrix_struct *csrDest, const csr_matrix_struct *csrSource)
int ergo_CSR_add_equal_structure (csr_matrix_struct *csrDest, const csr_matrix_struct *csrSource)
static long ergo_csr_find_index (const csr_matrix_struct *csr, int row, int col)
int ergo_CSR_add_to_element (csr_matrix_struct *csr, int row, int col, ergo_real value)
ergo_real ergo_CSR_get_element (const csr_matrix_struct *csr, int row, int col)
ergo_real ergo_CSR_get_max_abs_element (const csr_matrix_struct *csr)
long ergo_CSR_get_nvalues (const csr_matrix_struct *csr)
int ergo_CSR_get_values (const csr_matrix_struct *csr, std::vector< int > &rowind, std::vector< int > &colind, std::vector< ergo_real > &values, long nvalues)
int ergo_CSR_get_nvalues_singlerow (const csr_matrix_struct *csr, int row)
int ergo_CSR_get_values_singlerow (const csr_matrix_struct *csr, int row, std::vector< int > &colind, std::vector< ergo_real > &values, int nvalues)

Detailed Description

Compressed sparse row (CSR) matrix functionality.

Author:
: Elias Rudberg responsible

Function Documentation

static int csr_compare_index_pairs_for_qsort ( const void *  p1,
const void *  p2 
) [static]
int ergo_CSR_add_equal_structure ( csr_matrix_struct csrDest,
const csr_matrix_struct csrSource 
)
int ergo_CSR_add_to_element ( csr_matrix_struct csr,
int  row,
int  col,
ergo_real  value 
)
int ergo_CSR_copy ( csr_matrix_struct csrDest,
const csr_matrix_struct csrSource 
)
int ergo_CSR_create ( csr_matrix_struct csr,
int  symmetryFlag,
int  n,
long  nnz,
const std::vector< int > &  rowind,
const std::vector< int > &  colind 
)
int ergo_CSR_destroy ( csr_matrix_struct csr  ) 
static long ergo_csr_find_index ( const csr_matrix_struct csr,
int  row,
int  col 
) [static]
ergo_real ergo_CSR_get_element ( const csr_matrix_struct csr,
int  row,
int  col 
)
ergo_real ergo_CSR_get_max_abs_element ( const csr_matrix_struct csr  ) 
long ergo_CSR_get_nvalues ( const csr_matrix_struct csr  ) 
int ergo_CSR_get_nvalues_singlerow ( const csr_matrix_struct csr,
int  row 
)
int ergo_CSR_get_values ( const csr_matrix_struct csr,
std::vector< int > &  rowind,
std::vector< int > &  colind,
std::vector< ergo_real > &  values,
long  nvalues 
)
int ergo_CSR_get_values_singlerow ( const csr_matrix_struct csr,
int  row,
std::vector< int > &  colind,
std::vector< ergo_real > &  values,
int  nvalues 
)

Generated on 10 Jul 2018 for ergo by  doxygen 1.6.1