42 #ifndef ABSTRACT_LINALG_PACK_VECTOR_STD_OPS_H
43 #define ABSTRACT_LINALG_PACK_VECTOR_STD_OPS_H
47 namespace AbstractLinAlgPack {
108 void Vp_StV( VectorMutable* v_lhs,
const value_type& alpha,
const Vector& v_rhs );
117 const value_type& alpha,
const Vector& v_rhs1,
const Vector& v_rhs2
118 ,VectorMutable* v_lhs );
123 const value_type& alpha,
const Vector& v_rhs1,
const Vector& v_rhs2
124 ,VectorMutable* v_lhs );
166 return dot(v_rhs2,sv_rhs1);
169 #endif // ABSTRACT_LINALG_PACK_VECTOR_STD_OPS_H
Abstract interface for immutable, finite dimensional, coordinate vectors {abstract}.
RTOp_index_type index_type
void sign(const Vector &v, VectorMutable *z)
Compute the sign of each element in an input vector.
void Vt_S(VectorMutable *v_lhs, const value_type &alpha)
v_lhs *= alpha
void seed_random_vector_generator(unsigned int)
Seed the random number generator.
RTOp_value_type value_type
Sparse Vector Slice class template.
void Vp_StV(VectorMutable *v_lhs, const value_type &alpha, const Vector &v_rhs)
v_lhs = alpha * v_rhs + v_lhs
void ele_wise_divide(const value_type &alpha, const Vector &v_rhs1, const Vector &v_rhs2, VectorMutable *v_lhs)
v_lhs(i) = alpha * v_rhs1(i) / v_rhs2(i), i = 1,,,dim.
void ele_wise_prod(const value_type &alpha, const Vector &v_rhs1, const Vector &v_rhs2, VectorMutable *v_lhs)
v_lhs(i) += alpha * v_rhs1(i) * v_rhs2(i), i = 1,,,dim.
value_type dot(const Vector &v_rhs1, const Vector &v_rhs2)
result = v_rhs1' * v_rhs2
SparseVectorSlice< SparseElement< index_type, value_type > > SpVectorSlice
void Vp_S(VectorMutable *v_lhs, const value_type &alpha)
v_lhs += alpha
value_type dot(const SpVectorSlice &sv_rhs1, const Vector &v_rhs2)
result = sv_rhs1' * v_rhs2
void max_abs_ele(const Vector &v, value_type *max_v_j, index_type *max_j)
Compute the maximum element in a vector.
value_type sum(const Vector &v_rhs)
result = sum( v_rhs(i), i = 1,,,dim )
const f_int f_dbl_prec const f_int f_int const f_int f_int const f_dbl_prec & u
void random_vector(value_type l, value_type u, VectorMutable *v)
Generate a random vector with elements uniformly distrubuted elements.