Public Member Functions | Protected Attributes
DiagonalCoeffs Class Reference

Expression of the main diagonal of a matrix. More...

List of all members.

Public Member Functions

const Scalar coeff (int row, int) const
const Scalar coeff (int index) const
Scalar & coeffRef (int row, int)
Scalar & coeffRef (int index)
int cols () const
 DiagonalCoeffs (const MatrixType &matrix)
int rows () const

Protected Attributes

const MatrixType::Nested m_matrix

Detailed Description

Expression of the main diagonal of a matrix.

Parameters:
MatrixTypethe type of the object in which we are taking the main diagonal

The matrix is not required to be square.

This class represents an expression of the main diagonal of a square matrix. It is the return type of MatrixBase::diagonal() and most of the time this is the only way it is used.

See also:
MatrixBase::diagonal()

Member Function Documentation

int cols ( void  ) const [inline]
Returns:
the number of columns.
See also:
rows(), ColsAtCompileTime

Reimplemented from MatrixBase< DiagonalCoeffs< MatrixType > >.

int rows ( void  ) const [inline]
Returns:
the number of rows.
See also:
cols(), RowsAtCompileTime

Reimplemented from MatrixBase< DiagonalCoeffs< MatrixType > >.


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