35#ifndef _BLAZE_MATH_EXPRESSIONS_TSMATTDMATMULTEXPR_H_
36#define _BLAZE_MATH_EXPRESSIONS_TSMATTDMATMULTEXPR_H_
122template<
typename MT1
129 :
public MatMatMultExpr< DenseMatrix< TSMatTDMatMultExpr<MT1,MT2,SF,HF,LF,UF>, true > >
153 static constexpr bool SYM = ( SF && !( HF || LF || UF ) );
154 static constexpr bool HERM = ( HF && !( LF || UF ) );
155 static constexpr bool LOW = ( LF || ( ( SF || HF ) && UF ) );
156 static constexpr bool UPP = ( UF || ( ( SF || HF ) && LF ) );
166 template<
typename T1,
typename T2,
typename T3 >
177 template<
typename T1,
typename T2,
typename T3 >
178 static constexpr bool IsEvaluationRequired_v =
188 template<
typename T1,
typename T2,
typename T3 >
189 static constexpr bool UseOptimizedKernel_v =
190 ( useOptimizedKernels &&
202 template<
typename T1,
typename T2,
typename T3 >
203 static constexpr bool UseDefaultKernel_v = !UseOptimizedKernel_v<T1,T2,T3>;
322 :(
lhs_.columns() ) ) );
346 if( i >=
lhs_.rows() ) {
349 if( j >=
rhs_.columns() ) {
361 inline size_t rows() const noexcept {
372 return rhs_.columns();
402 template<
typename T >
403 inline bool canAlias(
const T* alias )
const noexcept {
404 return (
lhs_.isAliased( alias ) ||
rhs_.isAliased( alias ) );
414 template<
typename T >
415 inline bool isAliased(
const T* alias )
const noexcept {
416 return (
lhs_.isAliased( alias ) ||
rhs_.isAliased( alias ) );
426 return rhs_.isAligned();
459 template<
typename MT
479 TSMatTDMatMultExpr::selectAssignKernel( *lhs, A, B );
495 template<
typename MT3
498 static inline void selectAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
500 const size_t size( C.rows() * C.columns() );
504 selectSmallAssignKernel( C, A, B );
506 selectLargeAssignKernel( C, A, B );
526 template<
typename MT3
529 static inline void selectDefaultAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
535 for(
size_t i=0UL; i<A.columns(); ++i )
537 const auto end( A.end(i) );
538 auto element( A.begin(i) );
540 for( ; element!=
end; ++element ) {
541 C(element->index(),i) = element->value() * B(i,i);
547 const size_t block( 64UL );
549 for(
size_t jj=0UL; jj<B.columns(); jj+=block )
551 const size_t jpos( ( jj+block > B.columns() )?( B.columns() ):( jj+block ) );
553 for(
size_t i=0UL; i<A.columns(); ++i )
555 const auto end( A.end(i) );
556 auto element( A.begin(i) );
558 for( ; element!=
end; ++element )
560 const size_t i1( element->index() );
571 :(
LOW ?
min(i1+1UL,jpos) : jpos ) );
576 for(
size_t j=jbegin; j<jend; ++j ) {
578 C(i1,j) = element->value() * B(i,j);
580 C(i1,j) += element->value() * B(i,j);
588 for(
size_t j=0UL; j<B.columns(); ++j ) {
589 for(
size_t i=j+1UL; i<A.rows(); ++i ) {
590 C(i,j) =
HERM ?
conj( C(j,i) ) : C(j,i);
612 template<
typename MT3
615 static inline auto selectSmallAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
618 selectDefaultAssignKernel( C, A, B );
638 template<
typename MT3
641 static inline auto selectSmallAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
646 for(
size_t jj=0UL; jj<B.columns(); jj+=block )
648 const size_t jpos( ( jj+block > B.columns() )?( B.columns() ):( jj+block ) );
650 for(
size_t i=0UL; i<A.rows(); ++i ) {
651 for(
size_t j=jj; j<jpos; ++j ) {
656 for(
size_t i=0UL; i<A.columns(); ++i )
658 const auto end( A.end(i) );
659 auto element( A.begin(i) );
661 const size_t nonzeros( A.nonZeros(i) );
665 for(
size_t k=0UL; k<kpos; k+=4UL )
667 const size_t i1( element->index() );
668 const ET1 v1( element->value() );
670 const size_t i2( element->index() );
671 const ET1 v2( element->value() );
673 const size_t i3( element->index() );
674 const ET1 v3( element->value() );
676 const size_t i4( element->index() );
677 const ET1 v4( element->value() );
691 :(
LOW ?
min(i4+1UL,jpos) : jpos ) );
696 for(
size_t j=jbegin; j<jend; ++j ) {
697 C(i1,j) += v1 * B(i,j);
698 C(i2,j) += v2 * B(i,j);
699 C(i3,j) += v3 * B(i,j);
700 C(i4,j) += v4 * B(i,j);
704 for( ; element!=
end; ++element )
706 const size_t i1( element->index() );
717 :(
LOW ?
min(i1+1UL,jpos) : jpos ) );
722 for(
size_t j=jbegin; j<jend; ++j ) {
723 C(i1,j) += element->value() * B(i,j);
730 for(
size_t j=0UL; j<B.columns(); ++j ) {
731 for(
size_t i=j+1UL; i<A.rows(); ++i ) {
732 C(i,j) =
HERM ?
conj( C(j,i) ) : C(j,i);
754 template<
typename MT3
757 static inline auto selectLargeAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
760 selectDefaultAssignKernel( C, A, B );
780 template<
typename MT3
783 static inline auto selectLargeAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
788 const ForwardFunctor fwd;
790 const OppositeType_t<MT4> tmp(
serial( A ) );
791 assign( C, fwd( tmp * B ) );
809 template<
typename MT
828 const ForwardFunctor fwd;
830 const TmpType tmp(
serial( rhs ) );
831 assign( *lhs, fwd( tmp ) );
851 template<
typename MT
863 const ForwardFunctor fwd;
868 assign( *lhs, fwd( A * B ) );
886 template<
typename MT
888 friend inline auto addAssign( DenseMatrix<MT,SO>& lhs,
const TSMatTDMatMultExpr& rhs )
906 TSMatTDMatMultExpr::selectAddAssignKernel( *lhs, A, B );
922 template<
typename MT3
925 static inline void selectAddAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
927 const size_t size( C.rows() * C.columns() );
931 selectSmallAddAssignKernel( C, A, B );
933 selectLargeAddAssignKernel( C, A, B );
953 template<
typename MT3
956 static inline void selectDefaultAddAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
960 for(
size_t i=0UL; i<A.columns(); ++i )
962 const auto end( A.end(i) );
963 auto element( A.begin(i) );
965 for( ; element!=
end; ++element ) {
966 C(element->index(),i) += element->value() * B(i,i);
972 const size_t block( 64UL );
974 for(
size_t jj=0UL; jj<B.columns(); jj+=block )
976 const size_t jpos( ( jj+block > B.columns() )?( B.columns() ):( jj+block ) );
978 for(
size_t i=0UL; i<A.columns(); ++i )
980 const auto end( A.end(i) );
981 auto element( A.begin(i) );
983 for( ; element!=
end; ++element )
985 const size_t i1( element->index() );
991 :(
UPP ?
max(i1,jj) : jj ) );
996 :(
LOW ?
min(i1+1UL,jpos) : jpos ) );
1001 for(
size_t j=jbegin; j<jend; ++j ) {
1002 C(i1,j) += element->value() * B(i,j);
1026 template<
typename MT3
1029 static inline auto selectSmallAddAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1032 selectDefaultAddAssignKernel( C, A, B );
1052 template<
typename MT3
1055 static inline auto selectSmallAddAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1060 for(
size_t jj=0UL; jj<B.columns(); jj+=block )
1062 const size_t jpos( ( jj+block > B.columns() )?( B.columns() ):( jj+block ) );
1064 for(
size_t i=0UL; i<A.columns(); ++i )
1066 const auto end( A.end(i) );
1067 auto element( A.begin(i) );
1069 const size_t nonzeros( A.nonZeros(i) );
1073 for(
size_t k=0UL; k<kpos; k+=4UL )
1075 const size_t i1( element->index() );
1076 const ET1 v1( element->value() );
1078 const size_t i2( element->index() );
1079 const ET1 v2( element->value() );
1081 const size_t i3( element->index() );
1082 const ET1 v3( element->value() );
1084 const size_t i4( element->index() );
1085 const ET1 v4( element->value() );
1094 :(
UPP ?
max(i1,jj) : jj ) );
1099 :(
LOW ?
min(i4+1UL,jpos) : jpos ) );
1101 if( jbegin >= jend )
1104 for(
size_t j=jbegin; j<jend; ++j ) {
1105 C(i1,j) += v1 * B(i,j);
1106 C(i2,j) += v2 * B(i,j);
1107 C(i3,j) += v3 * B(i,j);
1108 C(i4,j) += v4 * B(i,j);
1112 for( ; element!=
end; ++element )
1114 const size_t i1( element->index() );
1120 :(
UPP ?
max(i1,jj) : jj ) );
1125 :(
LOW ?
min(i1+1UL,jpos) : jpos ) );
1127 if( jbegin >= jend )
1130 for(
size_t j=jbegin; j<jend; ++j ) {
1131 C(i1,j) += element->value() * B(i,j);
1154 template<
typename MT3
1157 static inline auto selectLargeAddAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1160 selectDefaultAddAssignKernel( C, A, B );
1180 template<
typename MT3
1183 static inline auto selectLargeAddAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1188 const ForwardFunctor fwd;
1190 const OppositeType_t<MT4> tmp(
serial( A ) );
1191 addAssign( C, fwd( tmp * B ) );
1211 template<
typename MT
1223 const ForwardFunctor fwd;
1228 addAssign( *lhs, fwd( A * B ) );
1250 template<
typename MT
1252 friend inline auto subAssign( DenseMatrix<MT,SO>& lhs,
const TSMatTDMatMultExpr& rhs )
1270 TSMatTDMatMultExpr::selectSubAssignKernel( *lhs, A, B );
1286 template<
typename MT3
1289 static inline void selectSubAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1291 const size_t size( C.rows() * C.columns() );
1295 selectSmallSubAssignKernel( C, A, B );
1297 selectLargeSubAssignKernel( C, A, B );
1317 template<
typename MT3
1320 static inline void selectDefaultSubAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1324 for(
size_t i=0UL; i<A.columns(); ++i )
1326 const auto end( A.end(i) );
1327 auto element( A.begin(i) );
1329 for( ; element!=
end; ++element ) {
1330 C(element->index(),i) -= element->value() * B(i,i);
1336 const size_t block( 64UL );
1338 for(
size_t jj=0UL; jj<B.columns(); jj+=block )
1340 const size_t jpos( ( jj+block > B.columns() )?( B.columns() ):( jj+block ) );
1342 for(
size_t i=0UL; i<A.columns(); ++i )
1344 const auto end( A.end(i) );
1345 auto element( A.begin(i) );
1347 for( ; element!=
end; ++element )
1349 const size_t i1( element->index() );
1355 :(
UPP ?
max(i1,jj) : jj ) );
1360 :(
LOW ?
min(i1+1UL,jpos) : jpos ) );
1362 if( jbegin >= jend )
1365 for(
size_t j=jbegin; j<jend; ++j ) {
1366 C(i1,j) -= element->value() * B(i,j);
1390 template<
typename MT3
1393 static inline auto selectSmallSubAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1396 selectDefaultSubAssignKernel( C, A, B );
1416 template<
typename MT3
1419 static inline auto selectSmallSubAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1424 for(
size_t jj=0UL; jj<B.columns(); jj+=block )
1426 const size_t jpos( ( jj+block > B.columns() )?( B.columns() ):( jj+block ) );
1428 for(
size_t i=0UL; i<A.columns(); ++i )
1430 const auto end( A.end(i) );
1431 auto element( A.begin(i) );
1433 const size_t nonzeros( A.nonZeros(i) );
1437 for(
size_t k=0UL; k<kpos; k+=4UL )
1439 const size_t i1( element->index() );
1440 const ET1 v1( element->value() );
1442 const size_t i2( element->index() );
1443 const ET1 v2( element->value() );
1445 const size_t i3( element->index() );
1446 const ET1 v3( element->value() );
1448 const size_t i4( element->index() );
1449 const ET1 v4( element->value() );
1458 :(
UPP ?
max(i1,jj) : jj ) );
1463 :(
LOW ?
min(i4+1UL,jpos) : jpos ) );
1465 if( jbegin >= jend )
1468 for(
size_t j=jbegin; j<jend; ++j ) {
1469 C(i1,j) -= v1 * B(i,j);
1470 C(i2,j) -= v2 * B(i,j);
1471 C(i3,j) -= v3 * B(i,j);
1472 C(i4,j) -= v4 * B(i,j);
1476 for( ; element!=
end; ++element )
1478 const size_t i1( element->index() );
1484 :(
UPP ?
max(i1,jj) : jj ) );
1489 :(
LOW ?
min(i1+1UL,jpos) : jpos ) );
1491 if( jbegin >= jend )
1494 for(
size_t j=jbegin; j<jend; ++j ) {
1495 C(i1,j) -= element->value() * B(i,j);
1518 template<
typename MT3
1521 static inline auto selectLargeSubAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1524 selectDefaultSubAssignKernel( C, A, B );
1544 template<
typename MT3
1547 static inline auto selectLargeSubAssignKernel( MT3& C,
const MT4& A,
const MT5& B )
1552 const ForwardFunctor fwd;
1554 const OppositeType_t<MT4> tmp(
serial( A ) );
1555 subAssign( C, fwd( tmp * B ) );
1575 template<
typename MT
1587 const ForwardFunctor fwd;
1592 subAssign( *lhs, fwd( A * B ) );
1614 template<
typename MT
1616 friend inline void schurAssign( DenseMatrix<MT,SO>& lhs,
const TSMatTDMatMultExpr& rhs )
1628 schurAssign( *lhs, tmp );
1661 template<
typename MT
1702 template<
typename MT
1721 const ForwardFunctor fwd;
1723 const TmpType tmp( rhs );
1744 template<
typename MT
1756 const ForwardFunctor fwd;
1782 template<
typename MT
1822 template<
typename MT
1834 const ForwardFunctor fwd;
1864 template<
typename MT
1904 template<
typename MT
1916 const ForwardFunctor fwd;
1943 template<
typename MT
2009template<
typename MT1
2041template<
typename MT1
2073template<
typename MT1
2076inline decltype(
auto)
2088 return ReturnType( (*lhs).rows(), (*rhs).columns() );
2123template<
typename MT1
2125inline decltype(
auto)
2130 if( (*lhs).columns() != (*rhs).rows() ) {
2134 return tsmattdmatmult( *lhs, *rhs );
2171template<
typename MT1
2177inline decltype(
auto)
declsym(
const TSMatTDMatMultExpr<MT1,MT2,SF,HF,LF,UF>& dm )
2186 return ReturnType( dm.leftOperand(), dm.rightOperand() );
2216template<
typename MT1
2231 return ReturnType( dm.leftOperand(), dm.rightOperand() );
2261template<
typename MT1
2276 return ReturnType( dm.leftOperand(), dm.rightOperand() );
2306template<
typename MT1
2349template<
typename MT1
2392template<
typename MT1
2407 return ReturnType( dm.leftOperand(), dm.rightOperand() );
2437template<
typename MT1
2480template<
typename MT1
2523template<
typename MT1
2538 return ReturnType( dm.leftOperand(), dm.rightOperand() );
2554template<
typename MT1,
typename MT2,
bool SF,
bool HF,
bool LF,
bool UF >
2556 :
public Size<MT1,0UL>
2559template<
typename MT1,
typename MT2,
bool SF,
bool HF,
bool LF,
bool UF >
2561 :
public Size<MT2,1UL>
2577template<
typename MT1,
typename MT2,
bool SF,
bool HF,
bool LF,
bool UF >
Header file for auxiliary alias declarations.
typename T::OppositeType OppositeType_t
Alias declaration for nested OppositeType type definitions.
Definition Aliases.h:310
typename T::CompositeType CompositeType_t
Alias declaration for nested CompositeType type definitions.
Definition Aliases.h:110
typename T::TransposeType TransposeType_t
Alias declaration for nested TransposeType type definitions.
Definition Aliases.h:550
typename T::ElementType ElementType_t
Alias declaration for nested ElementType type definitions.
Definition Aliases.h:190
typename T::ResultType ResultType_t
Alias declaration for nested ResultType type definitions.
Definition Aliases.h:450
Header file for run time assertion macros.
Header file for the blaze::checked and blaze::unchecked instances.
Constraints on the storage order of matrix types.
Header file for the conjugate shim.
Header file for the decldiag trait.
Header file for the DeclDiag functor.
Header file for the declherm trait.
Header file for the DeclHerm functor.
Header file for the decllow trait.
Header file for the DeclLow functor.
Header file for the declsym trait.
Header file for the DeclSym functor.
Header file for the declupp trait.
Header file for the DeclUpp functor.
Header file for the EnableIf class template.
Header file for the function trace functionality.
Header file for the If class template.
Header file for the IntegralConstant class template.
Header file for the IsAligned type trait.
Header file for the IsBuiltin type trait.
Header file for the IsColumnMajorMatrix type trait.
Header file for the IsComputation type trait class.
Header file for the isDefault shim.
Header file for the IsDiagonal type trait.
Header file for the IsExpression type trait class.
Header file for the IsIdentity type trait.
Header file for the IsLower type trait.
Header file for the IsResizable type trait.
Header file for the IsRowMajorMatrix type trait.
Header file for the IsStrictlyLower type trait.
Header file for the IsStrictlyUpper type trait.
Header file for the IsSymmetric type trait.
Header file for the IsTriangular type trait.
Header file for the IsUpper type trait.
Header file for the MAYBE_UNUSED function template.
Header file for the multiplication trait.
Header file for the Noop functor.
Header file for the prevMultiple shim.
Constraints on the storage order of matrix types.
Constraint on the data type.
Constraint on the data type.
Base class for dense matrices.
Definition DenseMatrix.h:82
Base class for sparse matrices.
Definition SparseMatrix.h:77
Expression object for transpose sparse matrix-transpose dense matrix multiplications.
Definition TSMatTDMatMultExpr.h:131
RightOperand rightOperand() const noexcept
Returns the right-hand side transpose dense matrix operand.
Definition TSMatTDMatMultExpr.h:391
static constexpr bool evaluateRight
Compilation switch for the composite type of the right-hand side dense matrix expression.
Definition TSMatTDMatMultExpr.h:149
ElementType_t< RT1 > ET1
Element type of the left-hand side dense matrix expression.
Definition TSMatTDMatMultExpr.h:136
bool isAligned() const noexcept
Returns whether the operands of the expression are properly aligned in memory.
Definition TSMatTDMatMultExpr.h:425
If_t< IsExpression_v< MT2 >, const MT2, const MT2 & > RightOperand
Composite type of the right-hand side dense matrix expression.
Definition TSMatTDMatMultExpr.h:257
typename If_t< HERM, DeclHermTrait< MultTrait_t< RT1, RT2 > >, If_t< SYM, DeclSymTrait< MultTrait_t< RT1, RT2 > >, If_t< LOW, If_t< UPP, DeclDiagTrait< MultTrait_t< RT1, RT2 > >, DeclLowTrait< MultTrait_t< RT1, RT2 > > >, If_t< UPP, DeclUppTrait< MultTrait_t< RT1, RT2 > >, MultTrait< RT1, RT2 > > > > >::Type ResultType
Result type for expression template evaluations.
Definition TSMatTDMatMultExpr.h:235
static constexpr bool SYM
Flag for symmetric matrices.
Definition TSMatTDMatMultExpr.h:153
static constexpr bool simdEnabled
Compilation switch for the expression template evaluation strategy.
Definition TSMatTDMatMultExpr.h:268
OppositeType_t< ResultType > OppositeType
Result type with opposite storage order for expression template evaluations.
Definition TSMatTDMatMultExpr.h:247
size_t rows() const noexcept
Returns the current number of rows of the matrix.
Definition TSMatTDMatMultExpr.h:361
CompositeType_t< MT1 > CT1
Composite type of the left-hand side sparse matrix expression.
Definition TSMatTDMatMultExpr.h:138
static constexpr bool LOW
Flag for lower matrices.
Definition TSMatTDMatMultExpr.h:155
ElementType_t< ResultType > ElementType
Resulting element type.
Definition TSMatTDMatMultExpr.h:249
MatMatMultExpr< DenseMatrix< This, true > > BaseType
Base type of this TSMatTDMatMultExpr instance.
Definition TSMatTDMatMultExpr.h:232
static constexpr bool evaluateLeft
Compilation switch for the composite type of the left-hand side sparse matrix expression.
Definition TSMatTDMatMultExpr.h:144
CompositeType_t< MT2 > CT2
Composite type of the right-hand side dense matrix expression.
Definition TSMatTDMatMultExpr.h:139
ResultType_t< MT1 > RT1
Result type of the left-hand side sparse matrix expression.
Definition TSMatTDMatMultExpr.h:134
size_t columns() const noexcept
Returns the current number of columns of the matrix.
Definition TSMatTDMatMultExpr.h:371
TSMatTDMatMultExpr< MT1, MT2, SF, HF, LF, UF > This
Type of this TSMatTDMatMultExpr instance.
Definition TSMatTDMatMultExpr.h:229
const ResultType CompositeType
Data type for composite expression templates.
Definition TSMatTDMatMultExpr.h:251
static constexpr bool UPP
Flag for upper matrices.
Definition TSMatTDMatMultExpr.h:156
TSMatTDMatMultExpr(const MT1 &lhs, const MT2 &rhs) noexcept
Constructor for the TSMatTDMatMultExpr class.
Definition TSMatTDMatMultExpr.h:281
LeftOperand leftOperand() const noexcept
Returns the left-hand side transpose sparse matrix operand.
Definition TSMatTDMatMultExpr.h:381
RightOperand rhs_
Right-hand side dense matrix of the multiplication expression.
Definition TSMatTDMatMultExpr.h:443
bool isAliased(const T *alias) const noexcept
Returns whether the expression is aliased with the given address alias.
Definition TSMatTDMatMultExpr.h:415
ResultType_t< MT2 > RT2
Result type of the right-hand side dense matrix expression.
Definition TSMatTDMatMultExpr.h:135
bool canSMPAssign() const noexcept
Returns whether the expression can be used in SMP assignments.
Definition TSMatTDMatMultExpr.h:435
ElementType_t< RT2 > ET2
Element type of the right-hand side sparse matrix expression.
Definition TSMatTDMatMultExpr.h:137
If_t< evaluateRight, const RT2, CT2 > RT
Type for the assignment of the right-hand side dense matrix operand.
Definition TSMatTDMatMultExpr.h:263
ReturnType at(size_t i, size_t j) const
Checked access to the matrix elements.
Definition TSMatTDMatMultExpr.h:345
const ElementType ReturnType
Return type for expression template evaluations.
Definition TSMatTDMatMultExpr.h:250
If_t< evaluateLeft, const RT1, CT1 > LT
Type for the assignment of the left-hand side sparse matrix operand.
Definition TSMatTDMatMultExpr.h:260
LeftOperand lhs_
Left-hand side sparse matrix of the multiplication expression.
Definition TSMatTDMatMultExpr.h:442
ReturnType operator()(size_t i, size_t j) const
2D-access to the matrix elements.
Definition TSMatTDMatMultExpr.h:296
bool canAlias(const T *alias) const noexcept
Returns whether the expression can alias with the given address alias.
Definition TSMatTDMatMultExpr.h:403
TransposeType_t< ResultType > TransposeType
Transpose type for expression template evaluations.
Definition TSMatTDMatMultExpr.h:248
static constexpr bool HERM
Flag for Hermitian matrices.
Definition TSMatTDMatMultExpr.h:154
If_t< IsExpression_v< MT1 >, const MT1, const MT1 & > LeftOperand
Composite type of the left-hand side sparse matrix expression.
Definition TSMatTDMatMultExpr.h:254
static constexpr bool smpAssignable
Compilation switch for the expression template assignment strategy.
Definition TSMatTDMatMultExpr.h:271
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
Header file for the Computation base class.
Header file for the DenseMatrix base class.
Header file for the MatMatMultExpr base class.
decltype(auto) column(Matrix< MT, SO > &matrix, RCAs... args)
Creating a view on a specific column of the given matrix.
Definition Column.h:137
decltype(auto) transIf(const DenseMatrix< MT, SO > &dm)
Conditional calculation of the transpose of the given dense matrix.
Definition DMatTransExpr.h:832
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
decltype(auto) declstrupp(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as strictly upper.
Definition DMatDeclStrUppExpr.h:1003
decltype(auto) conj(const DenseMatrix< MT, SO > &dm)
Returns a matrix containing the complex conjugate of each single element of dm.
Definition DMatMapExpr.h:1464
decltype(auto) decldiag(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as diagonal.
Definition DMatDeclDiagExpr.h:978
decltype(auto) declstrlow(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as strictly lower.
Definition DMatDeclStrLowExpr.h:1003
decltype(auto) serial(const DenseMatrix< MT, SO > &dm)
Forces the serial evaluation of the given dense matrix expression dm.
Definition DMatSerialExpr.h:812
decltype(auto) declupp(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as upper.
Definition DMatDeclUppExpr.h:1004
decltype(auto) decllow(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as lower.
Definition DMatDeclLowExpr.h:1004
decltype(auto) decluniupp(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as uniupper.
Definition DMatDeclUniUppExpr.h:1005
decltype(auto) declherm(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as Hermitian.
Definition DMatDeclHermExpr.h:1005
decltype(auto) declsym(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as symmetric.
Definition DMatDeclSymExpr.h:1005
decltype(auto) declunilow(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as unilower.
Definition DMatDeclUniLowExpr.h:1004
bool isDefault(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the given diagonal matrix is in default state.
Definition DiagonalMatrix.h:169
#define BLAZE_CONSTRAINT_MUST_NOT_BE_SYMMETRIC_MATRIX_TYPE(T)
Constraint on the data type.
Definition Symmetric.h:79
#define BLAZE_CONSTRAINT_MUST_BE_ROW_MAJOR_MATRIX_TYPE(T)
Constraint on the data type.
Definition RowMajorMatrix.h:61
#define BLAZE_CONSTRAINT_MATRICES_MUST_HAVE_SAME_STORAGE_ORDER(T1, T2)
Constraint on the data type.
Definition StorageOrder.h:84
#define BLAZE_CONSTRAINT_MUST_NOT_REQUIRE_EVALUATION(T)
Constraint on the data type.
Definition RequiresEvaluation.h:81
#define BLAZE_CONSTRAINT_MUST_FORM_VALID_MATMATMULTEXPR(T1, T2)
Constraint on the data type.
Definition MatMatMultExpr.h:103
#define BLAZE_CONSTRAINT_MUST_NOT_BE_ZERO_TYPE(T)
Constraint on the data type.
Definition Zero.h:81
#define BLAZE_CONSTRAINT_MUST_BE_DENSE_MATRIX_TYPE(T)
Constraint on the data type.
Definition DenseMatrix.h:61
#define BLAZE_CONSTRAINT_MUST_BE_SPARSE_MATRIX_TYPE(T)
Constraint on the data type.
Definition SparseMatrix.h:61
#define BLAZE_CONSTRAINT_MUST_BE_COLUMN_MAJOR_MATRIX_TYPE(T)
Constraint on the data type.
Definition ColumnMajorMatrix.h:61
#define BLAZE_CONSTRAINT_MUST_BE_ZERO_TYPE(T)
Constraint on the data type.
Definition Zero.h:61
typename MultTrait< T1, T2 >::Type MultTrait_t
Auxiliary alias declaration for the MultTrait class template.
Definition MultTrait.h:165
constexpr bool RequiresEvaluation_v
Auxiliary variable template for the RequiresEvaluation type trait.
Definition RequiresEvaluation.h:91
constexpr bool IsStrictlyUpper_v
Auxiliary variable template for the IsStrictlyUpper type trait.
Definition IsStrictlyUpper.h:173
constexpr bool IsSymmetric_v
Auxiliary variable template for the IsSymmetric type trait.
Definition IsSymmetric.h:172
constexpr bool IsTriangular_v
Auxiliary variable template for the IsTriangular type trait.
Definition IsTriangular.h:106
constexpr bool IsStrictlyLower_v
Auxiliary variable template for the IsStrictlyLower type trait.
Definition IsStrictlyLower.h:173
constexpr bool IsRowMajorMatrix_v
Auxiliary variable template for the IsRowMajorMatrix type trait.
Definition IsRowMajorMatrix.h:129
constexpr bool IsUpper_v
Auxiliary variable template for the IsUpper type trait.
Definition IsUpper.h:175
constexpr bool IsDiagonal_v
Auxiliary variable template for the IsDiagonal type trait.
Definition IsDiagonal.h:148
constexpr bool IsComputation_v
Auxiliary variable template for the IsComputation type trait.
Definition IsComputation.h:90
constexpr bool IsZero_v
Auxiliary variable template for the IsZero type trait.
Definition IsZero.h:166
constexpr bool IsColumnMajorMatrix_v
Auxiliary variable template for the IsColumnMajorMatrix type trait.
Definition IsColumnMajorMatrix.h:129
constexpr bool IsIdentity_v
Auxiliary variable template for the IsIdentity type trait.
Definition IsIdentity.h:137
constexpr bool IsLower_v
Auxiliary variable template for the IsLower type trait.
Definition IsLower.h:175
constexpr bool IsResizable_v
Auxiliary variable template for the IsResizable type trait.
Definition IsResizable.h:136
BLAZE_ALWAYS_INLINE constexpr auto prevMultiple(T1 value, T2 factor) noexcept
Rounds down an integral value to the previous multiple of a given factor.
Definition PrevMultiple.h:68
constexpr void reset(Matrix< MT, SO > &matrix)
Resetting the given matrix.
Definition Matrix.h:806
MT::Iterator end(Matrix< MT, SO > &matrix, size_t i)
Returns an iterator just past the last element of row/column i.
Definition Matrix.h:584
MT::Iterator begin(Matrix< MT, SO > &matrix, size_t i)
Returns an iterator to the first element of row/column i.
Definition Matrix.h:518
constexpr size_t size(const Matrix< MT, SO > &matrix) noexcept
Returns the total number of elements of the matrix.
Definition Matrix.h:676
bool isSquare(const Matrix< MT, SO > &matrix) noexcept
Checks if the given matrix is a square matrix.
Definition Matrix.h:1383
decltype(auto) row(Matrix< MT, SO > &, RRAs...)
Creating a view on a specific row of the given matrix.
Definition Row.h:137
#define BLAZE_INTERNAL_ASSERT(expr, msg)
Run time assertion macro for internal checks.
Definition Assert.h:101
auto smpSubAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs) -> EnableIf_t< IsDenseMatrix_v< MT1 > >
Default implementation of the SMP subtraction assignment of a matrix to dense matrix.
Definition DenseMatrix.h:162
auto smpAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs) -> EnableIf_t< IsDenseMatrix_v< MT1 > >
Default implementation of the SMP assignment of a matrix to a dense matrix.
Definition DenseMatrix.h:100
auto smpSchurAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs) -> EnableIf_t< IsDenseMatrix_v< MT1 > >
Default implementation of the SMP Schur product assignment of a matrix to dense matrix.
Definition DenseMatrix.h:194
auto smpAddAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs) -> EnableIf_t< IsDenseMatrix_v< MT1 > >
Default implementation of the SMP addition assignment of a matrix to a dense matrix.
Definition DenseMatrix.h:131
decltype(auto) subvector(Vector< VT, TF > &, RSAs...)
Creating a view on a specific subvector of the given vector.
Definition Subvector.h:158
constexpr bool IsSame_v
Auxiliary variable template for the IsSame type trait.
Definition IsSame.h:159
constexpr void MAYBE_UNUSED(const Args &...)
Suppression of unused parameter warnings.
Definition MaybeUnused.h:81
typename EnableIf< Condition, T >::Type EnableIf_t
Auxiliary type for the EnableIf class template.
Definition EnableIf.h:138
#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
#define BLAZE_FUNCTION_TRACE
Function trace macro.
Definition FunctionTrace.h:94
typename If< Condition >::template Type< T1, T2 > If_t
Auxiliary alias template for the If class template.
Definition If.h:108
typename EnableIf<!Condition, T >::Type DisableIf_t
Auxiliary type for the EnableIf class template.
Definition EnableIf.h:175
constexpr Unchecked unchecked
Global Unchecked instance.
Definition Check.h:146
Header file for the exception macros of the math module.
Constraints on the storage order of matrix types.
Header file for all forward declarations for expression class templates.
Header file for the Size type trait.
Header file for the reset shim.
Header file for the serial shim.
Base class for all compute expression templates.
Definition Computation.h:68
Base template for the DeclDiagTrait class.
Definition DeclDiagTrait.h:127
Generic wrapper for the decldiag() function.
Definition DeclDiag.h:61
Base template for the DeclHermTrait class.
Definition DeclHermTrait.h:126
Generic wrapper for the declherm() function.
Definition DeclHerm.h:61
Base template for the DeclLowTrait class.
Definition DeclLowTrait.h:126
Generic wrapper for the decllow() function.
Definition DeclLow.h:61
Base template for the DeclSymTrait class.
Definition DeclSymTrait.h:126
Generic wrapper for the declsym() function.
Definition DeclSym.h:61
Base template for the DeclUppTrait class.
Definition DeclUppTrait.h:126
Generic wrapper for the declupp() function.
Definition DeclUpp.h:61
Compile time check for the alignment of data types.
Definition IsAligned.h:88
Base class for all matrix/matrix multiplication expression templates.
Definition MatMatMultExpr.h:71
Base template for the MultTrait class.
Definition MultTrait.h:130
Generic wrapper for the null function.
Definition Noop.h:62
Compile time evaluation of the size of vectors and matrices.
Definition Size.h:119
System settings for performance optimizations.
Header file for the thresholds for matrix/vector and matrix/matrix multiplications.
Header file for the IsZero type trait.
Header file for the RequiresEvaluation type trait.
Header file for basic type definitions.
Header file for the generic max algorithm.
Header file for the generic min algorithm.