1 #include<DD-AVX_internal.hpp>
34 val.insert(
val.begin() + pos, a);
38 for(
int i = r+1; i <
row+1; i++){
47 std::copy(mat.
val.begin(), mat.
val.end(), back_inserter(
val));
60 std::cerr <<
"error bad row" << std::endl;
64 std::vector<double> ret(
row, 0.0);
75 std::cerr <<
"error bad col" << std::endl;
78 std::vector<double> ret(
row, 0.0);
80 #pragma omp parallel for
81 for(
int i=0; i<
row; i++){
84 ret.data()[i] =
val[j];
92 std::vector<double> ret(
row, 0.0);
94 #pragma omp parallel for
95 for(
int i=0; i<
row; i++){
98 ret.data()[i] =
val[j];
double precision CRS format sparse matrix
d_real_vector get_col_vec(const int c)
get col vector A[*,c]
std::vector< int > col_ind
d_real_vector get_row_vec(const int r)
get row vector A[r,*]
std::vector< int > row_ptr
void insert(const int r, const int c, const double a)
insert value a to A[r, c]
d_real_vector get_diag_vec()
get diagonal vector
double at(const int r, const int c)
get A[r, c]
std::vector< double > val
d_real_SpMat & operator=(const d_real_SpMat &mat)
copy operator
void copy(const d_real_SpMat &mat)
copy, mat = A
Double precision vector class, This class is almost same as std::vector<double>