Chemical Data Processing Library C++ API - Version 1.2.0
Public Types | Public Member Functions | Friends | List of all members
CDPL::Math::Matrix< T, A > Class Template Reference

#include <Matrix.hpp>

+ Inheritance diagram for CDPL::Math::Matrix< T, A >:

Public Types

typedef T ValueType
 
typedef T & Reference
 
typedef const T & ConstReference
 
typedef A::size_type SizeType
 
typedef A::difference_type DifferenceType
 
typedef A ArrayType
 
typedef T * Pointer
 
typedef const T * ConstPointer
 
typedef MatrixReference< SelfTypeClosureType
 
typedef const MatrixReference< const SelfTypeConstClosureType
 
typedef SelfType MatrixTemporaryType
 
typedef Vector< T, A > VectorTemporaryType
 
typedef std::shared_ptr< SelfTypeSharedPointer
 
typedef std::initializer_list< std::initializer_list< T > > InitializerListType
 
- Public Types inherited from CDPL::Math::MatrixContainer< Matrix< T, std::vector< T > > >
typedef Matrix< T, std::vector< T > > ContainerType
 
- Public Types inherited from CDPL::Math::MatrixExpression< E >
typedef E ExpressionType
 
- Public Types inherited from CDPL::Math::Expression< E >
typedef E ExpressionType
 

Public Member Functions

 Matrix ()
 
 Matrix (SizeType m, SizeType n)
 
 Matrix (SizeType m, SizeType n, const ValueType &v)
 
 Matrix (const Matrix &m)
 
 Matrix (Matrix &&m)
 
 Matrix (InitializerListType l)
 
template<typename E >
 Matrix (const MatrixExpression< E > &e)
 
Reference operator() (SizeType i, SizeType j)
 
ConstReference operator() (SizeType i, SizeType j) const
 
bool isEmpty () const
 
SizeType getSize1 () const
 
SizeType getSize2 () const
 
SizeType getMaxSize () const
 
ArrayTypegetData ()
 
const ArrayTypegetData () const
 
Matrixoperator= (const Matrix &m)
 
Matrixoperator= (Matrix &&m)
 
template<typename C >
Matrixoperator= (const MatrixContainer< C > &c)
 
Matrixoperator= (InitializerListType l)
 
template<typename E >
Matrixoperator= (const MatrixExpression< E > &e)
 
template<typename C >
Matrixoperator+= (const MatrixContainer< C > &c)
 
Matrixoperator+= (InitializerListType l)
 
template<typename E >
Matrixoperator+= (const MatrixExpression< E > &e)
 
template<typename C >
Matrixoperator-= (const MatrixContainer< C > &c)
 
Matrixoperator-= (InitializerListType l)
 
template<typename E >
Matrixoperator-= (const MatrixExpression< E > &e)
 
template<typename T1 >
std::enable_if< IsScalar< T1 >::value, Matrix >::type & operator*= (const T1 &t)
 
template<typename T1 >
std::enable_if< IsScalar< T1 >::value, Matrix >::type & operator/= (const T1 &t)
 
template<typename E >
Matrixassign (const MatrixExpression< E > &e)
 
Matrixassign (InitializerListType l)
 
template<typename E >
MatrixplusAssign (const MatrixExpression< E > &e)
 
MatrixplusAssign (InitializerListType l)
 
template<typename E >
MatrixminusAssign (const MatrixExpression< E > &e)
 
MatrixminusAssign (InitializerListType l)
 
void swap (Matrix &m)
 
void clear (const ValueType &v=ValueType())
 
void resize (SizeType m, SizeType n, bool preserve=true, const ValueType &v=ValueType())
 
- Public Member Functions inherited from CDPL::Math::MatrixContainer< Matrix< T, std::vector< T > > >
const ContainerTypeoperator() () const
 
ContainerTypeoperator() ()
 
- Public Member Functions inherited from CDPL::Math::MatrixExpression< E >
const ExpressionTypeoperator() () const
 
ExpressionTypeoperator() ()
 

Friends

void swap (Matrix &m1, Matrix &m2)
 

Additional Inherited Members

- Protected Member Functions inherited from CDPL::Math::MatrixContainer< Matrix< T, std::vector< T > > >
 MatrixContainer ()
 
 ~MatrixContainer ()
 
- Protected Member Functions inherited from CDPL::Math::MatrixExpression< E >
 MatrixExpression ()
 
 ~MatrixExpression ()
 
- Protected Member Functions inherited from CDPL::Math::Expression< E >
 Expression ()
 
 ~Expression ()
 

Member Typedef Documentation

◆ ValueType

template<typename T , typename A = std::vector<T>>
typedef T CDPL::Math::Matrix< T, A >::ValueType

◆ Reference

template<typename T , typename A = std::vector<T>>
typedef T& CDPL::Math::Matrix< T, A >::Reference

◆ ConstReference

template<typename T , typename A = std::vector<T>>
typedef const T& CDPL::Math::Matrix< T, A >::ConstReference

◆ SizeType

template<typename T , typename A = std::vector<T>>
typedef A::size_type CDPL::Math::Matrix< T, A >::SizeType

◆ DifferenceType

template<typename T , typename A = std::vector<T>>
typedef A::difference_type CDPL::Math::Matrix< T, A >::DifferenceType

◆ ArrayType

template<typename T , typename A = std::vector<T>>
typedef A CDPL::Math::Matrix< T, A >::ArrayType

◆ Pointer

template<typename T , typename A = std::vector<T>>
typedef T* CDPL::Math::Matrix< T, A >::Pointer

◆ ConstPointer

template<typename T , typename A = std::vector<T>>
typedef const T* CDPL::Math::Matrix< T, A >::ConstPointer

◆ ClosureType

template<typename T , typename A = std::vector<T>>
typedef MatrixReference<SelfType> CDPL::Math::Matrix< T, A >::ClosureType

◆ ConstClosureType

template<typename T , typename A = std::vector<T>>
typedef const MatrixReference<const SelfType> CDPL::Math::Matrix< T, A >::ConstClosureType

◆ MatrixTemporaryType

template<typename T , typename A = std::vector<T>>
typedef SelfType CDPL::Math::Matrix< T, A >::MatrixTemporaryType

◆ VectorTemporaryType

template<typename T , typename A = std::vector<T>>
typedef Vector<T, A> CDPL::Math::Matrix< T, A >::VectorTemporaryType

◆ SharedPointer

template<typename T , typename A = std::vector<T>>
typedef std::shared_ptr<SelfType> CDPL::Math::Matrix< T, A >::SharedPointer

◆ InitializerListType

template<typename T , typename A = std::vector<T>>
typedef std::initializer_list<std::initializer_list<T> > CDPL::Math::Matrix< T, A >::InitializerListType

Constructor & Destructor Documentation

◆ Matrix() [1/7]

template<typename T , typename A = std::vector<T>>
CDPL::Math::Matrix< T, A >::Matrix ( )
inline

◆ Matrix() [2/7]

template<typename T , typename A = std::vector<T>>
CDPL::Math::Matrix< T, A >::Matrix ( SizeType  m,
SizeType  n 
)
inline

◆ Matrix() [3/7]

template<typename T , typename A = std::vector<T>>
CDPL::Math::Matrix< T, A >::Matrix ( SizeType  m,
SizeType  n,
const ValueType v 
)
inline

◆ Matrix() [4/7]

template<typename T , typename A = std::vector<T>>
CDPL::Math::Matrix< T, A >::Matrix ( const Matrix< T, A > &  m)
inline

◆ Matrix() [5/7]

template<typename T , typename A = std::vector<T>>
CDPL::Math::Matrix< T, A >::Matrix ( Matrix< T, A > &&  m)
inline

◆ Matrix() [6/7]

template<typename T , typename A = std::vector<T>>
CDPL::Math::Matrix< T, A >::Matrix ( InitializerListType  l)
inline

◆ Matrix() [7/7]

template<typename T , typename A = std::vector<T>>
template<typename E >
CDPL::Math::Matrix< T, A >::Matrix ( const MatrixExpression< E > &  e)
inline

Member Function Documentation

◆ operator()() [1/2]

template<typename T , typename A = std::vector<T>>
Reference CDPL::Math::Matrix< T, A >::operator() ( SizeType  i,
SizeType  j 
)
inline

◆ operator()() [2/2]

template<typename T , typename A = std::vector<T>>
ConstReference CDPL::Math::Matrix< T, A >::operator() ( SizeType  i,
SizeType  j 
) const
inline

◆ isEmpty()

template<typename T , typename A = std::vector<T>>
bool CDPL::Math::Matrix< T, A >::isEmpty ( ) const
inline

◆ getSize1()

template<typename T , typename A = std::vector<T>>
SizeType CDPL::Math::Matrix< T, A >::getSize1 ( ) const
inline

◆ getSize2()

template<typename T , typename A = std::vector<T>>
SizeType CDPL::Math::Matrix< T, A >::getSize2 ( ) const
inline

◆ getMaxSize()

template<typename T , typename A = std::vector<T>>
SizeType CDPL::Math::Matrix< T, A >::getMaxSize ( ) const
inline

◆ getData() [1/2]

template<typename T , typename A = std::vector<T>>
ArrayType& CDPL::Math::Matrix< T, A >::getData ( )
inline

◆ getData() [2/2]

template<typename T , typename A = std::vector<T>>
const ArrayType& CDPL::Math::Matrix< T, A >::getData ( ) const
inline

◆ operator=() [1/5]

template<typename T , typename A = std::vector<T>>
Matrix& CDPL::Math::Matrix< T, A >::operator= ( const Matrix< T, A > &  m)
inline

◆ operator=() [2/5]

template<typename T , typename A = std::vector<T>>
Matrix& CDPL::Math::Matrix< T, A >::operator= ( Matrix< T, A > &&  m)
inline

◆ operator=() [3/5]

template<typename T , typename A = std::vector<T>>
template<typename C >
Matrix& CDPL::Math::Matrix< T, A >::operator= ( const MatrixContainer< C > &  c)
inline

◆ operator=() [4/5]

template<typename T , typename A = std::vector<T>>
Matrix& CDPL::Math::Matrix< T, A >::operator= ( InitializerListType  l)
inline

◆ operator=() [5/5]

template<typename T , typename A = std::vector<T>>
template<typename E >
Matrix& CDPL::Math::Matrix< T, A >::operator= ( const MatrixExpression< E > &  e)
inline

◆ operator+=() [1/3]

template<typename T , typename A = std::vector<T>>
template<typename C >
Matrix& CDPL::Math::Matrix< T, A >::operator+= ( const MatrixContainer< C > &  c)
inline

◆ operator+=() [2/3]

template<typename T , typename A = std::vector<T>>
Matrix& CDPL::Math::Matrix< T, A >::operator+= ( InitializerListType  l)
inline

◆ operator+=() [3/3]

template<typename T , typename A = std::vector<T>>
template<typename E >
Matrix& CDPL::Math::Matrix< T, A >::operator+= ( const MatrixExpression< E > &  e)
inline

◆ operator-=() [1/3]

template<typename T , typename A = std::vector<T>>
template<typename C >
Matrix& CDPL::Math::Matrix< T, A >::operator-= ( const MatrixContainer< C > &  c)
inline

◆ operator-=() [2/3]

template<typename T , typename A = std::vector<T>>
Matrix& CDPL::Math::Matrix< T, A >::operator-= ( InitializerListType  l)
inline

◆ operator-=() [3/3]

template<typename T , typename A = std::vector<T>>
template<typename E >
Matrix& CDPL::Math::Matrix< T, A >::operator-= ( const MatrixExpression< E > &  e)
inline

◆ operator*=()

template<typename T , typename A = std::vector<T>>
template<typename T1 >
std::enable_if<IsScalar<T1>::value, Matrix>::type& CDPL::Math::Matrix< T, A >::operator*= ( const T1 &  t)
inline

◆ operator/=()

template<typename T , typename A = std::vector<T>>
template<typename T1 >
std::enable_if<IsScalar<T1>::value, Matrix>::type& CDPL::Math::Matrix< T, A >::operator/= ( const T1 &  t)
inline

◆ assign() [1/2]

template<typename T , typename A = std::vector<T>>
template<typename E >
Matrix& CDPL::Math::Matrix< T, A >::assign ( const MatrixExpression< E > &  e)
inline

◆ assign() [2/2]

template<typename T , typename A = std::vector<T>>
Matrix& CDPL::Math::Matrix< T, A >::assign ( InitializerListType  l)
inline

◆ plusAssign() [1/2]

template<typename T , typename A = std::vector<T>>
template<typename E >
Matrix& CDPL::Math::Matrix< T, A >::plusAssign ( const MatrixExpression< E > &  e)
inline

◆ plusAssign() [2/2]

template<typename T , typename A = std::vector<T>>
Matrix& CDPL::Math::Matrix< T, A >::plusAssign ( InitializerListType  l)
inline

◆ minusAssign() [1/2]

template<typename T , typename A = std::vector<T>>
template<typename E >
Matrix& CDPL::Math::Matrix< T, A >::minusAssign ( const MatrixExpression< E > &  e)
inline

◆ minusAssign() [2/2]

template<typename T , typename A = std::vector<T>>
Matrix& CDPL::Math::Matrix< T, A >::minusAssign ( InitializerListType  l)
inline

◆ swap()

template<typename T , typename A = std::vector<T>>
void CDPL::Math::Matrix< T, A >::swap ( Matrix< T, A > &  m)
inline

◆ clear()

template<typename T , typename A = std::vector<T>>
void CDPL::Math::Matrix< T, A >::clear ( const ValueType v = ValueType())
inline

◆ resize()

template<typename T , typename A = std::vector<T>>
void CDPL::Math::Matrix< T, A >::resize ( SizeType  m,
SizeType  n,
bool  preserve = true,
const ValueType v = ValueType() 
)
inline

Friends And Related Function Documentation

◆ swap

template<typename T , typename A = std::vector<T>>
void swap ( Matrix< T, A > &  m1,
Matrix< T, A > &  m2 
)
friend

The documentation for this class was generated from the following files: