35 #ifndef _BLAZE_MATH_VIEWS_ROW_H_ 36 #define _BLAZE_MATH_VIEWS_ROW_H_ 124 template<
typename MT
126 inline DisableIf_< Or< IsComputation<MT>, IsTransExpr<MT>, IsDeclExpr<MT> >
127 , RowExprTrait_<MT> >
169 template<
typename MT
171 inline const DisableIf_< Or< IsComputation<MT>, IsTransExpr<MT>, IsDeclExpr<MT> >
196 template<
typename MT
198 inline DisableIf_< Or< IsComputation<MT>, IsTransExpr<MT>, IsDeclExpr<MT> >
229 template<
typename MT
236 return row( (~matrix).leftOperand(), index ) +
row( (~matrix).rightOperand(), index );
254 template<
typename MT
261 return row( (~matrix).leftOperand(), index ) -
row( (~matrix).rightOperand(), index );
279 template<
typename MT
286 return row( (~matrix).leftOperand(), index ) * (~matrix).rightOperand();
303 template<
typename MT
310 return (~matrix).leftOperand()[index] * (~matrix).rightOperand();
328 template<
typename MT
335 return row( (~matrix).leftOperand(), index ) * (~matrix).rightOperand();
353 template<
typename MT
360 return row( (~matrix).leftOperand(), index ) / (~matrix).rightOperand();
378 template<
typename MT
385 return forEach(
row( (~matrix).operand(), index ), (~matrix).operation() );
403 template<
typename MT
410 return eval(
row( (~matrix).operand(), index ) );
428 template<
typename MT
435 return serial(
row( (~matrix).operand(), index ) );
453 template<
typename MT
460 return row( (~matrix).operand(), index );
478 template<
typename MT
485 return trans(
column( (~matrix).operand(), index ) );
506 template<
typename MT,
bool SO,
bool DF,
bool SF >
509 template<
typename MT,
bool SO,
bool DF,
bool SF >
512 template<
typename MT,
bool SO,
bool DF,
bool SF >
515 template<
typename MT,
bool SO,
bool DF,
bool SF >
518 template<
bool RF,
typename MT,
bool SO,
bool DF,
bool SF >
521 template<
typename MT,
bool SO,
bool DF,
bool SF >
524 template<
typename MT,
bool SO,
bool DF,
bool SF >
537 template<
typename MT
555 template<
typename MT
575 template<
typename MT
595 template<
typename MT
638 for(
size_t i=0UL; i<row.size(); ++i )
639 if( !isDefault<RF>( row[i] ) )
return false;
672 const ConstIterator
end( row.end() );
673 for( ConstIterator element=row.begin(); element!=
end; ++element )
674 if( !isDefault<RF>( element->value() ) )
return false;
698 template<
typename MT
704 return ( row.row_ <= row.matrix_.rows() &&
722 template<
typename MT
728 return (
isSame( a.matrix_, b.matrix_ ) && ( a.row_ == b.row_ ) );
748 template<
typename MT
758 return tryAssign( lhs.matrix_, ~rhs, lhs.row_, index );
779 template<
typename MT
789 return tryAddAssign( lhs.matrix_, ~rhs, lhs.row_, index );
810 template<
typename MT
820 return trySubAssign( lhs.matrix_, ~rhs, lhs.row_, index );
841 template<
typename MT
851 return tryMultAssign( lhs.matrix_, ~rhs, lhs.row_, index );
872 template<
typename MT
882 return tryDivAssign( lhs.matrix_, ~rhs, lhs.row_, index );
903 template<
typename MT
910 return ReturnType( derestrict( row.matrix_ ), row.row_ );
926 template<
typename MT,
bool SO,
bool DF,
bool SF >
944 template<
typename MT,
bool SO,
bool DF,
bool SF >
963 template<
typename MT,
bool SO,
bool SF >
981 template<
typename MT,
bool SO,
bool SF >
983 :
public BoolConstant< HasMutableDataAccess<MT>::value >
999 template<
typename MT,
bool SO,
bool SF >
1001 :
public BoolConstant< And< IsAligned<MT>, Or< IsRowMajorMatrix<MT>, IsSymmetric<MT> > >::value >
1017 template<
typename MT,
bool SO,
bool SF >
1018 struct IsPadded< Row<MT,SO,true,SF> >
1019 :
public BoolConstant< And< IsPadded<MT>, Or< IsRowMajorMatrix<MT>, IsSymmetric<MT> > >::value >
1035 template<
typename MT,
bool DF >
1053 template<
typename MT,
bool SO,
bool DF,
bool SF,
typename T >
1054 struct AddTrait< Row<MT,SO,DF,SF>, T >
1059 template<
typename T,
typename MT,
bool SO,
bool DF,
bool SF >
1060 struct AddTrait< T, Row<MT,SO,DF,SF> >
1078 template<
typename MT,
bool SO,
bool DF,
bool SF,
typename T >
1079 struct SubTrait< Row<MT,SO,DF,SF>, T >
1084 template<
typename T,
typename MT,
bool SO,
bool DF,
bool SF >
1085 struct SubTrait< T, Row<MT,SO,DF,SF> >
1103 template<
typename MT,
bool SO,
bool DF,
bool SF,
typename T >
1109 template<
typename T,
typename MT,
bool SO,
bool DF,
bool SF >
1128 template<
typename MT,
bool SO,
bool DF,
bool SF,
typename T >
1134 template<
typename T,
typename MT,
bool SO,
bool DF,
bool SF >
1153 template<
typename MT,
bool SO,
bool DF,
bool SF,
typename T >
1154 struct DivTrait< Row<MT,SO,DF,SF>, T >
1159 template<
typename T,
typename MT,
bool SO,
bool DF,
bool SF >
1160 struct DivTrait< T, Row<MT,SO,DF,SF> >
1178 template<
typename MT,
bool SO,
bool DF,
bool SF >
typename DerestrictTrait< T >::Type DerestrictTrait_
Auxiliary alias declaration for the DerestrictTrait type trait.The DerestrictTrait_ alias declaration...
Definition: DerestrictTrait.h:110
Compile time check for low-level access to constant data.This type trait tests whether the given data...
Definition: HasConstDataAccess.h:75
Header file for the subtraction trait.
BLAZE_ALWAYS_INLINE 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:721
Header file for basic type definitions.
Header file for the row trait.
BLAZE_ALWAYS_INLINE size_t size(const Vector< VT, TF > &vector) noexcept
Returns the current size/dimension of the vector.
Definition: Vector.h:261
Generic wrapper for a compile time constant integral value.The IntegralConstant class template repres...
Definition: IntegralConstant.h:71
Compile time check for resizable data types.This type trait tests whether the given data type is an o...
Definition: IsOpposedView.h:81
void reset(const DiagonalProxy< MT > &proxy)
Resetting the represented element to the default initial values.
Definition: DiagonalProxy.h:533
Row specialization for dense matrices.
Header file for the And class template.
Header file for the IsTransExpr type trait class.
const DMatSerialExpr< MT, SO > serial(const DenseMatrix< MT, SO > &dm)
Forces the serial evaluation of the given dense matrix expression dm.
Definition: DMatSerialExpr.h:721
typename MultTrait< T1, T2 >::Type MultTrait_
Auxiliary alias declaration for the MultTrait class template.The MultTrait_ alias declaration provide...
Definition: MultTrait.h:245
Row specialization for sparse matrices.
Header file for the IsMatMatAddExpr type trait class.
Base template for the CrossTrait class.
Definition: CrossTrait.h:110
Compile time check for data types with restricted data access.This type trait tests whether the given...
Definition: IsRestricted.h:82
Base template for the SubvectorTrait class.
Definition: SubvectorTrait.h:120
Header file for the IsMatTransExpr type trait class.
Compile time check for low-level access to mutable data.This type trait tests whether the given data ...
Definition: HasMutableDataAccess.h:75
Compile time check for the alignment of data types.This type trait tests whether the given data type ...
Definition: IsAligned.h:87
Header file for the DisableIf class template.
typename RowExprTrait< MT >::Type RowExprTrait_
Auxiliary alias declaration for the RowExprTrait type trait.The RowExprTrait_ alias declaration provi...
Definition: RowExprTrait.h:134
Header file for the implementation of the Row base template.
Header file for the multiplication trait.
Header file for the IsSymmetric type trait.
Namespace of the Blaze C++ math library.
Definition: Blaze.h:57
Header file for the IsVecTVecMultExpr type trait class.
const Element * ConstIterator
Iterator over constant elements.
Definition: CompressedMatrix.h:2939
Compile time check for data types with padding.This type trait tests whether the given data type empl...
Definition: IsPadded.h:76
Header file for the Or class template.
Header file for the IsMatMatMultExpr type trait class.
typename SubvectorTrait< VT >::Type SubvectorTrait_
Auxiliary alias declaration for the SubvectorTrait type trait.The SubvectorTrait_ alias declaration p...
Definition: SubvectorTrait.h:155
const DMatForEachExpr< MT, OP, SO > forEach(const DenseMatrix< MT, SO > &dm, OP op)
Evaluates the given custom operation on each single element of the dense matrix dm.
Definition: DMatForEachExpr.h:1046
Header file for the IsMatSerialExpr type trait class.
Header file for the IsMatScalarMultExpr type trait class.
Header file for the subvector trait.
Header file for the IsAligned type trait.
DisableIf_< Or< IsComputation< MT >, IsTransExpr< MT >, IsDeclExpr< MT > >, RowExprTrait_< MT > > row(Matrix< MT, SO > &matrix, size_t index)
Creating a view on a specific row of the given matrix.
Definition: Row.h:128
Header file for the IsOpposedView type trait.
Header file for the IsMatEvalExpr type trait class.
typename CrossTrait< T1, T2 >::Type CrossTrait_
Auxiliary alias declaration for the CrossTrait class template.The CrossTrait_ alias declaration provi...
Definition: CrossTrait.h:135
BLAZE_ALWAYS_INLINE 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:260
Header file for the RowExprTrait class template.
DisableIf_< Or< IsComputation< MT >, IsTransExpr< MT >, IsDeclExpr< MT > >, ColumnExprTrait_< MT > > column(Matrix< MT, SO > &matrix, size_t index)
Creating a view on a specific column of the given matrix.
Definition: Column.h:128
Header file for the EnableIf class template.
void clear(const DiagonalProxy< MT > &proxy)
Clearing the represented element.
Definition: DiagonalProxy.h:553
typename DivTrait< T1, T2 >::Type DivTrait_
Auxiliary alias declaration for the DivTrait class template.The DivTrait_ alias declaration provides ...
Definition: DivTrait.h:245
Reference to a specific row of a dense or sparse matrix.The Row template represents a reference to a ...
Definition: Forward.h:48
Header file for the HasConstDataAccess type trait.
Header file for the Matrix base class.
const Type & ReturnType
Return type for expression template evaluations.
Definition: CompressedMatrix.h:2934
Base template for the AddTrait class.
Definition: AddTrait.h:143
Header file for the IsMatScalarDivExpr type trait class.
Base template for the MultTrait class.
Definition: MultTrait.h:143
Header file for the addition trait.
Header file for the cross product trait.
Header file for the division trait.
#define BLAZE_FUNCTION_TRACE
Function trace macro.This macro can be used to reliably trace function calls. In case function tracin...
Definition: FunctionTrace.h:93
Base class for matrices.The Matrix class is a base class for all dense and sparse matrix classes with...
Definition: Forward.h:94
Header file for the HasMutableDataAccess type trait.
const DMatEvalExpr< MT, SO > eval(const DenseMatrix< MT, SO > &dm)
Forces the evaluation of the given dense matrix expression dm.
Definition: DMatEvalExpr.h:703
Header file for the IsMatMatSubExpr type trait class.
Evaluation of the return type of the derestrict function.Via this type trait it is possible to evalua...
Definition: DerestrictTrait.h:73
Header file for the IsDeclExpr type trait class.
typename EnableIf< Condition, T >::Type EnableIf_
Auxiliary alias declaration for the EnableIf class template.The EnableIf_ alias declaration provides ...
Definition: EnableIf.h:223
Base template for the DivTrait class.
Definition: DivTrait.h:143
typename T::ConstIterator ConstIterator_
Alias declaration for nested ConstIterator type definitions.The ConstIterator_ alias declaration prov...
Definition: Aliases.h:103
Header file for the IsRowMajorMatrix type trait.
Base class for N-dimensional vectors.The Vector class is a base class for all arbitrarily sized (N-di...
Definition: Forward.h:164
const DMatTransExpr< MT,!SO > trans(const DenseMatrix< MT, SO > &dm)
Calculation of the transpose of the given dense matrix.
Definition: DMatTransExpr.h:733
Header file for the IsComputation type trait class.
typename SubTrait< T1, T2 >::Type SubTrait_
Auxiliary alias declaration for the SubTrait class template.The SubTrait_ alias declaration provides ...
Definition: SubTrait.h:245
Header file for the IntegralConstant class template.
bool isIntact(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the invariants of the given diagonal matrix are intact.
Definition: DiagonalMatrix.h:249
bool isDefault(const DiagonalProxy< MT > &proxy)
Returns whether the represented element is in default state.
Definition: DiagonalProxy.h:573
Base template for the SubTrait class.
Definition: SubTrait.h:143
Header file for the IsMatForEachExpr type trait class.
typename AddTrait< T1, T2 >::Type AddTrait_
Auxiliary alias declaration for the AddTrait class template.The AddTrait_ alias declaration provides ...
Definition: AddTrait.h:245
#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
Header file for the TrueType type/value trait base class.
Header file for the function trace functionality.