Logo ROOT   6.08/07
Reference Guide
List of all members | Public Types | Public Member Functions | Private Attributes | List of all members
ROOT::Math::MatRepStd< T, D1, D2 > Class Template Reference

template<class T, unsigned int D1, unsigned int D2 = D1>
class ROOT::Math::MatRepStd< T, D1, D2 >

Expression wrapper class for Matrix objects.

MatRepStd Standard Matrix representation for a general D1 x D2 matrix.

This class is itself a template on the contained type T, the number of rows and the number of columns. Its data member is an array T[nrows*ncols] containing the matrix data. The data are stored in the row-major C convention. For example, for a matrix, M, of size 3x3, the data \( \left[a_0,a_1,a_2,.......,a_7,a_8 \right] \)d are stored in the following order:

\[ M = \left( \begin{array}{ccc} a_0 & a_1 & a_2 \\ a_3 & a_4 & a_5 \\ a_6 & a_7 & a_8 \end{array} \right) \]

Definition at line 134 of file Expression.h.

Public Types

enum  { kRows = D1, kCols = D2, kSize = D1*D2 }
 
typedef T value_type
 

Public Member Functions

apply (unsigned int i) const
 
T * Array ()
 
const T * Array () const
 
const T & operator() (unsigned int i, unsigned int j) const
 
T & operator() (unsigned int i, unsigned int j)
 
template<class R >
MatRepStd< T, D1, D2 > & operator+= (const R &rhs)
 
template<class R >
MatRepStd< T, D1, D2 > & operator-= (const R &rhs)
 
template<class R >
MatRepStd< T, D1, D2 > & operator= (const R &rhs)
 
template<class R >
bool operator== (const R &rhs) const
 
T & operator[] (unsigned int i)
 
const T & operator[] (unsigned int i) const
 

Private Attributes

fArray [kSize]
 

#include <Math/Expression.h>

Member Typedef Documentation

◆ value_type

template<class T, unsigned int D1, unsigned int D2 = D1>
typedef T ROOT::Math::MatRepStd< T, D1, D2 >::value_type

Definition at line 59 of file MatrixRepresentationsStatic.h.

Member Enumeration Documentation

◆ anonymous enum

template<class T, unsigned int D1, unsigned int D2 = D1>
anonymous enum
Enumerator
kRows 

return no. of matrix rows

kCols 

return no. of matrix columns

kSize 

return no of elements: rows*columns

Definition at line 104 of file MatrixRepresentationsStatic.h.

Member Function Documentation

◆ apply()

template<class T, unsigned int D1, unsigned int D2 = D1>
T ROOT::Math::MatRepStd< T, D1, D2 >::apply ( unsigned int  i) const
inline

Definition at line 71 of file MatrixRepresentationsStatic.h.

◆ Array() [1/2]

template<class T, unsigned int D1, unsigned int D2 = D1>
T* ROOT::Math::MatRepStd< T, D1, D2 >::Array ( )
inline

Definition at line 73 of file MatrixRepresentationsStatic.h.

◆ Array() [2/2]

template<class T, unsigned int D1, unsigned int D2 = D1>
const T* ROOT::Math::MatRepStd< T, D1, D2 >::Array ( ) const
inline

Definition at line 75 of file MatrixRepresentationsStatic.h.

◆ operator()() [1/2]

template<class T, unsigned int D1, unsigned int D2 = D1>
const T& ROOT::Math::MatRepStd< T, D1, D2 >::operator() ( unsigned int  i,
unsigned int  j 
) const
inline

Definition at line 61 of file MatrixRepresentationsStatic.h.

◆ operator()() [2/2]

template<class T, unsigned int D1, unsigned int D2 = D1>
T& ROOT::Math::MatRepStd< T, D1, D2 >::operator() ( unsigned int  i,
unsigned int  j 
)
inline

Definition at line 64 of file MatrixRepresentationsStatic.h.

◆ operator+=()

template<class T, unsigned int D1, unsigned int D2 = D1>
template<class R >
MatRepStd<T, D1, D2>& ROOT::Math::MatRepStd< T, D1, D2 >::operator+= ( const R rhs)
inline

Definition at line 78 of file MatrixRepresentationsStatic.h.

◆ operator-=()

template<class T, unsigned int D1, unsigned int D2 = D1>
template<class R >
MatRepStd<T, D1, D2>& ROOT::Math::MatRepStd< T, D1, D2 >::operator-= ( const R rhs)
inline

Definition at line 84 of file MatrixRepresentationsStatic.h.

◆ operator=()

template<class T, unsigned int D1, unsigned int D2 = D1>
template<class R >
MatRepStd<T, D1, D2>& ROOT::Math::MatRepStd< T, D1, D2 >::operator= ( const R rhs)
inline

Definition at line 90 of file MatrixRepresentationsStatic.h.

◆ operator==()

template<class T, unsigned int D1, unsigned int D2 = D1>
template<class R >
bool ROOT::Math::MatRepStd< T, D1, D2 >::operator== ( const R rhs) const
inline

Definition at line 96 of file MatrixRepresentationsStatic.h.

◆ operator[]() [1/2]

template<class T, unsigned int D1, unsigned int D2 = D1>
T& ROOT::Math::MatRepStd< T, D1, D2 >::operator[] ( unsigned int  i)
inline

Definition at line 67 of file MatrixRepresentationsStatic.h.

◆ operator[]() [2/2]

template<class T, unsigned int D1, unsigned int D2 = D1>
const T& ROOT::Math::MatRepStd< T, D1, D2 >::operator[] ( unsigned int  i) const
inline

Definition at line 69 of file MatrixRepresentationsStatic.h.

Member Data Documentation

◆ fArray

template<class T, unsigned int D1, unsigned int D2 = D1>
T ROOT::Math::MatRepStd< T, D1, D2 >::fArray[kSize]
private

Definition at line 115 of file MatrixRepresentationsStatic.h.


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