35#ifndef _BLAZE_MATH_SUBVECTOR_H_
36#define _BLAZE_MATH_SUBVECTOR_H_
75class Rand< Subvector<VT,AF,TF,true,CSAs...> >
84 template<
typename SVT >
94 for(
size_t i=0UL; i<
subvector.size(); ++i ) {
108 template<
typename SVT
119 for(
size_t i=0UL; i<
subvector.size(); ++i ) {
148class Rand< Subvector<VT,AF,TF,false,CSAs...> >
157 template<
typename SVT >
161 using ElementType = ElementType_t<SubvectorType>;
168 if(
size == 0UL )
return;
175 while(
subvector.nonZeros() < nonzeros ) {
189 template<
typename SVT >
193 using ElementType = ElementType_t<SubvectorType>;
200 if( nonzeros >
size ) {
204 if(
size == 0UL )
return;
209 while(
subvector.nonZeros() < nonzeros ) {
223 template<
typename SVT
228 using ElementType = ElementType_t<SubvectorType>;
235 if(
size == 0UL )
return;
242 while(
subvector.nonZeros() < nonzeros ) {
258 template<
typename SVT
263 using ElementType = ElementType_t<SubvectorType>;
270 if( nonzeros >
size ) {
274 if(
size == 0UL )
return;
279 while(
subvector.nonZeros() < nonzeros ) {
Header file for auxiliary alias declarations.
Header file for the RemoveReference type trait.
Default implementation of the Rand class.
Definition Random.h:230
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
decltype(auto) min(const DenseMatrix< MT1, SO1 > &lhs, const DenseMatrix< MT2, SO2 > &rhs)
Computes the componentwise minimum of the dense matrices lhs and rhs.
Definition DMatDMatMapExpr.h:1339
decltype(auto) max(const DenseMatrix< MT1, SO1 > &lhs, const DenseMatrix< MT2, SO2 > &rhs)
Computes the componentwise maximum of the dense matrices lhs and rhs.
Definition DMatDMatMapExpr.h:1375
#define BLAZE_CONSTRAINT_MUST_BE_SPARSE_VECTOR_TYPE(T)
Constraint on the data type.
Definition SparseVector.h:61
#define BLAZE_CONSTRAINT_MUST_BE_DENSE_VECTOR_TYPE(T)
Constraint on the data type.
Definition DenseVector.h:61
#define BLAZE_CONSTRAINT_MUST_BE_SUBVECTOR_TYPE(T)
Constraint on the data type.
Definition Subvector.h:61
AlignmentFlag
Alignment flag for (un-)aligned vectors and matrices.
Definition AlignmentFlag.h:63
constexpr size_t size(const Matrix< MT, SO > &matrix) noexcept
Returns the total number of elements of the matrix.
Definition Matrix.h:676
T rand()
Random number function.
Definition Random.h:583
void randomize(T &&value)
Randomization of a given variable.
Definition Random.h:626
decltype(auto) subvector(Vector< VT, TF > &, RSAs...)
Creating a view on a specific subvector of the given vector.
Definition Subvector.h:158
typename RemoveReference< T >::Type RemoveReference_t
Auxiliary alias declaration for the RemoveReference type trait.
Definition RemoveReference.h:95
#define BLAZE_THROW_INVALID_ARGUMENT(MESSAGE)
Macro for the emission of a std::invalid_argument exception.
Definition Exception.h:235
Header file for the exception macros of the math module.
Header file for the dense vector SMP implementation.
Header file for the sparse vector SMP implementation.
Implementation of a random number generator.
Header file for the implementation of the Submatrix view.
Header file for the implementation of the Subvector view.