23 #include "vnl/vnl_matrix_fixed.txx"
24 #include "vnl/vnl_transpose.h"
25 #include "vnl/algo/vnl_matrix_inverse.h"
26 #include "vnl/vnl_matrix.h"
27 #include "vnl/algo/vnl_determinant.h"
45 template<
typename T,
unsigned int NRows = 3,
unsigned int NColumns = 3 >
79 vnl_vector_fixed<T,NRows>
operator *(
const vnl_vector_fixed< T, NColumns > & vector)
const;
84 template<
unsigned int OuterDim>
102 vnl_matrix< T >
operator *(
const vnl_matrix< T > & matrix)
const;
108 void operator*=(
const vnl_matrix< T > & matrix);
111 vnl_vector< T >
operator *(
const vnl_vector< T > & matrix)
const;
148 inline const T &
operator()(
unsigned int row,
unsigned int col)
const
184 inline void Fill(
const T & value)
197 inline Matrix(
const vnl_matrix< T > & matrix)
207 for (
unsigned int r = 0; r < NRows; r++ )
209 for (
unsigned int c = 0; c < NColumns; c++ )
246 inline vnl_matrix_fixed< T, NColumns, NRows >
GetInverse(
void)
const
248 if ( vnl_determinant(
m_Matrix) == 0.0 )
250 itkGenericExceptionMacro(<<
"Singular matrix. Determinant is 0.");
252 vnl_matrix< T > temp = vnl_matrix_inverse< T >(
m_Matrix);
273 template<
typename T,
unsigned int NRows,
unsigned int NColumns >
274 std::ostream & operator<<(std::ostream & os, const Matrix< T, NRows, NColumns > & v)
276 os << v.GetVnlMatrix();
281 #ifndef ITK_MANUAL_INSTANTIATION
282 #include "itkMatrix.hxx"
const Self & operator=(const vnl_matrix< T > &matrix)
const Self & operator=(const InternalMatrixType &matrix)
A templated class holding a M x N size Matrix.
void operator*=(const T &value)
Matrix(const Self &matrix)
Self operator-(const Self &matrix) const
bool operator!=(const Self &matrix) const
vnl_matrix_fixed< T, NColumns, NRows > GetInverse(void) const
T & operator()(unsigned int row, unsigned int col)
vnl_matrix_fixed< T, NRows, NColumns > InternalMatrixType
const InternalMatrixType & GetVnlMatrix(void) const
InternalMatrixType m_Matrix
Vector< T, NRows > operator*(const Vector< T, NColumns > &vector) const
const Self & operator+=(const Self &matrix)
Self operator*(const T &value)
Matrix(const InternalMatrixType &matrix)
Matrix< T, NColumns, NColumns > CompatibleSquareMatrixType
const T & operator()(unsigned int row, unsigned int col) const
const Self & operator=(const Self &matrix)
vnl_matrix_fixed< T, NColumns, NRows > GetTranspose(void) const
Matrix< T, NRows, OuterDim > operator*(const vnl_matrix_fixed< T, NRows, OuterDim > &matrix) const
T * operator[](unsigned int i)
A templated class holding a n-Dimensional vector.
bool operator==(const Self &matrix) const
void operator*=(const CompatibleSquareMatrixType &matrix)
const Self & operator-=(const Self &matrix)
static const unsigned int ColumnDimensions
Self operator/(const T &value)
InternalMatrixType & GetVnlMatrix(void)
static const unsigned int RowDimensions
void Fill(const T &value)
Matrix(const vnl_matrix< T > &matrix)
Self operator+(const Self &matrix) const
Define additional traits for native types such as int or float.
A templated class holding a geometric point in n-Dimensional space.
A templated class holding a n-Dimensional covariant vector.
const T * operator[](unsigned int i) const
void operator/=(const T &value)