35#ifndef _BLAZE_MATH_DENSE_INITIALIZERMATRIX_H_
36#define _BLAZE_MATH_DENSE_INITIALIZERMATRIX_H_
181template<
typename Type
184 :
public DenseMatrix< InitializerMatrix<Type,Tag>, false >
215 template<
typename NewType >
224 template<
size_t NewM
287 inline
size_t rows() const noexcept;
301 template< typename Other > inline
bool canAlias ( const Other* alias ) const noexcept;
302 template< typename Other > inline
bool isAliased( const Other* alias ) const noexcept;
350template< typename
Type
368template<
typename Type
385template<
typename Type
417template<
typename Type
427 if( j < list.size() )
428 return list.begin()[j];
446template<
typename Type
474template<
typename Type
479 return list_.begin()->begin();
492template<
typename Type
498 return list_.begin()[i].begin();
511template<
typename Type
530template<
typename Type
549template<
typename Type
568template<
typename Type
592template<
typename Type
606template<
typename Type
623template<
typename Type
637template<
typename Type
654template<
typename Type
674template<
typename Type
678 size_t nonzeros( 0 );
680 for(
const auto& rowList :
list_ ) {
681 for(
size_t i=0UL; i<rowList.size(); ++i ) {
701template<
typename Type
720template<
typename Type
751template<
typename Type
753template<
typename Other >
756 return static_cast<const void*
>( this ) ==
static_cast<const void*
>( alias );
771template<
typename Type
773template<
typename Other >
776 return static_cast<const void*
>( this ) ==
static_cast<const void*
>( alias );
792template<
typename Type,
typename Tag >
795template<
typename Type,
typename Tag >
818template<
typename Type
837template<
typename Type
856template<
typename T,
typename Tag >
857struct HasConstDataAccess< InitializerMatrix<T,Tag> >
874template<
typename T,
typename Tag >
892template<
typename T1,
typename Tag,
typename T2 >
895 using Type = InitializerMatrix< typename HighType<T1,T2>::Type, Tag >;
911template<
typename T1,
typename Tag,
typename T2 >
914 using Type = InitializerMatrix< typename LowType<T1,T2>::Type, Tag >;
Header file for run time assertion macros.
Constraint on the data type.
Header file for the HasConstDataAccess type trait.
Header file for the HighType type trait.
Header file for the InitializerIterator class template.
Header file for the IntegralConstant class template.
Header file for the IsInitializer type trait.
Header file for the LowType type trait.
Header file for the MAYBE_UNUSED function template.
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
Efficient implementation of a dynamic matrix.
Definition DynamicMatrix.h:242
Implementation of an iterator for (extended) initializer lists.
Definition InitializerIterator.h:57
Dense matrix representation of an initializer list.
Definition InitializerMatrix.h:185
InitializerMatrix< Type, Tag > This
Type of this InitializerMatrix instance.
Definition InitializerMatrix.h:188
DenseMatrix< This, false > BaseType
Base type of this InitializerMatrix instance.
Definition InitializerMatrix.h:189
size_t rows() const noexcept
InitializerIterator< Type > ConstIterator
Iterator over constant elements.
Definition InitializerMatrix.h:209
Type ElementType
Type of the matrix elements.
Definition InitializerMatrix.h:198
ConstIterator cbegin(size_t i) const noexcept
static constexpr bool smpAssignable
Definition InitializerMatrix.h:243
bool canAlias(const Other *alias) const noexcept
ConstPointer data() const noexcept
Low-level data access to the matrix elements.
Definition InitializerMatrix.h:477
ConstReference operator()(size_t i, size_t j) const noexcept
2D-access to the matrix elements.
Definition InitializerMatrix.h:420
const Type * ConstPointer
Pointer to a constant matrix value.
Definition InitializerMatrix.h:206
const Type & Reference
Reference to a non-constant matrix value.
Definition InitializerMatrix.h:203
size_t spacing() const noexcept
ConstIterator end(size_t i) const noexcept
Tag TagType
Tag type of this InitializerVector instance.
Definition InitializerMatrix.h:199
size_t m_
Definition InitializerMatrix.h:314
bool isAliased(const Other *alias) const noexcept
size_t columns() const noexcept
static constexpr bool simdEnabled
Definition InitializerMatrix.h:237
DynamicMatrix< Type, true > OppositeType
Result type with opposite storage order for expression template evaluations.
Definition InitializerMatrix.h:195
void swap(InitializerMatrix &m) noexcept
ConstIterator cend(size_t i) const noexcept
ConstReference at(size_t i, size_t j) const
Checked access to the matrix elements.
Definition InitializerMatrix.h:449
InitializerMatrix(initializer_list< initializer_list< Type > > list) noexcept
Constructor for InitializerMatrix.
Definition InitializerMatrix.h:370
DynamicMatrix< Type, false > ResultType
Result type for expression template evaluations.
Definition InitializerMatrix.h:192
DynamicMatrix< Type, true > TransposeType
Transpose type for expression template evaluations.
Definition InitializerMatrix.h:197
const Type & ConstReference
Reference to a constant matrix value.
Definition InitializerMatrix.h:204
static const NewType zero_
Definition InitializerMatrix.h:326
size_t capacity() const noexcept
InitializerMatrix(initializer_list< initializer_list< Type > > list, size_t n)
Constructor for InitializerMatrix.
Definition InitializerMatrix.h:387
size_t n_
Definition InitializerMatrix.h:315
InitializerIterator< Type > Iterator
Iterator over non-constant elements.
Definition InitializerMatrix.h:208
const This & CompositeType
Data type for composite expression templates.
Definition InitializerMatrix.h:201
ListType list_
Definition InitializerMatrix.h:316
const Type * Pointer
Pointer to a non-constant matrix value.
Definition InitializerMatrix.h:205
initializer_list< initializer_list< NewType > > ListType
Definition InitializerMatrix.h:308
const Type & ReturnType
Return type for expression template evaluations.
Definition InitializerMatrix.h:200
ConstIterator begin(size_t i) const noexcept
Initializer list type of the Blaze library.
Header file for the DenseMatrix base class.
#define BLAZE_CONSTRAINT_MUST_NOT_BE_VOLATILE(T)
Constraint on the data type.
Definition Volatile.h:79
#define BLAZE_CONSTRAINT_MUST_NOT_BE_POINTER_TYPE(T)
Constraint on the data type.
Definition Pointer.h:79
#define BLAZE_CONSTRAINT_MUST_NOT_BE_CONST(T)
Constraint on the data type.
Definition Const.h:79
#define BLAZE_CONSTRAINT_MUST_NOT_BE_REFERENCE_TYPE(T)
Constraint on the data type.
Definition Reference.h:79
bool isIntact(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the invariants of the given diagonal matrix are intact.
Definition DiagonalMatrix.h:207
void swap(DiagonalMatrix< MT, SO, DF > &a, DiagonalMatrix< MT, SO, DF > &b) noexcept
Swapping the contents of two matrices.
Definition DiagonalMatrix.h:225
bool isDefault(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the given diagonal matrix is in default state.
Definition DiagonalMatrix.h:169
constexpr size_t determineColumns(initializer_list< initializer_list< Type > > list) noexcept
Determines the maximum number of columns specified by the given initializer list.
Definition InitializerList.h:107
size_t nonZeros(const Matrix< MT, SO > &matrix)
Returns the total number of non-zero elements in the matrix.
Definition Matrix.h:730
constexpr size_t size(const Matrix< MT, SO > &matrix) noexcept
Returns the total number of elements of the matrix.
Definition Matrix.h:676
#define BLAZE_USER_ASSERT(expr, msg)
Run time assertion macro for user checks.
Definition Assert.h:117
constexpr void MAYBE_UNUSED(const Args &...)
Suppression of unused parameter warnings.
Definition MaybeUnused.h:81
BoolConstant< true > TrueType
Type traits base class.
Definition IntegralConstant.h:132
#define BLAZE_THROW_OUT_OF_RANGE(MESSAGE)
Macro for the emission of a std::out_of_range exception.
Definition Exception.h:331
#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 all forward declarations of the math module.
Header file for the extended initializer_list functionality.
Base template for the HighType type trait.
Definition HighType.h:322
Rebind mechanism to obtain a InitializerMatrix with different data/element type.
Definition InitializerMatrix.h:216
InitializerMatrix< NewType, Tag > Other
The type of the other InitializerMatrix.
Definition InitializerMatrix.h:217
Resize mechanism to obtain a InitializerMatrix with different fixed dimensions.
Definition InitializerMatrix.h:226
InitializerMatrix< Type, Tag > Other
The type of the other InitializerMatrix.
Definition InitializerMatrix.h:227
Compile time check for custom data types.
Definition IsInitializer.h:83
Base template for the LowType type trait.
Definition LowType.h:322
Header file for basic type definitions.