ROOTPWA
Public Member Functions | Private Member Functions | Private Attributes | List of all members
matrix< T > Class Template Reference

#include <matrix.h>

Inheritance diagram for matrix< T >:
identityMatrix< T >

Public Member Functions

 matrix ()
 matrix (const int n, const int m)
 matrix (const int n, const int m, T *p)
 matrix (const matrix &M)
 ~matrix ()
matrix & operator= (const matrix &)
T & el (const int i, const int j)
T & element (const int i, const int j)
const T & el (const int i, const int j) const
const T & element (const int i, const int j) const
matrix operator*= (const double a)
matrix operator+= (const matrix &M)
matrix operator-= (const matrix &M)
matrix operator* (const matrix &M) const
matrix operator+ (const matrix &M) const
matrix operator- (const matrix &M) const
threeVec operator* (const threeVec &v) const
fourVec operator* (const fourVec &v) const
matrix operator* (const T &a) const
matrix conjugate () const
matrix transpose () const
matrix adjoint () const
int status () const
void setStatus (const int s)
T trace () const
T det () const
matrix LU () const
matrix inv ()
int nrows () const
int ncols () const
matrix zero ()
const matrix & print (std::ostream &os=std::cout) const
matrix & scan (std::istream &is=std::cin)

Private Member Functions

void _create (const int, const int)
void _destroy (void)
void _copy (const matrix &)
matrix _LU (int *, int *) const
matrix _lubksb (int *indx, matrix &b)

Private Attributes

int _nrows
int _ncols
T * _f
int _status

Detailed Description

template<typename T>
class matrix< T >

Definition at line 34 of file matrix.h.

Constructor & Destructor Documentation

template<typename T >
matrix< T >::matrix ( )

Definition at line 485 of file matrix.h.

template<typename T >
matrix< T >::matrix ( const int  n,
const int  m 
)

Definition at line 492 of file matrix.h.

template<typename T>
matrix< T >::matrix ( const int  n,
const int  m,
T *  p 
)

Definition at line 500 of file matrix.h.

References p.

template<typename T>
matrix< T >::matrix ( const matrix< T > &  M)

Definition at line 510 of file matrix.h.

References matrix< T >::_ncols, and matrix< T >::_nrows.

template<typename T >
matrix< T >::~matrix ( )

Definition at line 518 of file matrix.h.

Member Function Documentation

template<typename T >
void matrix< T >::_copy ( const matrix< T > &  src)
private
template<typename T >
void matrix< T >::_create ( const int  n,
const int  m 
)
private

Definition at line 445 of file matrix.h.

References n.

template<typename T >
void matrix< T >::_destroy ( void  )
private

Definition at line 474 of file matrix.h.

template<typename T >
matrix< T > matrix< T >::_LU ( int *  d,
int *  indx 
) const
private

Definition at line 148 of file matrix.h.

References matrix< T >::el(), i, mag(), matrix< T >::setStatus(), and TINY.

template<typename T >
matrix< T > matrix< T >::_lubksb ( int *  indx,
matrix< T > &  b 
)
private

Definition at line 235 of file matrix.h.

References matrix< T >::el(), i, mag(), and matrix< T >::nrows().

Referenced by matrix< T >::inv().

template<typename T >
matrix< T > matrix< T >::adjoint ( ) const

Definition at line 320 of file matrix.h.

References matrix< T >::conjugate().

template<typename T >
matrix< T > matrix< T >::conjugate ( ) const

Definition at line 296 of file matrix.h.

References conj(), matrix< T >::el(), and i.

Referenced by matrix< T >::adjoint().

template<typename T >
T matrix< T >::det ( ) const

Definition at line 122 of file matrix.h.

References d, matrix< T >::el(), and i.

template<typename T >
T & matrix< T >::el ( const int  i,
const int  j 
)
template<typename T >
const T & matrix< T >::el ( const int  i,
const int  j 
) const

Definition at line 435 of file matrix.h.

template<typename T>
T& matrix< T >::element ( const int  i,
const int  j 
)
inline

Definition at line 46 of file matrix.h.

Referenced by TPWALikelihood< complexT >::reorderIntegralMatrix().

template<typename T>
const T& matrix< T >::element ( const int  i,
const int  j 
) const
inline

Definition at line 48 of file matrix.h.

template<typename T >
matrix< T > matrix< T >::inv ( )
template<typename T >
matrix< T > matrix< T >::LU ( ) const

Definition at line 221 of file matrix.h.

References d.

template<typename T>
int matrix< T >::ncols ( ) const
inline

Definition at line 70 of file matrix.h.

template<typename T>
int matrix< T >::nrows ( ) const
inline

Definition at line 69 of file matrix.h.

Referenced by matrix< T >::_lubksb(), and TPWALikelihoodC::LoadAmplitudes().

template<typename T >
matrix< T > matrix< T >::operator* ( const matrix< T > &  M) const

Definition at line 390 of file matrix.h.

References matrix< T >::_ncols, matrix< T >::_nrows, matrix< T >::el(), and i.

template<typename T >
threeVec matrix< T >::operator* ( const threeVec &  v) const

Definition at line 601 of file matrix.h.

References threeVec::el(), and i.

template<typename T >
fourVec matrix< T >::operator* ( const fourVec &  v) const

Definition at line 614 of file matrix.h.

References fourVec::el(), and i.

template<typename T>
matrix< T > matrix< T >::operator* ( const T &  a) const

Definition at line 413 of file matrix.h.

References matrix< T >::el(), and i.

template<typename T >
matrix< T > matrix< T >::operator*= ( const double  a)

Definition at line 354 of file matrix.h.

References i.

template<typename T >
matrix< T > matrix< T >::operator+ ( const matrix< T > &  M) const

Definition at line 330 of file matrix.h.

References matrix< T >::_ncols, matrix< T >::_nrows, matrix< T >::el(), and i.

template<typename T >
matrix< T > matrix< T >::operator+= ( const matrix< T > &  M)

Definition at line 343 of file matrix.h.

References matrix< T >::_ncols, matrix< T >::_nrows, matrix< T >::el(), and i.

template<typename T >
matrix< T > matrix< T >::operator- ( const matrix< T > &  M) const

Definition at line 365 of file matrix.h.

References matrix< T >::_ncols, matrix< T >::_nrows, matrix< T >::el(), and i.

template<typename T >
matrix< T > matrix< T >::operator-= ( const matrix< T > &  M)

Definition at line 378 of file matrix.h.

References matrix< T >::_ncols, matrix< T >::_nrows, matrix< T >::el(), and i.

template<typename T >
matrix< T > & matrix< T >::operator= ( const matrix< T > &  M)

Definition at line 526 of file matrix.h.

template<typename T >
const matrix< T > & matrix< T >::print ( std::ostream &  os = std::cout) const

Definition at line 535 of file matrix.h.

References i.

Referenced by operator<<().

template<typename T >
matrix< T > & matrix< T >::scan ( std::istream &  is = std::cin)

Definition at line 554 of file matrix.h.

References i.

Referenced by operator>>().

template<typename T>
void matrix< T >::setStatus ( const int  s)
inline

Definition at line 64 of file matrix.h.

Referenced by matrix< T >::_LU(), and matrix< T >::inv().

template<typename T>
int matrix< T >::status ( ) const
inline

Definition at line 63 of file matrix.h.

Referenced by matrix< T >::_copy(), and matrix< T >::inv().

template<typename T >
T matrix< T >::trace ( ) const

Definition at line 110 of file matrix.h.

References i.

template<typename T >
matrix< T > matrix< T >::transpose ( ) const

Definition at line 308 of file matrix.h.

References matrix< T >::el(), and i.

template<typename T >
matrix< T > matrix< T >::zero ( )

Definition at line 592 of file matrix.h.

Member Data Documentation

template<typename T>
T* matrix< T >::_f
private

Definition at line 80 of file matrix.h.

Referenced by matrix< T >::_copy().

template<typename T>
int matrix< T >::_ncols
private
template<typename T>
int matrix< T >::_nrows
private
template<typename T>
int matrix< T >::_status
private

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