14 dd_real_vector_ref(
typename std::vector<double>::iterator hi,
typename std::vector<double>::iterator lo)
17 operator double()
const{
21 operator dd_real()
const{
72 std::vector<double>
hi;
73 std::vector<double>
lo;
93 hi.resize(
N, val.x[0]);
94 lo.resize(
N, val.x[1]);
103 operator std::vector<double>();
123 std::vector<double>
HI(){
return this->
hi;}
125 std::vector<double>
LO(){
return this->
lo;}
137 void print_all(){
for(
int i=0; i<
N; i++) std::cout <<
hi[i] <<
", " <<
lo[i] << std::endl; }
139 void print(
int i){ std::cout <<
hi[i] <<
", " <<
lo[i] << std::endl;}
170 hi.resize(
N, val.x[0]);
171 lo.resize(
N, val.x[1]);
184 hi.push_back(val.x[0]);
185 lo.push_back(val.x[1]);
201 void copy(
const std::vector<double>& vec);
203 void copy(
const std::vector<dd_real>& vec);
221 bool operator==(
const std::vector<double>& vec);
223 bool operator==(
const std::vector<dd_real>& vec);
230 bool operator!=(
const std::vector<double>& vec);
232 bool operator!=(
const std::vector<dd_real>& vec);
dd_real operator*(const dd_real a, const dd_real_vector_ref b)
dd_real operator+(const dd_real a, const dd_real_vector_ref b)
dd_real operator/(const dd_real a, const dd_real_vector_ref b)
dd_real operator-(const dd_real a, const dd_real_vector_ref b)
Double precision vector class, This class is almost same as std::vector<double>
Double-double precision vector reference class.
dd_real operator/(const dd_real a)
dd_real operator*(const dd_real a)
void operator=(dd_real_vector_ref &c)
std::vector< double >::iterator dd_lo_iter
dd_real_vector_ref(typename std::vector< double >::iterator hi, typename std::vector< double >::iterator lo)
dd_real operator-(const dd_real a)
void operator=(double &c)
std::vector< double >::iterator dd_hi_iter
void operator=(dd_real c)
dd_real operator+(const dd_real a)
Double-double precision vector class.
void copy(const dd_real_vector &vec)
copy from dd_real_vector
std::vector< double > LO()
get lo array pointer
bool operator!=(const dd_real_vector &vec)
comparision function
dd_real_vector operator/=(dd_real_vector &vec)
all elemetnt arithmetic function
dd_real_vector operator*(dd_real_vector &vec)
all elemetnt arithmetic function
void output_plane(const char *filename)
output vector to plane file
void print_all()
output all elements to standard I/O
std::vector< double > HI()
get hi array pointer
void push_back(const dd_real val)
push_back, this method is almost same as std::vector
dd_real_vector_ref operator[](int i)
get vec[i] value
void mul(dd_real_vector &vec1, dd_real_vector &vec2)
all elemetnt arithmetic function
double * hi_data()
get hi array pointer
dd_real_vector operator+=(dd_real_vector &vec)
all elemetnt arithmetic function
double * lo_data()
get lo array pointer
dd_real_vector operator+(dd_real_vector &vec)
all elemetnt arithmetic function
void input_mm(FILE *file)
create vector from matrix market file
dd_real_vector operator/(dd_real_vector &vec)
all elemetnt arithmetic function
void print(int i)
output vec[i] to standard I/O
dd_real_vector(int n, double val)
create size N, all element is val DD vector
void input_plane(FILE *file)
create vector from plane file
void div(dd_real_vector &vec1, dd_real_vector &vec2)
all elemetnt arithmetic function
dd_real_vector(int n)
create size N DD vector
dd_real_vector(int n, dd_real val)
create size N, all element is val DD vector
void sub(dd_real_vector &vec1, dd_real_vector &vec2)
all elemetnt arithmetic function
double * data()
get hi array pointer
dd_real_vector operator*=(dd_real_vector &vec)
all elemetnt arithmetic function
void clear()
clear, this method is almost same as std::vector
void resize(int n, double val)
resize, this method is almost same as std::vector
dd_real_vector & operator=(const dd_real_vector &vec)
copy from dd_real_vector
dd_real at(int i)
get vec[i] value
bool operator==(const dd_real_vector &vec)
comparision function
dd_real_vector operator-()
sign
void resize(int n, dd_real val)
resize, this method is almost same as std::vector
void input(const char *filename)
create vector from file
dd_real_vector operator-=(dd_real_vector &vec)
all elemetnt arithmetic function
void output_mm(const char *filename)
output vector to matrix market file
void add(dd_real_vector &vec1, dd_real_vector &vec2)
all elemetnt arithmetic function
void push_back(const double val)
push_back, this method is almost same as std::vector
void resize(int n)
resize, this method is almost same as std::vector