#include <MboMatrix.h>
Public Member Functions | |
Matrix (const Matrix< _Ty, _Cols, _Rows > &m) | |
size_t | numRows () |
size_t | numCols () |
_Ty & | operator() (size_t row, size_t col) throw (MatrixException) |
Matrix< _Ty, _Cols, _Rows > | operator+ () |
Matrix< _Ty, _Cols, _Rows > | operator- () |
Matrix< _Ty, _Cols, _Rows > & | operator= (const Matrix< _Ty, _Cols, _Rows > &m) |
Matrix< _Ty, _Cols, _Rows > & | operator+= (const Matrix< _Ty, _Cols, _Rows > &m) throw (MatrixException) |
Matrix< _Ty, _Cols, _Rows > & | operator-= (const Matrix< _Ty, _Cols, _Rows > &m) throw (MatrixException) |
Matrix< _Ty, _Cols, _Rows > & | operator *= (const Matrix< _Ty, _Cols, _Rows > &m) throw (MatrixException) |
Matrix< _Ty, _Cols, _Rows > & | operator *= (const _Ty &c) |
Matrix< _Ty, _Cols, _Rows > & | operator/= (const _Ty &c) |
Matrix< _Ty, _Cols, _Rows > & | operator^= (const size_t &pow) throw (MatrixException) |
void | Null (const size_t &row, const size_t &col) |
void | Null () |
void | Unit (const size_t &row) |
void | Unit () |
Matrix< _Ty, _Cols, _Rows > | Solve (const Matrix< _Ty, _Cols, _Rows > &v) const throw (MatrixException) |
Matrix< _Ty, _Cols, _Rows > | Adj () throw (MatrixException) |
_Ty | Det () throw (MatrixException) |
_Ty | Norm () |
_Ty | Cofactor (size_t row, size_t col) throw (MatrixException) |
_Ty | Cond () |
bool | IsSquare () |
bool | IsSingular () |
bool | IsDiagonal () |
bool | IsScalar () |
bool | IsUnit () |
bool | IsNull () |
bool | IsSymmetric () |
bool | IsSkewSymmetric () |
bool | IsUpperTiangular () |
bool | IsLowerTiangular () |
template<class _Ty, size_t _Cols, size_t _Rows> | |
Matrix< _Ty, _Cols, _Rows > | operator- () |
Friends | |
Matrix< _Ty, _Cols2, _Rows1 > | _Cols |
bool | operator== (const Matrix< _Ty, _Cols, _Rows > &m1, const Matrix< _Ty, _Cols, _Rows > &m2) |
bool | operator!= (const Matrix< _Ty, _Cols, _Rows > &m1, const Matrix< _Ty, _Cols, _Rows > &m2) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator+ (const Matrix< _Ty, _Cols, _Rows > &m1, const Matrix< _Ty, _Cols, _Rows > &m2) throw (MatrixException) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator- (const Matrix< _Ty, _Cols, _Rows > &m1, const Matrix< _Ty, _Cols, _Rows > &m2) throw (MatrixException) |
template<class _Ty, size_t _Cols1Rows2, size_t _Rows1, size_t _Cols2> | |
Matrix< _Ty, _Cols2, _Rows1 > | operator * (const Matrix< _Ty, _Cols1Rows2, _Rows1 > &lhs, const Matrix< _Ty, _Cols2, _Cols1Rows2 > &rhs) friend template< class _Ty |
Matrix< _Ty, _Cols2, _Rows1 > _Rows Matrix< _Ty, _Cols, _Rows > | operator * (const Matrix< _Ty, _Cols, _Rows > &m1, const Matrix< _Ty, _Cols, _Rows > &m2) throw (MatrixException) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator * (const Matrix< _Ty, _Cols, _Rows > &m, const T &no) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator * (const T &no, const Matrix< _Ty, _Cols, _Rows > &m) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator/ (const Matrix< _Ty, _Cols, _Rows > &m1, const Matrix< _Ty, _Cols, _Rows > &m2) throw (MatrixException) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator/ (const Matrix< _Ty, _Cols, _Rows > &m, const T &no) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator/ (const T &no, const Matrix< _Ty, _Cols, _Rows > &m) throw (MatrixException) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator~ (const Matrix< _Ty, _Cols, _Rows > &m) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator! (Matrix< _Ty, _Cols, _Rows > m) throw (MatrixException) |
template<class _Ty, _Cols , _Rows > | |
Matrix< _Ty, _Cols, _Rows > | operator^ (const Matrix< _Ty, _Cols, _Rows > &m, const size_t &pow) throw (MatrixException) |
istream & | operator>> (istream &i, Matrix< _Ty, _Cols, _Rows > &m) |
ostream & | operator<< (ostream &o, Matrix< _Ty, _Cols, _Rows > &m) |
Definition at line 68 of file MboMatrix.h.
mbo::Matrix< _Ty, _Cols, _Rows >::Matrix | ( | const Matrix< _Ty, _Cols, _Rows > & | m | ) | [inline] |
size_t mbo::Matrix< _Ty, _Cols, _Rows >::numRows | ( | ) | [inline] |
size_t mbo::Matrix< _Ty, _Cols, _Rows >::numCols | ( | ) | [inline] |
_Ty & mbo::Matrix< _Ty, _Cols, _Rows >::operator() | ( | size_t | row, | |
size_t | col | |||
) | throw (MatrixException) [inline] |
Definition at line 170 of file MboMatrix.h.
References mbo::Matrix< _Ty, _Cols, _Rows >::_Cols.
00171 { 00172 if (nRow >= _Rows || nCol >= _Cols) 00173 { 00174 throw MatrixException("Matrix<_Ty, _Cols, _Rows>::operator(): Index out of range!"); 00175 } 00176 return Val[row][col]; 00177 }
Matrix<_Ty, _Cols, _Rows> mbo::Matrix< _Ty, _Cols, _Rows >::operator+ | ( | ) | [inline] |
Matrix<_Ty, _Cols, _Rows> mbo::Matrix< _Ty, _Cols, _Rows >::operator- | ( | ) |
Matrix< _Ty, _Cols, _Rows > & mbo::Matrix< _Ty, _Cols, _Rows >::operator= | ( | const Matrix< _Ty, _Cols, _Rows > & | m | ) | [inline] |
Matrix<_Ty, _Cols, _Rows>& mbo::Matrix< _Ty, _Cols, _Rows >::operator+= | ( | const Matrix< _Ty, _Cols, _Rows > & | m | ) | throw (MatrixException) |
Matrix<_Ty, _Cols, _Rows>& mbo::Matrix< _Ty, _Cols, _Rows >::operator-= | ( | const Matrix< _Ty, _Cols, _Rows > & | m | ) | throw (MatrixException) |
Matrix<_Ty, _Cols, _Rows>& mbo::Matrix< _Ty, _Cols, _Rows >::operator *= | ( | const Matrix< _Ty, _Cols, _Rows > & | m | ) | throw (MatrixException) |
Matrix<_Ty, _Cols, _Rows>& mbo::Matrix< _Ty, _Cols, _Rows >::operator *= | ( | const _Ty & | c | ) |
Matrix<_Ty, _Cols, _Rows>& mbo::Matrix< _Ty, _Cols, _Rows >::operator/= | ( | const _Ty & | c | ) |
Matrix<_Ty, _Cols, _Rows>& mbo::Matrix< _Ty, _Cols, _Rows >::operator^= | ( | const size_t & | pow | ) | throw (MatrixException) |
void mbo::Matrix< _Ty, _Cols, _Rows >::Null | ( | const size_t & | row, | |
const size_t & | col | |||
) |
void mbo::Matrix< _Ty, _Cols, _Rows >::Null | ( | ) |
void mbo::Matrix< _Ty, _Cols, _Rows >::Unit | ( | const size_t & | row | ) |
void mbo::Matrix< _Ty, _Cols, _Rows >::Unit | ( | ) |
Matrix<_Ty, _Cols, _Rows> mbo::Matrix< _Ty, _Cols, _Rows >::Solve | ( | const Matrix< _Ty, _Cols, _Rows > & | v | ) | const throw (MatrixException) |
Matrix<_Ty, _Cols, _Rows> mbo::Matrix< _Ty, _Cols, _Rows >::Adj | ( | ) | throw (MatrixException) |
_Ty mbo::Matrix< _Ty, _Cols, _Rows >::Det | ( | ) | throw (MatrixException) |
_Ty mbo::Matrix< _Ty, _Cols, _Rows >::Norm | ( | ) |
_Ty mbo::Matrix< _Ty, _Cols, _Rows >::Cofactor | ( | size_t | row, | |
size_t | col | |||
) | throw (MatrixException) |
_Ty mbo::Matrix< _Ty, _Cols, _Rows >::Cond | ( | ) |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsSquare | ( | ) | [inline] |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsSingular | ( | ) |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsDiagonal | ( | ) |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsScalar | ( | ) |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsUnit | ( | ) |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsNull | ( | ) |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsSymmetric | ( | ) |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsSkewSymmetric | ( | ) |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsUpperTiangular | ( | ) |
bool mbo::Matrix< _Ty, _Cols, _Rows >::IsLowerTiangular | ( | ) |
Matrix<_Ty, _Cols, _Rows> mbo::Matrix< _Ty, _Cols, _Rows >::operator- | ( | ) | [inline] |
Definition at line 329 of file MboMatrix.h.
References mbo::Matrix< _Ty, _Cols, _Rows >::_Cols, and mbo::Matrix< _Ty, _Cols, _Rows >::Val.
00330 { 00331 Matrix<_Ty, _Cols, _Rows> ret(); 00332 00333 for (size_t i=0; i < _Rows; i++) 00334 { 00335 for (size_t j=0; j < _Cols; j++) 00336 { 00337 ret.Val[i][j] = - Val[i][j]; 00338 } 00339 } 00340 return ret; 00341 }
friend Matrix<_Ty, _Cols2, _Rows1> _Cols [friend] |
Definition at line 104 of file MboMatrix.h.
Referenced by mbo::Matrix< _Ty, _Cols, _Rows >::operator()(), operator+(), operator-(), mbo::Matrix< _Ty, _Cols, _Rows >::operator-(), mbo::operator==(), and operator~().
bool operator== | ( | const Matrix< _Ty, _Cols, _Rows > & | m1, | |
const Matrix< _Ty, _Cols, _Rows > & | m2 | |||
) | [friend] |
Definition at line 218 of file MboMatrix.h.
00219 { 00220 for (size_t i=0; i < _Rows; i++) 00221 { 00222 for (size_t j=0; j < _Cols; i++) 00223 { 00224 if (lhs1.Val[i][j] != rhs2.Val[i][j]) 00225 return false; 00226 } 00227 } 00228 }
bool operator!= | ( | const Matrix< _Ty, _Cols, _Rows > & | m1, | |
const Matrix< _Ty, _Cols, _Rows > & | m2 | |||
) | [friend] |
Matrix<_Ty, _Cols, _Rows> operator+ | ( | const Matrix< _Ty, _Cols, _Rows > & | m1, | |
const Matrix< _Ty, _Cols, _Rows > & | m2 | |||
) | throw (MatrixException) [friend] |
Matrix<_Ty, _Cols, _Rows> operator- | ( | const Matrix< _Ty, _Cols, _Rows > & | m1, | |
const Matrix< _Ty, _Cols, _Rows > & | m2 | |||
) | throw (MatrixException) [friend] |
Matrix<_Ty, _Cols2, _Rows1> operator * | ( | const Matrix< _Ty, _Cols1Rows2, _Rows1 > & | lhs, | |
const Matrix< _Ty, _Cols2, _Cols1Rows2 > & | rhs | |||
) | [friend] |
Matrix<_Ty, _Cols2, _Rows1> _Rows Matrix<_Ty, _Cols, _Rows> operator * | ( | const Matrix< _Ty, _Cols, _Rows > & | m1, | |
const Matrix< _Ty, _Cols, _Rows > & | m2 | |||
) | throw (MatrixException) [friend] |
Matrix<_Ty, _Cols, _Rows> operator * | ( | const Matrix< _Ty, _Cols, _Rows > & | m, | |
const T & | no | |||
) | [friend] |
Matrix<_Ty, _Cols, _Rows> operator/ | ( | const Matrix< _Ty, _Cols, _Rows > & | m1, | |
const Matrix< _Ty, _Cols, _Rows > & | m2 | |||
) | throw (MatrixException) [friend] |
Matrix<_Ty, _Cols, _Rows> operator/ | ( | const T & | no, | |
const Matrix< _Ty, _Cols, _Rows > & | m | |||
) | throw (MatrixException) [friend] |
Matrix<_Ty, _Cols, _Rows> operator~ | ( | const Matrix< _Ty, _Cols, _Rows > & | m | ) | [friend] |
Matrix<_Ty, _Cols, _Rows> operator! | ( | Matrix< _Ty, _Cols, _Rows > | m | ) | throw (MatrixException) [friend] |
Matrix<_Ty, _Cols, _Rows> operator^ | ( | const Matrix< _Ty, _Cols, _Rows > & | m, | |
const size_t & | pow | |||
) | throw (MatrixException) [friend] |
istream& operator>> | ( | istream & | i, | |
Matrix< _Ty, _Cols, _Rows > & | m | |||
) | [friend] |
Definition at line 181 of file MboMatrix.h.
00182 { 00183 for (size_t i=0; i < m.Row; i++) 00184 { 00185 for (size_t j=0; j < m.Col; j++) 00186 { 00187 in >> m.Val[i][j]; 00188 } 00189 } 00190 return in; 00191 }
ostream& operator<< | ( | ostream & | o, | |
Matrix< _Ty, _Cols, _Rows > & | m | |||
) | [friend] |
Definition at line 195 of file MboMatrix.h.
00196 { 00197 for (size_t i=0; i < m.Row; i++) 00198 { 00199 for (size_t j=0; j < m.Col; j++) 00200 { 00201 out << m.Val[i][j] << '\t'; 00202 } 00203 out << endl; 00204 } 00205 return out; 00206 }
Hosted on code.google.com | © Marcus Börger | Generated on Fri Jan 18 21:21:12 2008 for MBO-lib by ![]() |