35 #ifndef _BLAZE_MATH_EXPRESSIONS_DMATTDMATSCHUREXPR_H_ 36 #define _BLAZE_MATH_EXPRESSIONS_DMATTDMATSCHUREXPR_H_ 101 template<
typename MT1
104 :
public SchurExpr< DenseMatrix< DMatTDMatSchurExpr<MT1,MT2>, false > >
124 static constexpr
bool returnExpr = ( !IsTemporary_v<RN1> && !IsTemporary_v<RN2> );
139 ( RequiresEvaluation_v<MT1> || RequiresEvaluation_v<MT2> || !
returnExpr );
142 template<
typename MT >
144 static constexpr
bool UseAssign_v =
useAssign;
156 template<
typename MT >
157 static constexpr
bool UseSMPAssign_v =
230 if( i >=
lhs_.rows() ) {
233 if( j >=
lhs_.columns() ) {
245 inline size_t rows() const noexcept {
256 return lhs_.columns();
286 template<
typename T >
287 inline bool canAlias(
const T* alias )
const noexcept {
288 return ( IsExpression_v<MT1> && ( RequiresEvaluation_v<MT1> ?
lhs_.isAliased( alias ) :
lhs_.canAlias( alias ) ) ) ||
289 ( IsExpression_v<MT2> && ( RequiresEvaluation_v<MT2> ?
rhs_.isAliased( alias ) :
rhs_.canAlias( alias ) ) );
299 template<
typename T >
300 inline bool isAliased(
const T* alias )
const noexcept {
301 return (
lhs_.isAliased( alias ) ||
rhs_.isAliased( alias ) );
311 return lhs_.isAligned() &&
rhs_.isAligned();
321 return lhs_.canSMPAssign() ||
rhs_.canSMPAssign() ||
322 (
rows() *
columns() >= SMP_DMATTDMATSCHUR_THRESHOLD );
346 template<
typename MT
356 constexpr
size_t block( BLOCK_SIZE );
358 const size_t m( rhs.rows() );
359 const size_t n( rhs.columns() );
361 for(
size_t ii=0UL; ii<m; ii+=block ) {
362 const size_t iend( ( m < ii+block )?( m ):( ii+block ) );
363 for(
size_t jj=0UL; jj<n; jj+=block ) {
364 const size_t jend( ( n < jj+block )?( n ):( jj+block ) );
365 for(
size_t i=ii; i<iend; ++i ) {
366 for(
size_t j=jj; j<jend; ++j ) {
367 (~lhs)(i,j) = rhs.lhs_(i,j) * rhs.rhs_(i,j);
391 template<
typename MT
401 if( !IsOperation_v<MT1> &&
isSame( ~lhs, rhs.lhs_ ) ) {
402 schurAssign( ~lhs, rhs.rhs_ );
407 assign( ~lhs, A % B );
428 template<
typename MT
431 -> EnableIf_t< UseAssign_v<MT> && IsCommutative_v<MT1,MT2> >
438 if( !IsOperation_v<MT1> &&
isSame( ~lhs, rhs.lhs_ ) ) {
439 schurAssign( ~lhs, rhs.rhs_ );
441 else if( !IsOperation_v<MT2> &&
isSame( ~lhs, rhs.rhs_ ) ) {
442 schurAssign( ~lhs, rhs.lhs_ );
444 else if( !RequiresEvaluation_v<MT2> ) {
445 assign ( ~lhs, rhs.rhs_ );
446 schurAssign( ~lhs, rhs.lhs_ );
449 assign ( ~lhs, rhs.lhs_ );
450 schurAssign( ~lhs, rhs.rhs_ );
468 template<
typename MT
474 using TmpType = If_t< SO, OppositeType, ResultType >;
486 const TmpType tmp(
serial( rhs ) );
507 template<
typename MT
509 friend inline auto addAssign( DenseMatrix<MT,SO>& lhs,
const DMatTDMatSchurExpr& rhs )
510 -> DisableIf_t< UseAssign_v<MT> >
517 constexpr
size_t block( BLOCK_SIZE );
519 const size_t m( rhs.rows() );
520 const size_t n( rhs.columns() );
522 for(
size_t ii=0UL; ii<m; ii+=block ) {
523 const size_t iend( ( m < ii+block )?( m ):( ii+block ) );
524 for(
size_t jj=0UL; jj<n; jj+=block ) {
525 const size_t jend( ( n < jj+block )?( n ):( jj+block ) );
526 for(
size_t i=ii; i<iend; ++i ) {
527 for(
size_t j=jj; j<jend; ++j ) {
528 (~lhs)(i,j) += rhs.lhs_(i,j) * rhs.rhs_(i,j);
552 template<
typename MT
554 friend inline auto addAssign( DenseMatrix<MT,SO>& lhs,
const DMatTDMatSchurExpr& rhs )
555 -> EnableIf_t< UseAssign_v<MT> >
567 addAssign( ~lhs, tmp );
591 template<
typename MT
593 friend inline auto subAssign( DenseMatrix<MT,SO>& lhs,
const DMatTDMatSchurExpr& rhs )
594 -> DisableIf_t< UseAssign_v<MT> >
601 constexpr
size_t block( BLOCK_SIZE );
603 const size_t m( rhs.rows() );
604 const size_t n( rhs.columns() );
606 for(
size_t ii=0UL; ii<m; ii+=block ) {
607 const size_t iend( ( m < ii+block )?( m ):( ii+block ) );
608 for(
size_t jj=0UL; jj<n; jj+=block ) {
609 const size_t jend( ( n < jj+block )?( n ):( jj+block ) );
610 for(
size_t i=ii; i<iend; ++i ) {
611 for(
size_t j=jj; j<jend; ++j ) {
612 (~lhs)(i,j) -= rhs.lhs_(i,j) * rhs.rhs_(i,j);
636 template<
typename MT
638 friend inline auto subAssign( DenseMatrix<MT,SO>& lhs,
const DMatTDMatSchurExpr& rhs )
639 -> EnableIf_t< UseAssign_v<MT> >
651 subAssign( ~lhs, tmp );
675 template<
typename MT
677 friend inline auto schurAssign( DenseMatrix<MT,SO>& lhs,
const DMatTDMatSchurExpr& rhs )
678 -> DisableIf_t< UseAssign_v<MT> >
685 constexpr
size_t block( BLOCK_SIZE );
687 const size_t m( rhs.rows() );
688 const size_t n( rhs.columns() );
690 for(
size_t ii=0UL; ii<m; ii+=block ) {
691 const size_t iend( ( m < ii+block )?( m ):( ii+block ) );
692 for(
size_t jj=0UL; jj<n; jj+=block ) {
693 const size_t jend( ( n < jj+block )?( n ):( jj+block ) );
694 for(
size_t i=ii; i<iend; ++i ) {
695 for(
size_t j=jj; j<jend; ++j ) {
696 (~lhs)(i,j) *= rhs.lhs_(i,j) * rhs.rhs_(i,j);
721 template<
typename MT
723 friend inline auto schurAssign( DenseMatrix<MT,SO>& lhs,
const DMatTDMatSchurExpr& rhs )
724 -> EnableIf_t< UseAssign_v<MT> && !IsCommutative_v<MT1,MT2> >
736 schurAssign( ~lhs, tmp );
757 template<
typename MT
759 friend inline auto schurAssign( DenseMatrix<MT,SO>& lhs,
const DMatTDMatSchurExpr& rhs )
760 -> EnableIf_t< UseAssign_v<MT> && IsCommutative_v<MT1,MT2> >
767 if( !RequiresEvaluation_v<MT2> ) {
768 schurAssign( ~lhs, rhs.rhs_ );
769 schurAssign( ~lhs, rhs.lhs_ );
772 schurAssign( ~lhs, rhs.lhs_ );
773 schurAssign( ~lhs, rhs.rhs_ );
806 template<
typename MT
809 -> EnableIf_t< UseSMPAssign_v<MT> && !IsCommutative_v<MT1,MT2> >
816 if( !IsOperation_v<MT1> &&
isSame( ~lhs, rhs.lhs_ ) ) {
843 template<
typename MT
846 -> EnableIf_t< UseSMPAssign_v<MT> && IsCommutative_v<MT1,MT2> >
853 if( !IsOperation_v<MT1> &&
isSame( ~lhs, rhs.lhs_ ) ) {
856 else if( !IsOperation_v<MT2> &&
isSame( ~lhs, rhs.rhs_ ) ) {
859 else if( !RequiresEvaluation_v<MT2> ) {
886 template<
typename MT
889 -> EnableIf_t< UseSMPAssign_v<MT> >
893 using TmpType = If_t< SO, OppositeType, ResultType >;
905 const TmpType tmp( rhs );
926 template<
typename MT
929 -> EnableIf_t< UseSMPAssign_v<MT> >
965 template<
typename MT
968 -> EnableIf_t< UseSMPAssign_v<MT> >
1005 template<
typename MT
1008 -> EnableIf_t< UseSMPAssign_v<MT> && !IsCommutative_v<MT1,MT2> >
1041 template<
typename MT
1044 -> EnableIf_t< UseSMPAssign_v<MT> && IsCommutative_v<MT1,MT2> >
1051 if( !RequiresEvaluation_v<MT2> ) {
1108 template<
typename MT1
1110 , EnableIf_t< !IsSymmetric_v<MT1> &&
1111 !IsSymmetric_v<MT2> &&
1112 !( IsUniLower_v<MT1> && IsUniUpper_v<MT2> ) &&
1113 !( IsUniUpper_v<MT1> && IsUniLower_v<MT2> ) &&
1114 !( IsStrictlyLower_v<MT1> && IsUpper_v<MT2> ) &&
1115 !( IsStrictlyUpper_v<MT1> && IsLower_v<MT2> ) &&
1116 !( IsLower_v<MT1> && IsStrictlyUpper_v<MT2> ) &&
1117 !( IsUpper_v<MT1> && IsStrictlyLower_v<MT2> ) >* =
nullptr >
1118 inline const DMatTDMatSchurExpr<MT1,MT2>
1119 dmattdmatschur(
const DenseMatrix<MT1,false>& lhs,
const DenseMatrix<MT2,true>& rhs )
1126 return DMatTDMatSchurExpr<MT1,MT2>( ~lhs, ~rhs );
1145 template<
typename MT1
1147 , EnableIf_t< IsSymmetric_v<MT1> &&
1148 !IsSymmetric_v<MT2> &&
1149 !( IsUniLower_v<MT1> && IsUniUpper_v<MT2> ) &&
1150 !( IsUniUpper_v<MT1> && IsUniLower_v<MT2> ) &&
1151 !( IsStrictlyLower_v<MT1> && IsUpper_v<MT2> ) &&
1152 !( IsStrictlyUpper_v<MT1> && IsLower_v<MT2> ) &&
1153 !( IsLower_v<MT1> && IsStrictlyUpper_v<MT2> ) &&
1154 !( IsUpper_v<MT1> && IsStrictlyLower_v<MT2> ) >* =
nullptr >
1155 inline decltype(
auto)
1156 dmattdmatschur( const DenseMatrix<MT1,false>& lhs, const DenseMatrix<MT2,true>& rhs )
1163 return trans( ~lhs ) % ~rhs;
1182 template<
typename MT1
1184 , EnableIf_t< IsSymmetric_v<MT2> &&
1185 !( IsUniLower_v<MT1> && IsUniUpper_v<MT2> ) &&
1186 !( IsUniUpper_v<MT1> && IsUniLower_v<MT2> ) &&
1187 !( IsStrictlyLower_v<MT1> && IsUpper_v<MT2> ) &&
1188 !( IsStrictlyUpper_v<MT1> && IsLower_v<MT2> ) &&
1189 !( IsLower_v<MT1> && IsStrictlyUpper_v<MT2> ) &&
1190 !( IsUpper_v<MT1> && IsStrictlyLower_v<MT2> ) >* =
nullptr >
1191 inline decltype(
auto)
1192 dmattdmatschur( const DenseMatrix<MT1,false>& lhs, const DenseMatrix<MT2,true>& rhs )
1199 return (~lhs) %
trans( ~rhs );
1219 template<
typename MT1
1221 , EnableIf_t< ( IsUniLower_v<MT1> && IsUniUpper_v<MT2> ) ||
1222 ( IsUniUpper_v<MT1> && IsUniLower_v<MT2> ) >* =
nullptr >
1223 inline decltype(
auto)
1224 dmattdmatschur( const DenseMatrix<MT1,false>& lhs, const DenseMatrix<MT2,true>& rhs )
1233 using ReturnType =
const SchurTrait_t< ResultType_t<MT1>, ResultType_t<MT2> >;
1258 template<
typename MT1
1260 , EnableIf_t< ( IsStrictlyLower_v<MT1> && IsUpper_v<MT2> ) ||
1261 ( IsStrictlyUpper_v<MT1> && IsLower_v<MT2> ) ||
1262 ( IsLower_v<MT1> && IsStrictlyUpper_v<MT2> ) ||
1263 ( IsUpper_v<MT1> && IsStrictlyLower_v<MT2> ) >* =
nullptr >
1264 inline decltype(
auto)
1265 dmattdmatschur( const DenseMatrix<MT1,false>& lhs, const DenseMatrix<MT2,true>& rhs )
1274 using ReturnType =
const SchurTrait_t< ResultType_t<MT1>, ResultType_t<MT2> >;
1314 template<
typename MT1
1316 inline decltype(
auto)
1325 return dmattdmatschur( ~lhs, ~rhs );
1343 template<
typename MT1
1345 , EnableIf_t< !IsSymmetric_v<MT1> &&
1346 !IsSymmetric_v<MT2> &&
1347 !( IsUniLower_v<MT1> && IsUniUpper_v<MT2> ) &&
1348 !( IsUniUpper_v<MT1> && IsUniLower_v<MT2> ) &&
1349 !( IsStrictlyLower_v<MT1> && IsUpper_v<MT2> ) &&
1350 !( IsStrictlyUpper_v<MT1> && IsLower_v<MT2> ) &&
1351 !( IsLower_v<MT1> && IsStrictlyUpper_v<MT2> ) &&
1352 !( IsUpper_v<MT1> && IsStrictlyLower_v<MT2> ) >* =
nullptr >
1353 inline const DMatTDMatSchurExpr<MT1,MT2>
1354 tdmatdmatschur(
const DenseMatrix<MT1,true>& lhs,
const DenseMatrix<MT2,false>& rhs )
1361 return DMatTDMatSchurExpr<MT1,MT2>( ~lhs, ~rhs );
1380 template<
typename MT1
1382 , EnableIf_t< !IsSymmetric_v<MT1> &&
1383 IsSymmetric_v<MT2> &&
1384 !( IsUniLower_v<MT1> && IsUniUpper_v<MT2> ) &&
1385 !( IsUniUpper_v<MT1> && IsUniLower_v<MT2> ) &&
1386 !( IsStrictlyLower_v<MT1> && IsUpper_v<MT2> ) &&
1387 !( IsStrictlyUpper_v<MT1> && IsLower_v<MT2> ) &&
1388 !( IsLower_v<MT1> && IsStrictlyUpper_v<MT2> ) &&
1389 !( IsUpper_v<MT1> && IsStrictlyLower_v<MT2> ) >* =
nullptr >
1390 inline decltype(
auto)
1391 tdmatdmatschur( const DenseMatrix<MT1,true>& lhs, const DenseMatrix<MT2,false>& rhs )
1398 return (~lhs) %
trans( ~rhs );
1417 template<
typename MT1
1419 , EnableIf_t< IsSymmetric_v<MT1> &&
1420 !( IsUniLower_v<MT1> && IsUniUpper_v<MT2> ) &&
1421 !( IsUniUpper_v<MT1> && IsUniLower_v<MT2> ) &&
1422 !( IsStrictlyLower_v<MT1> && IsUpper_v<MT2> ) &&
1423 !( IsStrictlyUpper_v<MT1> && IsLower_v<MT2> ) &&
1424 !( IsLower_v<MT1> && IsStrictlyUpper_v<MT2> ) &&
1425 !( IsUpper_v<MT1> && IsStrictlyLower_v<MT2> ) >* =
nullptr >
1426 inline decltype(
auto)
1427 tdmatdmatschur( const DenseMatrix<MT1,true>& lhs, const DenseMatrix<MT2,false>& rhs )
1434 return trans( ~lhs ) % (~rhs);
1454 template<
typename MT1
1456 , EnableIf_t< ( IsUniLower_v<MT1> && IsUniUpper_v<MT2> ) ||
1457 ( IsUniUpper_v<MT1> && IsUniLower_v<MT2> ) >* =
nullptr >
1458 inline decltype(
auto)
1459 tdmatdmatschur( const DenseMatrix<MT1,true>& lhs, const DenseMatrix<MT2,false>& rhs )
1468 using ReturnType =
const SchurTrait_t< ResultType_t<MT1>, ResultType_t<MT2> >;
1493 template<
typename MT1
1495 , EnableIf_t< ( IsStrictlyLower_v<MT1> && IsUpper_v<MT2> ) ||
1496 ( IsStrictlyUpper_v<MT1> && IsLower_v<MT2> ) ||
1497 ( IsLower_v<MT1> && IsStrictlyUpper_v<MT2> ) ||
1498 ( IsUpper_v<MT1> && IsStrictlyLower_v<MT2> ) >* =
nullptr >
1499 inline decltype(
auto)
1500 tdmatdmatschur( const DenseMatrix<MT1,true>& lhs, const DenseMatrix<MT2,false>& rhs )
1509 using ReturnType =
const SchurTrait_t< ResultType_t<MT1>, ResultType_t<MT2> >;
1549 template<
typename MT1
1551 inline decltype(
auto)
1560 return tdmatdmatschur( ~lhs, ~rhs );
1575 template<
typename MT1,
typename MT2 >
1576 struct IsAligned< DMatTDMatSchurExpr<MT1,MT2> >
1577 :
public BoolConstant< IsAligned_v<MT1> && IsAligned_v<MT2> >
Constraint on the data type.
#define BLAZE_THROW_INVALID_ARGUMENT(MESSAGE)
Macro for the emission of a std::invalid_argument exception.This macro encapsulates the default way o...
Definition: Exception.h:235
Header file for auxiliary alias declarations.
Header file for kernel specific block sizes.
#define BLAZE_CONSTRAINT_MUST_BE_IDENTITY_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not an identity matrix type...
Definition: Identity.h:60
Header file for the Schur product trait.
Header file for the UNUSED_PARAMETER function template.
Header file for the IsUniUpper type trait.
LeftOperand lhs_
Left-hand side dense matrix of the Schur product expression.
Definition: DMatTDMatSchurExpr.h:328
bool isAligned() const noexcept
Returns whether the operands of the expression are properly aligned in memory.
Definition: DMatTDMatSchurExpr.h:310
bool isSame(const Matrix< MT1, SO1 > &a, const Matrix< MT2, SO2 > &b) noexcept
Returns whether the two given matrices represent the same observable state.
Definition: Matrix.h:992
Header file for basic type definitions.
typename If< Condition, T1, T2 >::Type If_t
Auxiliary alias declaration for the If class template.The If_t alias declaration provides a convenien...
Definition: If.h:109
typename T::ResultType ResultType_t
Alias declaration for nested ResultType type definitions.The ResultType_t alias declaration provides ...
Definition: Aliases.h:390
Header file for the IsCommutative type trait.
Header file for the serial shim.
#define BLAZE_CONSTRAINT_MUST_BE_MATRIX_WITH_STORAGE_ORDER(T, SO)
Constraint on the data type.In case the given data type T is not a dense or sparse matrix type and in...
Definition: StorageOrder.h:63
ElementType_t< ResultType > ElementType
Resulting element type.
Definition: DMatTDMatSchurExpr.h:169
#define BLAZE_CONSTRAINT_MUST_BE_DENSE_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a dense, N-dimensional matrix type...
Definition: DenseMatrix.h:61
static constexpr bool smpAssignable
Compilation flag for SMP assignments.
Definition: CompressedMatrix.h:3113
LeftOperand leftOperand() const noexcept
Returns the left-hand side dense matrix operand.
Definition: DMatTDMatSchurExpr.h:265
Constraint on the data type.
ResultType_t< MT2 > RT2
Result type of the right-hand side dense matrix expression.
Definition: DMatTDMatSchurExpr.h:110
RightOperand rightOperand() const noexcept
Returns the right-hand side transpose dense matrix operand.
Definition: DMatTDMatSchurExpr.h:275
const ResultType CompositeType
Data type for composite expression templates.
Definition: DMatTDMatSchurExpr.h:175
decltype(std::declval< RN1 >() *std::declval< RN2 >()) ExprReturnType
Expression return type for the subscript operator.
Definition: DMatTDMatSchurExpr.h:127
Header file for the Computation base class.
Constraints on the storage order of matrix types.
Header file for the RequiresEvaluation type trait.
constexpr void UNUSED_PARAMETER(const Args &...)
Suppression of unused parameter warnings.
Definition: Unused.h:81
typename T::ReturnType ReturnType_t
Alias declaration for nested ReturnType type definitions.The ReturnType_t alias declaration provides ...
Definition: Aliases.h:410
Header file for the IsUniLower type trait.
ResultType_t< MT1 > RT1
Result type of the left-hand side dense matrix expression.
Definition: DMatTDMatSchurExpr.h:109
#define BLAZE_CONSTRAINT_MUST_FORM_VALID_SCHUREXPR(T1, T2)
Constraint on the data type.In case the given data types T1 and T2 do not form a valid matrix/matrix ...
Definition: SchurExpr.h:103
constexpr size_t columns(const Matrix< MT, SO > &matrix) noexcept
Returns the current number of columns of the matrix.
Definition: Matrix.h:514
Base class for dense matrices.The DenseMatrix class is a base class for all dense matrix classes...
Definition: DenseMatrix.h:80
typename T::ElementType ElementType_t
Alias declaration for nested ElementType type definitions.The ElementType_t alias declaration provide...
Definition: Aliases.h:170
Header file for all forward declarations for sparse vectors and matrices.
bool canAlias(const T *alias) const noexcept
Returns whether the expression can alias with the given address alias.
Definition: DMatTDMatSchurExpr.h:287
static constexpr bool smpAssignable
Compilation switch for the expression template assignment strategy.
Definition: DMatTDMatSchurExpr.h:189
If_t< IsExpression_v< MT1 >, const MT1, const MT1 &> LeftOperand
Composite type of the left-hand side dense matrix expression.
Definition: DMatTDMatSchurExpr.h:178
Constraint on the data type.
typename EnableIf< Condition, T >::Type EnableIf_t
Auxiliary type for the EnableIf class template.The EnableIf_t alias declaration provides a convenient...
Definition: EnableIf.h:138
Header file for the DisableIf class template.
Header file for the IsTemporary type trait class.
Header file for the IsStrictlyUpper type trait.
Header file for the IsSymmetric type trait.
const If_t< returnExpr, ExprReturnType, ElementType > ReturnType
Return type for expression template evaluations.
Definition: DMatTDMatSchurExpr.h:172
static constexpr bool returnExpr
Compilation switch for the selection of the subscript operator return type.
Definition: DMatTDMatSchurExpr.h:124
Namespace of the Blaze C++ math library.
Definition: Blaze.h:58
Header file for the If class template.
#define BLAZE_CONSTRAINT_MUST_BE_COLUMN_MAJOR_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a column-major dense or sparse matri...
Definition: ColumnMajorMatrix.h:61
#define BLAZE_CONSTRAINT_MUST_BE_ZERO_TYPE(T)
Constraint on the data type.In case the given data type T is not a zero vector or matrix type...
Definition: Zero.h:61
static constexpr bool simdEnabled
Compilation switch for the expression template evaluation strategy.
Definition: DMatTDMatSchurExpr.h:186
size_t columns() const noexcept
Returns the current number of columns of the matrix.
Definition: DMatTDMatSchurExpr.h:255
#define BLAZE_THROW_OUT_OF_RANGE(MESSAGE)
Macro for the emission of a std::out_of_range exception.This macro encapsulates the default way of Bl...
Definition: Exception.h:331
Header file for the DenseMatrix base class.
Header file for the IsOperation type trait class.
TransposeType_t< ResultType > TransposeType
Transpose type for expression template evaluations.
Definition: DMatTDMatSchurExpr.h:168
Header file for the IsLower type trait.
CompositeType_t< MT1 > CT1
Composite type of the left-hand side dense matrix expression.
Definition: DMatTDMatSchurExpr.h:113
Header file for the IsAligned type trait.
Constraints on the storage order of matrix types.
ReturnType_t< MT1 > RN1
Return type of the left-hand side dense matrix expression.
Definition: DMatTDMatSchurExpr.h:111
Header file for the exception macros of the math module.
Constraint on the data type.
Header file for all forward declarations for expression class templates.
If_t< IsExpression_v< MT2 >, const MT2, const MT2 &> RightOperand
Composite type of the right-hand side dense matrix expression.
Definition: DMatTDMatSchurExpr.h:181
Header file for the EnableIf class template.
Header file for the IsStrictlyLower type trait.
#define BLAZE_CONSTRAINT_MATRICES_MUST_HAVE_DIFFERENT_STORAGE_ORDER(T1, T2)
Constraint on the data type.In case either of the two given data types T1 or T2 is not a matrix type ...
Definition: StorageOrder.h:106
typename T::OppositeType OppositeType_t
Alias declaration for nested OppositeType type definitions.The OppositeType_t alias declaration provi...
Definition: Aliases.h:270
ReturnType at(size_t i, size_t j) const
Checked access to the matrix elements.
Definition: DMatTDMatSchurExpr.h:229
#define BLAZE_CONSTRAINT_MUST_BE_ROW_MAJOR_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a row-major dense or sparse matrix t...
Definition: RowMajorMatrix.h:61
DMatTDMatSchurExpr(const MT1 &lhs, const MT2 &rhs) noexcept
Constructor for the DMatTDMatSchurExpr class.
Definition: DMatTDMatSchurExpr.h:198
Base class for all Schur product expression templates.The SchurExpr class serves as a tag for all exp...
Definition: SchurExpr.h:66
typename T::TransposeType TransposeType_t
Alias declaration for nested TransposeType type definitions.The TransposeType_t alias declaration pro...
Definition: Aliases.h:470
Header file for run time assertion macros.
typename T::CompositeType CompositeType_t
Alias declaration for nested CompositeType type definitions.The CompositeType_t alias declaration pro...
Definition: Aliases.h:90
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
Header file for the SchurExpr base class.
typename SchurTrait< T1, T2 >::Type SchurTrait_t
Auxiliary alias declaration for the SchurTrait class template.The SchurTrait_t alias declaration prov...
Definition: SchurTrait.h:164
#define BLAZE_FUNCTION_TRACE
Function trace macro.This macro can be used to reliably trace function calls. In case function tracin...
Definition: FunctionTrace.h:94
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
Expression object for dense matrix-transpose dense matrix Schur product.The DMatTDMatSchurExpr class ...
Definition: DMatTDMatSchurExpr.h:103
Constraints on the storage order of matrix types.
decltype(auto) serial(const DenseMatrix< MT, SO > &dm)
Forces the serial evaluation of the given dense matrix expression dm.
Definition: DMatSerialExpr.h:808
#define BLAZE_CONSTRAINT_MUST_NOT_REQUIRE_EVALUATION(T)
Constraint on the data type.In case the given data type T requires an intermediate evaluation within ...
Definition: RequiresEvaluation.h:81
bool canSMPAssign() const noexcept
Returns whether the expression can be used in SMP assignments.
Definition: DMatTDMatSchurExpr.h:320
IntegralConstant< bool, B > BoolConstant
Generic wrapper for a compile time constant boolean value.The BoolConstant class template represents ...
Definition: IntegralConstant.h:101
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
constexpr size_t rows(const Matrix< MT, SO > &matrix) noexcept
Returns the current number of rows of the matrix.
Definition: Matrix.h:498
RightOperand rhs_
Right-hand side dense matrix of the Schur product expression.
Definition: DMatTDMatSchurExpr.h:329
SchurTrait_t< RT1, RT2 > ResultType
Result type for expression template evaluations.
Definition: DMatTDMatSchurExpr.h:166
#define BLAZE_CONSTRAINT_MATRICES_MUST_HAVE_SAME_STORAGE_ORDER(T1, T2)
Constraint on the data type.In case either of the two given data types T1 or T2 is not a matrix type ...
Definition: StorageOrder.h:84
const Type & ReturnType
Return type for expression template evaluations.
Definition: CompressedMatrix.h:3081
decltype(auto) trans(const DenseMatrix< MT, SO > &dm)
Calculation of the transpose of the given dense matrix.
Definition: DMatTransExpr.h:765
OppositeType_t< ResultType > OppositeType
Result type with opposite storage order for expression template evaluations.
Definition: DMatTDMatSchurExpr.h:167
CompositeType_t< MT2 > CT2
Composite type of the right-hand side dense matrix expression.
Definition: DMatTDMatSchurExpr.h:114
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
Base class for all compute expression templates.The Computation class serves as a tag for all computa...
Definition: Computation.h:66
Header file for the IntegralConstant class template.
size_t rows() const noexcept
Returns the current number of rows of the matrix.
Definition: DMatTDMatSchurExpr.h:245
bool isAliased(const T *alias) const noexcept
Returns whether the expression is aliased with the given address alias.
Definition: DMatTDMatSchurExpr.h:300
Header file for the IsUpper type trait.
typename DisableIf< Condition, T >::Type DisableIf_t
Auxiliary type for the DisableIf class template.The DisableIf_t alias declaration provides a convenie...
Definition: DisableIf.h:138
static constexpr bool useAssign
Compilation switch for the serial evaluation strategy of the Schur product expression.
Definition: DMatTDMatSchurExpr.h:138
Header file for the thresholds for matrix/vector and matrix/matrix multiplications.
#define BLAZE_INTERNAL_ASSERT(expr, msg)
Run time assertion macro for internal checks.In case of an invalid run time expression, the program execution is terminated. The BLAZE_INTERNAL_ASSERT macro can be disabled by setting the BLAZE_USER_ASSERTION flag to zero or by defining NDEBUG during the compilation.
Definition: Assert.h:101
ReturnType operator()(size_t i, size_t j) const
2D-access to the matrix elements.
Definition: DMatTDMatSchurExpr.h:214
ReturnType_t< MT2 > RN2
Return type of the right-hand side dense matrix expression.
Definition: DMatTDMatSchurExpr.h:112
Header file for the IsExpression type trait class.
Header file for the function trace functionality.
Constraint on the data type.