11#ifndef TLAPACK_BLAS_GERU_HH
12#define TLAPACK_BLAS_GERU_HH
38 class T = type_t<matrixA_t>,
39 disable_if_allow_optblas_t<pair<alpha_t, T>,
42 pair<vectorY_t, T> > = 0>
53 const idx_t m = nrows(
A);
54 const idx_t n = ncols(
A);
60 for (idx_t j = 0; j < n; ++j) {
62 for (idx_t i = 0; i < m; ++i)
63 A(i, j) +=
x[i] *
tmp;
67#ifdef TLAPACK_USE_LAPACKPP
73 class T = type_t<matrixA_t>,
74 enable_if_allow_optblas_t<pair<alpha_t, T>,
77 pair<vectorY_t, T> > = 0>
78void geru(
const alpha_t alpha,
84 auto A_ = legacy_matrix(A);
85 auto x_ = legacy_vector(x);
86 auto y_ = legacy_vector(y);
89 constexpr Layout L = layout<matrixA_t>;
93 return ::blas::geru((::blas::Layout)L, m, n, alpha, x_.ptr, x_.inc, y_.ptr,
94 y_.inc, A_.ptr, A_.ldim);
#define TLAPACK_SCALAR
Macro for tlapack::concepts::Scalar compatible with C++17.
Definition concepts.hpp:915
#define TLAPACK_LEGACY_VECTOR
Macro for tlapack::concepts::LegacyVector compatible with C++17.
Definition concepts.hpp:954
#define TLAPACK_LEGACY_MATRIX
Macro for tlapack::concepts::LegacyMatrix compatible with C++17.
Definition concepts.hpp:951
#define TLAPACK_VECTOR
Macro for tlapack::concepts::Vector compatible with C++17.
Definition concepts.hpp:906
#define TLAPACK_MATRIX
Macro for tlapack::concepts::Matrix compatible with C++17.
Definition concepts.hpp:896
void geru(const alpha_t &alpha, const vectorX_t &x, const vectorY_t &y, matrixA_t &A)
General matrix rank-1 update:
Definition geru.hpp:43
#define tlapack_check_false(cond)
Throw an error if cond is true.
Definition exceptionHandling.hpp:113
typename traits::real_type_traits< Types..., int >::type real_type
The common real type of the list of types.
Definition scalar_type_traits.hpp:113