All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DVecTransExpr.h
Go to the documentation of this file.
1 //=================================================================================================
33 //=================================================================================================
34 
35 #ifndef _BLAZE_MATH_EXPRESSIONS_DVECTRANSEXPR_H_
36 #define _BLAZE_MATH_EXPRESSIONS_DVECTRANSEXPR_H_
37 
38 
39 //*************************************************************************************************
40 // Includes
41 //*************************************************************************************************
42 
51 #include <blaze/math/Intrinsics.h>
57 #include <blaze/util/Assert.h>
58 #include <blaze/util/EmptyType.h>
59 #include <blaze/util/EnableIf.h>
61 #include <blaze/util/SelectType.h>
62 #include <blaze/util/Types.h>
63 
64 
65 namespace blaze {
66 
67 //=================================================================================================
68 //
69 // CLASS DVECTRANSEXPR
70 //
71 //=================================================================================================
72 
73 //*************************************************************************************************
80 template< typename VT // Type of the dense vector
81  , bool TF > // Transpose flag
82 class DVecTransExpr : public DenseVector< DVecTransExpr<VT,TF>, TF >
83  , private VecTransExpr
84  , private SelectType< IsComputation<VT>::value, Computation, EmptyType >::Type
85 {
86  private:
87  //**Type definitions****************************************************************************
88  typedef typename VT::CompositeType CT;
89  //**********************************************************************************************
90 
91  //**Serial evaluation strategy******************************************************************
93 
99  enum { useAssign = RequiresEvaluation<VT>::value };
100 
102  template< typename VT2 >
104  struct UseAssign {
105  enum { value = useAssign };
106  };
108  //**********************************************************************************************
109 
110  //**Parallel evaluation strategy****************************************************************
112 
117  template< typename VT2 >
118  struct UseSMPAssign {
119  enum { value = VT2::smpAssignable && useAssign };
120  };
122  //**********************************************************************************************
123 
124  public:
125  //**Type definitions****************************************************************************
127  typedef typename VT::TransposeType ResultType;
128  typedef typename VT::ResultType TransposeType;
129  typedef typename VT::ElementType ElementType;
130  typedef typename VT::ReturnType ReturnType;
131 
134 
137 
139  typedef typename SelectType< IsExpression<VT>::value, const VT, const VT& >::Type Operand;
140  //**********************************************************************************************
141 
142  //**ConstIterator class definition**************************************************************
146  {
147  public:
148  //**Type definitions*************************************************************************
149  typedef std::random_access_iterator_tag IteratorCategory;
154 
155  // STL iterator requirements
161 
163  typedef typename VT::ConstIterator IteratorType;
164  //*******************************************************************************************
165 
166  //**Constructor******************************************************************************
171  explicit inline ConstIterator( IteratorType iterator )
172  : iterator_( iterator ) // Iterator to the current element
173  {}
174  //*******************************************************************************************
175 
176  //**Addition assignment operator*************************************************************
182  inline ConstIterator& operator+=( size_t inc ) {
183  iterator_ += inc;
184  return *this;
185  }
186  //*******************************************************************************************
187 
188  //**Subtraction assignment operator**********************************************************
194  inline ConstIterator& operator-=( size_t dec ) {
195  iterator_ -= dec;
196  return *this;
197  }
198  //*******************************************************************************************
199 
200  //**Prefix increment operator****************************************************************
206  ++iterator_;
207  return *this;
208  }
209  //*******************************************************************************************
210 
211  //**Postfix increment operator***************************************************************
216  inline const ConstIterator operator++( int ) {
217  return ConstIterator( iterator_++ );
218  }
219  //*******************************************************************************************
220 
221  //**Prefix decrement operator****************************************************************
227  --iterator_;
228  return *this;
229  }
230  //*******************************************************************************************
231 
232  //**Postfix decrement operator***************************************************************
237  inline const ConstIterator operator--( int ) {
238  return ConstIterator( iterator_-- );
239  }
240  //*******************************************************************************************
241 
242  //**Element access operator******************************************************************
247  inline ReturnType operator*() const {
248  return *iterator_;
249  }
250  //*******************************************************************************************
251 
252  //**Load function****************************************************************************
257  inline IntrinsicType load() const {
258  return iterator_.load();
259  }
260  //*******************************************************************************************
261 
262  //**Equality operator************************************************************************
268  inline bool operator==( const ConstIterator& rhs ) const {
269  return iterator_ == rhs.iterator_;
270  }
271  //*******************************************************************************************
272 
273  //**Inequality operator**********************************************************************
279  inline bool operator!=( const ConstIterator& rhs ) const {
280  return iterator_ != rhs.iterator_;
281  }
282  //*******************************************************************************************
283 
284  //**Less-than operator***********************************************************************
290  inline bool operator<( const ConstIterator& rhs ) const {
291  return iterator_ < rhs.iterator_;
292  }
293  //*******************************************************************************************
294 
295  //**Greater-than operator********************************************************************
301  inline bool operator>( const ConstIterator& rhs ) const {
302  return iterator_ > rhs.iterator_;
303  }
304  //*******************************************************************************************
305 
306  //**Less-or-equal-than operator**************************************************************
312  inline bool operator<=( const ConstIterator& rhs ) const {
313  return iterator_ <= rhs.iterator_;
314  }
315  //*******************************************************************************************
316 
317  //**Greater-or-equal-than operator***********************************************************
323  inline bool operator>=( const ConstIterator& rhs ) const {
324  return iterator_ >= rhs.iterator_;
325  }
326  //*******************************************************************************************
327 
328  //**Subtraction operator*********************************************************************
334  inline DifferenceType operator-( const ConstIterator& rhs ) const {
335  return iterator_ - rhs.iterator_;
336  }
337  //*******************************************************************************************
338 
339  //**Addition operator************************************************************************
346  friend inline const ConstIterator operator+( const ConstIterator& it, size_t inc ) {
347  return ConstIterator( it.iterator_ + inc );
348  }
349  //*******************************************************************************************
350 
351  //**Addition operator************************************************************************
358  friend inline const ConstIterator operator+( size_t inc, const ConstIterator& it ) {
359  return ConstIterator( it.iterator_ + inc );
360  }
361  //*******************************************************************************************
362 
363  //**Subtraction operator*********************************************************************
370  friend inline const ConstIterator operator-( const ConstIterator& it, size_t dec ) {
371  return ConstIterator( it.iterator_ - dec );
372  }
373  //*******************************************************************************************
374 
375  private:
376  //**Member variables*************************************************************************
378  //*******************************************************************************************
379  };
380  //**********************************************************************************************
381 
382  //**Compilation flags***************************************************************************
384  enum { vectorizable = VT::vectorizable };
385 
387  enum { smpAssignable = VT::smpAssignable };
388  //**********************************************************************************************
389 
390  //**Constructor*********************************************************************************
395  explicit inline DVecTransExpr( const VT& dv )
396  : dv_( dv ) // Dense vector of the transposition expression
397  {}
398  //**********************************************************************************************
399 
400  //**Subscript operator**************************************************************************
406  inline ReturnType operator[]( size_t index ) const {
407  BLAZE_INTERNAL_ASSERT( index < dv_.size(), "Invalid vector access index" );
408  return dv_[index];
409  }
410  //**********************************************************************************************
411 
412  //**Load function*******************************************************************************
418  inline IntrinsicType load( size_t index ) const {
419  typedef IntrinsicTrait<ElementType> IT;
420  BLAZE_INTERNAL_ASSERT( index < dv_.size() , "Invalid vector access index" );
421  BLAZE_INTERNAL_ASSERT( index % IT::size == 0UL , "Invalid vector access index" );
422  return dv_.load( index );
423  }
424  //**********************************************************************************************
425 
426  //**Low-level data access***********************************************************************
431  inline const ElementType* data() const {
432  return dv_.data();
433  }
434  //**********************************************************************************************
435 
436  //**Begin function******************************************************************************
441  inline ConstIterator begin() const {
442  return ConstIterator( dv_.begin() );
443  }
444  //**********************************************************************************************
445 
446  //**End function********************************************************************************
451  inline ConstIterator end() const {
452  return ConstIterator( dv_.end() );
453  }
454  //**********************************************************************************************
455 
456  //**Size function*******************************************************************************
461  inline size_t size() const {
462  return dv_.size();
463  }
464  //**********************************************************************************************
465 
466  //**Operand access******************************************************************************
471  inline Operand operand() const {
472  return dv_;
473  }
474  //**********************************************************************************************
475 
476  //**********************************************************************************************
482  template< typename T >
483  inline bool canAlias( const T* alias ) const {
484  return dv_.canAlias( alias );
485  }
486  //**********************************************************************************************
487 
488  //**********************************************************************************************
494  template< typename T >
495  inline bool isAliased( const T* alias ) const {
496  return dv_.isAliased( alias );
497  }
498  //**********************************************************************************************
499 
500  //**********************************************************************************************
505  inline bool isAligned() const {
506  return dv_.isAligned();
507  }
508  //**********************************************************************************************
509 
510  //**********************************************************************************************
515  inline bool canSMPAssign() const {
516  return dv_.canSMPAssign();
517  }
518  //**********************************************************************************************
519 
520  private:
521  //**Member variables****************************************************************************
523  //**********************************************************************************************
524 
525  //**Assignment to dense vectors*****************************************************************
539  template< typename VT2 > // Type of the target dense vector
540  friend inline typename EnableIf< UseAssign<VT2> >::Type
541  assign( DenseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
542  {
544 
545  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
546 
547  DVecTransposer<VT2,!TF> tmp( ~lhs );
548  assign( tmp, rhs.dv_ );
549  }
551  //**********************************************************************************************
552 
553  //**Assignment to sparse vectors****************************************************************
567  template< typename VT2 > // Type of the target sparse vector
568  friend inline typename EnableIf< UseAssign<VT2> >::Type
569  assign( SparseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
570  {
572 
573  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
574 
575  SVecTransposer<VT2,!TF> tmp( ~lhs );
576  assign( tmp, rhs.dv_ );
577  }
579  //**********************************************************************************************
580 
581  //**Addition assignment to dense vectors********************************************************
595  template< typename VT2 > // Type of the target dense vector
596  friend inline typename EnableIf< UseAssign<VT2> >::Type
597  addAssign( DenseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
598  {
600 
601  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
602 
603  DVecTransposer<VT2,!TF> tmp( ~lhs );
604  addAssign( tmp, rhs.dv_ );
605  }
607  //**********************************************************************************************
608 
609  //**Addition assignment to sparse vectors*******************************************************
610  // No special implementation for the addition assignment to sparse vectors.
611  //**********************************************************************************************
612 
613  //**Subtraction assignment to dense vectors*****************************************************
627  template< typename VT2 > // Type of the target dense vector
628  friend inline typename EnableIf< UseAssign<VT2> >::Type
629  subAssign( DenseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
630  {
632 
633  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
634 
635  DVecTransposer<VT2,!TF> tmp( ~lhs );
636  subAssign( tmp, rhs.dv_ );
637  }
639  //**********************************************************************************************
640 
641  //**Subtraction assignment to sparse vectors****************************************************
642  // No special implementation for the subtraction assignment to sparse vectors.
643  //**********************************************************************************************
644 
645  //**Multiplication assignment to dense vectors**************************************************
659  template< typename VT2 > // Type of the target dense vector
660  friend inline typename EnableIf< UseAssign<VT2> >::Type
661  multAssign( DenseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
662  {
664 
665  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
666 
667  DVecTransposer<VT2,!TF> tmp( ~lhs );
668  multAssign( tmp, rhs.dv_ );
669  }
671  //**********************************************************************************************
672 
673  //**Multiplication assignment to sparse vectors*************************************************
674  // No special implementation for the multiplication assignment to sparse vectors.
675  //**********************************************************************************************
676 
677  //**SMP assignment to dense vectors*************************************************************
691  template< typename VT2 > // Type of the target dense vector
692  friend inline typename EnableIf< UseSMPAssign<VT2> >::Type
693  smpAssign( DenseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
694  {
696 
697  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
698 
699  DVecTransposer<VT2,!TF> tmp( ~lhs );
700  smpAssign( tmp, rhs.dv_ );
701  }
703  //**********************************************************************************************
704 
705  //**SMP assignment to sparse vectors************************************************************
719  template< typename VT2 > // Type of the target sparse vector
720  friend inline typename EnableIf< UseSMPAssign<VT2> >::Type
721  smpAssign( SparseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
722  {
724 
725  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
726 
727  SVecTransposer<VT2,!TF> tmp( ~lhs );
728  smpAssign( tmp, rhs.dv_ );
729  }
731  //**********************************************************************************************
732 
733  //**SMP addition assignment to dense vectors****************************************************
747  template< typename VT2 > // Type of the target dense vector
748  friend inline typename EnableIf< UseSMPAssign<VT2> >::Type
749  smpAddAssign( DenseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
750  {
752 
753  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
754 
755  DVecTransposer<VT2,!TF> tmp( ~lhs );
756  smpAddAssign( tmp, rhs.dv_ );
757  }
759  //**********************************************************************************************
760 
761  //**SMP addition assignment to sparse vectors***************************************************
762  // No special implementation for the SMP addition assignment to sparse vectors.
763  //**********************************************************************************************
764 
765  //**SMP subtraction assignment to dense vectors*************************************************
779  template< typename VT2 > // Type of the target dense vector
780  friend inline typename EnableIf< UseSMPAssign<VT2> >::Type
781  smpSubAssign( DenseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
782  {
784 
785  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
786 
787  DVecTransposer<VT2,!TF> tmp( ~lhs );
788  smpSubAssign( tmp, rhs.dv_ );
789  }
791  //**********************************************************************************************
792 
793  //**SMP subtraction assignment to sparse vectors************************************************
794  // No special implementation for the SMP subtraction assignment to sparse vectors.
795  //**********************************************************************************************
796 
797  //**SMP multiplication assignment to dense vectors**********************************************
811  template< typename VT2 > // Type of the target dense vector
812  friend inline typename EnableIf< UseSMPAssign<VT2> >::Type
813  smpMultAssign( DenseVector<VT2,TF>& lhs, const DVecTransExpr& rhs )
814  {
816 
817  BLAZE_INTERNAL_ASSERT( (~lhs).size() == rhs.size(), "Invalid vector sizes" );
818 
819  DVecTransposer<VT2,!TF> tmp( ~lhs );
820  smpMultAssign( tmp, rhs.dv_ );
821  }
823  //**********************************************************************************************
824 
825  //**SMP multiplication assignment to sparse vectors*********************************************
826  // No special implementation for the SMP multiplication assignment to sparse vectors.
827  //**********************************************************************************************
828 
829  //**Trans function******************************************************************************
847  template< typename VT2 // Type of the dense vector
848  , bool TF2 > // Transpose flag of the dense vector
849  friend inline Operand trans( const DVecTransExpr<VT2,TF2>& dv )
850  {
852 
853  return dv.dv_;
854  }
856  //**********************************************************************************************
857 
858  //**Compile time checks*************************************************************************
863  //**********************************************************************************************
864 };
865 //*************************************************************************************************
866 
867 
868 
869 
870 //=================================================================================================
871 //
872 // GLOBAL OPERATORS
873 //
874 //=================================================================================================
875 
876 //*************************************************************************************************
895 template< typename VT // Type of the dense vector
896  , bool TF > // Transpose flag
898 {
900 
901  return DVecTransExpr<VT,!TF>( ~dv );
902 }
903 //*************************************************************************************************
904 
905 
906 
907 
908 //=================================================================================================
909 //
910 // EXPRESSION TRAIT SPECIALIZATIONS
911 //
912 //=================================================================================================
913 
914 //*************************************************************************************************
916 template< typename VT, bool TF, bool AF >
917 struct SubvectorExprTrait< DVecTransExpr<VT,TF>, AF >
918 {
919  public:
920  //**********************************************************************************************
921  typedef typename TransExprTrait< typename SubvectorExprTrait<const VT,AF>::Type >::Type Type;
922  //**********************************************************************************************
923 };
925 //*************************************************************************************************
926 
927 } // namespace blaze
928 
929 #endif
bool isAliased(const T *alias) const
Returns whether the expression is aliased with the given address alias.
Definition: DVecTransExpr.h:495
Pointer difference type of the Blaze library.
VT::TransposeType ResultType
Result type for expression template evaluations.
Definition: DVecTransExpr.h:127
ElementType & ReferenceType
Reference return type.
Definition: DVecTransExpr.h:152
const ElementType * data() const
Low-level data access to the vector elements.
Definition: DVecTransExpr.h:431
Base class for all vector transposition expression templates.The VecTransExpr class serves as a tag f...
Definition: VecTransExpr.h:65
const ConstIterator operator++(int)
Post-increment operator.
Definition: DVecTransExpr.h:216
void smpSubAssign(DenseMatrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the SMP subtraction assignment of a matrix to dense matrix.
Definition: DenseMatrix.h:152
VT::ConstIterator IteratorType
ConstIterator type of the dense vector expression.
Definition: DVecTransExpr.h:163
void smpMultAssign(DenseVector< VT1, TF1 > &lhs, const Vector< VT2, TF2 > &rhs)
Default implementation of the SMP multiplication assignment of a vector to a dense vector...
Definition: DenseVector.h:179
std::random_access_iterator_tag IteratorCategory
The iterator category.
Definition: DVecTransExpr.h:149
const This & CompositeType
Data type for composite expression templates.
Definition: CompressedMatrix.h:2408
ConstIterator end() const
Returns an iterator just past the last non-zero element of the dense vector.
Definition: DVecTransExpr.h:451
ConstIterator & operator--()
Pre-decrement operator.
Definition: DVecTransExpr.h:226
ConstIterator & operator+=(size_t inc)
Addition assignment operator.
Definition: DVecTransExpr.h:182
Header file for the DenseVector base class.
friend const ConstIterator operator+(size_t inc, const ConstIterator &it)
Addition between an integral value and a ConstIterator.
Definition: DVecTransExpr.h:358
Header file for the Computation base class.
Iterator over the elements of the dense vector.
Definition: DVecTransExpr.h:145
IntrinsicTrait< ElementType >::Type IntrinsicType
Resulting intrinsic element type.
Definition: DVecTransExpr.h:133
Header file for the RequiresEvaluation type trait.
SelectType< useAssign, const ResultType, const DVecTransExpr & >::Type CompositeType
Data type for composite expression templates.
Definition: DVecTransExpr.h:136
ConstIterator(IteratorType iterator)
Constructor for the ConstIterator class.
Definition: DVecTransExpr.h:171
IntrinsicType load(size_t index) const
Access to the intrinsic elements of the vector.
Definition: DVecTransExpr.h:418
Expression object for the transposition of a dense vector.The DVecTransposer class is a wrapper objec...
Definition: DVecTransposer.h:71
Operand dv_
Dense vector of the transposition expression.
Definition: DVecTransExpr.h:522
VT::ReturnType ReturnType
Return type for expression template evaluations.
Definition: DVecTransExpr.h:130
void smpAddAssign(DenseMatrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the SMP addition assignment of a matrix to a dense matrix.
Definition: DenseMatrix.h:122
Compile time check to query the requirement to evaluate an expression.Via this type trait it is possi...
Definition: RequiresEvaluation.h:90
SelectType< IsExpression< VT >::value, const VT, const VT & >::Type Operand
Composite data type of the dense vector expression.
Definition: DVecTransExpr.h:139
ReferenceType reference
Reference return type.
Definition: DVecTransExpr.h:159
Compile time type selection.The SelectType class template selects one of the two given types T1 and T...
Definition: SelectType.h:59
IntrinsicType load() const
Access to the intrinsic elements of the vector.
Definition: DVecTransExpr.h:257
bool operator!=(const ConstIterator &rhs) const
Inequality comparison between two ConstIterator objects.
Definition: DVecTransExpr.h:279
ElementType ValueType
Type of the underlying elements.
Definition: DVecTransExpr.h:150
Header file for the dense vector transposer.
bool canSMPAssign() const
Returns whether the expression can be used in SMP assignments.
Definition: DVecTransExpr.h:515
ConstIterator & operator-=(size_t dec)
Subtraction assignment operator.
Definition: DVecTransExpr.h:194
const Element * ConstIterator
Iterator over constant elements.
Definition: CompressedMatrix.h:2412
VT::ResultType TransposeType
Transpose type for expression template evaluations.
Definition: DVecTransExpr.h:128
void assign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the assignment of a matrix to a matrix.
Definition: Matrix.h:271
Expression object for the transposition of a sparse vector.The SVecTransposer class is a wrapper obje...
Definition: Forward.h:123
Base class for N-dimensional dense vectors.The DenseVector class is a base class for all arbitrarily ...
Definition: DenseVector.h:70
bool canAlias(const T *alias) const
Returns whether the expression can alias with the given address alias.
Definition: DVecTransExpr.h:483
bool operator>(const ConstIterator &rhs) const
Greater-than comparison between two ConstIterator objects.
Definition: DVecTransExpr.h:301
ptrdiff_t DifferenceType
Difference between two iterators.
Definition: DVecTransExpr.h:153
Constraint on the data type.
bool operator>=(const ConstIterator &rhs) const
Greater-than comparison between two ConstIterator objects.
Definition: DVecTransExpr.h:323
CompressedMatrix< Type, false > TransposeType
Transpose type for expression template evaluations.
Definition: CompressedMatrix.h:2405
Constraint on the data type.
Type ElementType
Type of the sparse matrix elements.
Definition: CompressedMatrix.h:2406
void multAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the multiplication assignment of a matrix to a matrix.
Definition: Matrix.h:361
ReturnType operator*() const
Direct access to the element at the current iterator position.
Definition: DVecTransExpr.h:247
bool operator==(const ConstIterator &rhs) const
Equality comparison between two ConstIterator objects.
Definition: DVecTransExpr.h:268
Header file for the SelectType class template.
Header file for all forward declarations for expression class templates.
Header file for the EnableIf class template.
DifferenceType operator-(const ConstIterator &rhs) const
Calculating the number of elements between two iterators.
Definition: DVecTransExpr.h:334
void smpAssign(DenseMatrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the SMP assignment of a matrix to a dense matrix.
Definition: DenseMatrix.h:92
bool operator<=(const ConstIterator &rhs) const
Less-than comparison between two ConstIterator objects.
Definition: DVecTransExpr.h:312
const Type & ReturnType
Return type for expression template evaluations.
Definition: CompressedMatrix.h:2407
Header file for the VecTransExpr base class.
Intrinsic characteristics of data types.The IntrinsicTrait class template provides the intrinsic char...
Definition: IntrinsicTrait.h:748
Header file for run time assertion macros.
void addAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the addition assignment of a matrix to a matrix.
Definition: Matrix.h:301
VT::ElementType ElementType
Resulting element type.
Definition: DVecTransExpr.h:129
friend const ConstIterator operator+(const ConstIterator &it, size_t inc)
Addition between a ConstIterator and an integral value.
Definition: DVecTransExpr.h:346
Substitution Failure Is Not An Error (SFINAE) class.The EnableIf class template is an auxiliary tool ...
Definition: EnableIf.h:184
PointerType pointer
Pointer return type.
Definition: DVecTransExpr.h:158
void subAssign(Matrix< MT1, SO1 > &lhs, const Matrix< MT2, SO2 > &rhs)
Default implementation of the subtraction assignment of a matrix to matrix.
Definition: Matrix.h:331
Header file for the TransExprTrait class template.
VT::CompositeType CT
Composite type of the dense vector expression.
Definition: DVecTransExpr.h:88
DVecTransExpr(const VT &dv)
Constructor for the DVecTransExpr class.
Definition: DVecTransExpr.h:395
DifferenceType difference_type
Difference between two iterators.
Definition: DVecTransExpr.h:160
ElementType * PointerType
Pointer return type.
Definition: DVecTransExpr.h:151
const ConstIterator operator--(int)
Post-decrement operator.
Definition: DVecTransExpr.h:237
Header file for all intrinsic functionality.
#define BLAZE_CONSTRAINT_MUST_BE_DENSE_VECTOR_TYPE(T)
Constraint on the data type.In case the given data type T is not a dense, N-dimensional vector type...
Definition: DenseVector.h:79
Header file for the sparse vector transposer.
ConstIterator & operator++()
Pre-increment operator.
Definition: DVecTransExpr.h:205
const DMatTransExpr< MT,!SO > trans(const DenseMatrix< MT, SO > &dm)
Calculation of the transpose of the given dense matrix.
Definition: DMatTransExpr.h:907
bool isAligned() const
Returns whether the operands of the expression are properly aligned in memory.
Definition: DVecTransExpr.h:505
Header file for the IsComputation type trait class.
Base class for sparse vectors.The SparseVector class is a base class for all arbitrarily sized (N-dim...
Definition: Forward.h:108
#define BLAZE_FUNCTION_TRACE
Function trace macro.This macro can be used to reliably trace function calls. In case function tracin...
Definition: FunctionTrace.h:157
This ResultType
Result type for expression template evaluations.
Definition: CompressedMatrix.h:2403
bool operator<(const ConstIterator &rhs) const
Less-than comparison between two ConstIterator objects.
Definition: DVecTransExpr.h:290
IteratorCategory iterator_category
The iterator category.
Definition: DVecTransExpr.h:156
size_t size() const
Returns the current size/dimension of the vector.
Definition: DVecTransExpr.h:461
Header file for basic type definitions.
Header file for the SubvectorExprTrait class template.
Expression object for dense vector transpositions.The DVecTransExpr class represents the compile time...
Definition: DVecTransExpr.h:82
IteratorType iterator_
Iterator to the current element.
Definition: DVecTransExpr.h:377
ReturnType operator[](size_t index) const
Subscript operator for the direct access to the vector elements.
Definition: DVecTransExpr.h:406
ConstIterator begin() const
Returns an iterator to the first non-zero element of the dense vector.
Definition: DVecTransExpr.h:441
Header file for the empty type.
ValueType value_type
Type of the underlying elements.
Definition: DVecTransExpr.h:157
friend const ConstIterator operator-(const ConstIterator &it, size_t dec)
Subtraction between a ConstIterator and an integral value.
Definition: DVecTransExpr.h:370
#define BLAZE_CONSTRAINT_MUST_BE_VECTOR_WITH_TRANSPOSE_FLAG(T, TF)
Constraint on the data type.In case the given data type T is not a dense or sparse vector type and in...
Definition: TransposeFlag.h:238
Operand operand() const
Returns the dense vector operand.
Definition: DVecTransExpr.h:471
#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
DVecTransExpr< VT, TF > This
Type of this DVecTransExpr instance.
Definition: DVecTransExpr.h:126
Header file for the IsExpression type trait class.
Header file for the FunctionTrace class.