36 #include "../operations_vec.h"
42 template<
typename vector_t,
typename matrix_t>
44 const number &beta1,
const matrix_t &A1,
const vector_t &w1,
45 const number &alpha1,
const vector_t &v1)
52 template<
typename vector_t,
typename matrix_t>
54 const number &beta1,
const matrix_t &A1,
const vector_t &w1,
55 const number &alpha1,
const vector_t &v1,
56 const number &alpha2,
const vector_t &v2)
59 VecScaleAdd(dest, 1.0, dest, alpha1, v1, alpha2, v2);
65 template<
typename vector_t,
typename matrix_t>
67 const number &beta1,
const matrix_t &A1,
const vector_t &w1,
68 const number &beta2,
const matrix_t &A2,
const vector_t &w2)
76 template<
typename vector_t,
typename matrix_t>
78 const number &beta1,
const matrix_t &A1,
const vector_t &w1,
79 const number &beta2,
const matrix_t &A2,
const vector_t &w2,
80 const number &alpha1,
const vector_t &v1)
88 template<
typename vector_t,
typename matrix_t>
92 static inline bool MatMult(vector_t &dest,
93 const number &beta1,
const matrix_t &A1,
const vector_t &w1)
100 const number &alpha1,
const vector_t &v1,
101 const number &beta1,
const matrix_t &A1,
const vector_t &w1)
108 const number &alpha1,
const vector_t &v1,
109 const number &alpha2,
const vector_t &v2,
110 const number &beta1,
const matrix_t &A1,
const vector_t &w1)
117 const number &beta1,
const matrix_t &A1,
const vector_t &w1,
118 const number &beta2,
const matrix_t &A2,
const vector_t &w2)
125 const number &alpha1,
const vector_t &v1,
126 const number &beta1,
const matrix_t &A1,
const vector_t &w1,
127 const number &beta2,
const matrix_t &A2,
const vector_t &w2)
134 const number &beta1,
const matrix_t &A1,
const vector_t &w1)
141 const number &alpha1,
const vector_t &v1,
142 const number &beta1,
const matrix_t &A1,
const vector_t &w1)
144 return MatMultTransposedAddDirect(dest, alpha1, w1, beta1, A1, w1);
double number
Definition: types.h:124
void VecScaleAdd(vector_t &vOut, typename vector_t::value_type s1, const vector_t &v1, typename vector_t::value_type s2, const vector_t &v2)
Scales two Vectors, adds them and returns the sum in a third vector.
Definition: math_vector_functions_common_impl.hpp:265
@ MATRIX_USE_GLOBAL_FUNCTIONS
Definition: matrix_algebra_types.h:69
bool MatMultDirect(ParallelVector< vector_type > &dest, const number &beta1, const ParallelMatrix< matrix_type > &A1, const ParallelVector< vector_type > &w1)
Definition: parallel_matrix_impl.h:224
bool MatMultAddDirect(vector_t &dest, const number &beta1, const matrix_t &A1, const vector_t &w1, const number &alpha1, const vector_t &v1)
calculates dest = alpha1*v1 + beta1 * A1 *w1;
Definition: matrix_use_global_functions.h:43
void VecScaleAssign(double &dest, double alpha1, const double &v1)
calculates dest = alpha1*v1. for doubles
Definition: operations_vec.h:49
bool MatMultTransposed(vector_t &dest, const number &beta1, const matrix_t &A1, const vector_t &w1)
calculates dest = alpha1*v1 + beta1 * A1 *w1;
Definition: operations_mat.h:111
static bool MatMult(vector_t &dest, const number &beta1, const matrix_t &A1, const vector_t &w1)
calculates dest = beta1 * A1;
Definition: matrix_use_global_functions.h:92
static bool MatMultAdd(vector_t &dest, const number &alpha1, const vector_t &v1, const number &beta1, const matrix_t &A1, const vector_t &w1)
calculates dest = alpha1*v1 + beta1 * A1 *w1;
Definition: matrix_use_global_functions.h:99
static bool MatMultAdd(vector_t &dest, const number &alpha1, const vector_t &v1, const number &alpha2, const vector_t &v2, const number &beta1, const matrix_t &A1, const vector_t &w1)
calculates dest = alpha1*v1 + beta1 * A1 *w1 + alpha2*v2;
Definition: matrix_use_global_functions.h:107
static bool MatMultTransposedAdd(vector_t &dest, const number &alpha1, const vector_t &v1, const number &beta1, const matrix_t &A1, const vector_t &w1)
calculates dest = alpha1*v1 + beta1 * A1^T *w1;
Definition: matrix_use_global_functions.h:140
static bool MatMultTransposed(vector_t &dest, const number &beta1, const matrix_t &A1, const vector_t &w1)
calculates dest = beta1 * A1^T *w1;
Definition: matrix_use_global_functions.h:133
static bool MatMultAdd(vector_t &dest, const number &alpha1, const vector_t &v1, const number &beta1, const matrix_t &A1, const vector_t &w1, const number &beta2, const matrix_t &A2, const vector_t &w2)
calculates dest = beta1 * A1 *w1 + beta2 * A2*w2 + alpha1*v1;
Definition: matrix_use_global_functions.h:124
static bool MatMultAdd(vector_t &dest, const number &beta1, const matrix_t &A1, const vector_t &w1, const number &beta2, const matrix_t &A2, const vector_t &w2)
calculates dest = beta1 * A1 *w1 + beta2 * A2*w2;
Definition: matrix_use_global_functions.h:116
Definition: matrix_algebra_types.h:75