80 explicit GVector(
const int& num);
81 explicit GVector(
const double& a);
82 explicit GVector(
const double& a,
const double& b);
83 explicit GVector(
const double& a,
const double& b,
const double& c);
89 const double&
operator[](
const int& index)
const;
108 const int&
size(
void)
const;
109 double&
at(
const int& index);
110 const double&
at(
const int& index)
const;
GVector slice(const int &start, const int &stop) const
Vector slice operator.
friend GVector abs(const GVector &vector)
Computes absolute of vector elements.
void alloc_members(void)
Allocate vector.
GArf operator/(const GArf &arf, const double &scale)
Auxiliary Response File vision operator friend.
friend GVector cosh(const GVector &vector)
Computes cosh of vector elements.
friend double max(const GVector &vector)
Computes maximum vector element.
double & operator[](const int &index)
Vector element access operator.
GVector & operator*=(const double &scalar)
Scalar unary multiplication operator.
friend GVector sin(const GVector &vector)
Computes sine of vector elements.
friend GVector log10(const GVector &vector)
Computes base10 logarithm of vector elements.
friend GVector acos(const GVector &vector)
Computes arccos of vector elements.
int last_nonzero(void) const
Return the index of the last non-zero element in a vector.
Definition of interface for all GammaLib classes.
friend double norm(const GVector &vector)
Computes vector norm.
int first_nonzero(void) const
Return the index of the first non-zero element in a vector.
GVector & operator=(const GVector &vector)
Assignment operator.
friend double sum(const GVector &vector)
Computes vector sum.
GArf operator+(const GArf &a, const GArf &b)
Auxiliary Response File addition operator friend.
std::string classname(void) const
Return class name.
friend GVector tan(const GVector &vector)
Computes tangens of vector elements.
friend double angle(const GVector &a, const GVector &b)
Computes angle between vectors.
double & at(const int &index)
Vector element access with range checking.
friend GVector atanh(const GVector &vector)
Computes atanh of vector elements.
void clear(void)
Clear vector.
virtual ~GVector(void)
Destructor.
friend GVector asin(const GVector &vector)
Computes arcsin of vector elements.
friend GVector atan(const GVector &vector)
Computes arctan of vector elements.
double * m_data
Vector array.
friend GVector asinh(const GVector &vector)
Computes asinh of vector elements.
friend GVector tanh(const GVector &vector)
Computes tanh of vector elements.
int non_zeros(void) const
Returns number of non-zero elements in vector.
Interface class for all GammaLib classes.
friend GVector perm(const GVector &vector, const int *p)
Computes vector permutation.
bool operator==(const GVector &vector) const
Equality operator.
int m_num
Number of elements in vector.
GVector & operator+=(const GVector &vector)
Unary addition operator.
GArf operator*(const GArf &arf, const double &scale)
Auxiliary Response File scaling operator friend.
friend GVector cos(const GVector &vector)
Computes cosine of vector elements.
friend GVector cross(const GVector &a, const GVector &b)
Vector cross product.
GVector * clone(void) const
Clone vector.
void init_members(void)
Initialise class members.
friend double min(const GVector &vector)
Computes minimum vector element.
GVector operator-(void) const
Unary minus operator.
friend GVector sqrt(const GVector &vector)
Computes square root of vector elements.
void copy_members(const GVector &vector)
Copy class members.
friend double operator*(const GVector &a, const GVector &b)
Vector scalar product.
friend GVector iperm(const GVector &vector, const int *p)
Computes vector inverse permutation.
friend GVector pow(const GVector &vector, const double &power)
Computes tanh of vector elements.
GVector & operator/=(const double &scalar)
Scalar unary division operator.
GVector(void)
Void vector constructor.
Exception handler interface definition.
friend GVector exp(const GVector &vector)
Computes exponential of vector elements.
friend GVector acosh(const GVector &vector)
Computes acosh of vector elements.
friend GVector log(const GVector &vector)
Computes natural logarithm of vector elements.
bool operator!=(const GVector &vector) const
Non-equality operator.
const int & size(void) const
Return size of vector.
friend GVector sinh(const GVector &vector)
Computes sinh of vector elements.
std::string print(const GChatter &chatter=NORMAL) const
Print vector information.
void free_members(void)
Delete class members.
GArf operator-(const GArf &a, const GArf &b)
Auxiliary Response File subtraction operator friend.
GVector & operator-=(const GVector &vector)
Unary subtraction operator.