21 #ifndef GSLPP_VECTOR_HH 22 #define GSLPP_VECTOR_HH 28 #include <gsl/gsl_vector.h> 60 Vector(size_type size,
bool clear);
68 Vector(size_type size,
const double *init);
77 Vector(gsl_vector *holder);
84 Vector(
const gsl_vector *holder);
124 const_iterator begin()
const;
129 const_iterator end()
const;
134 size_type size()
const;
143 return cdata->data[i * cdata->stride];
153 return data->data[i * data->stride];
157 const gsl_vector * operator ->()
const;
160 gsl_vector * operator ->();
172 void print(std::ostream& os)
const;
174 bool is_writable()
const;
175 bool is_valid()
const;
180 cdata = data = holder;
191 const gsl_vector *cdata;
199 gsl_vector_add(result, rhs);
206 gsl_vector_sub(result, rhs);
213 gsl_vector_scale(result, f);
225 reset_holder(&m_view.vector);
228 gsl_vector_view m_view;
239 m_holder(&m_view.vector)
245 return m_holder.begin();
249 return m_holder.end();
253 return m_holder.size();
265 const gsl_vector * operator ->()
const{
266 return m_holder.operator ->();
274 gsl_vector_const_view m_view;
void print(std::ostream &os) const
void reset_holder(const gsl_vector *holder)
gsl_vector * vector_pointer_type
reference operator[](size_t i)
const gsl_vector * vector_const_pointer_type
ConstVectorView(gsl_vector_const_view vv)
value_type operator[](size_t i) const
vector_iterator operator+(const vector_iterator &it, int dist)
const_vector_iterator const_iterator
vector_iterator operator-(const vector_iterator &it, int dist)
Vector::const_iterator end() const
void reset_holder(gsl_vector *holder)
double operator[](size_t i) const
VectorView(gsl_vector_view vv)
std::ostream & operator<<(std::ostream &os, const Matrix &m)
Vector::size_type size() const
Vector::const_iterator begin() const
Matrix EXPORT_GSL operator*(const Matrix &lhs, const Matrix &rhs)
const double & const_reference