SCPPNT::Transpose_View< Array2D > Class Template Reference

Allows use of the transpose of a matrix without creating a new matrix. More...

#include <transv.h>

List of all members.

Public Types

typedef Array2D::size_type size_type
 Subscript type.
typedef Array2D::value_type value_type
 Type of elements stored in matrix.
typedef Array2D::element_type element_type
 Type of elements stored in matrix.
typedef Array2D::pointer pointer
 Pointer to type stored in matrix.
typedef Array2D::iterator iterator
 Iterator over elements in matrix.
typedef Array2D::reference reference
 Reference to type stored in matrix.
typedef Array2D::const_iterator const_iterator
 Iterator over elements in constant matrix.
typedef Array2D::const_reference const_reference
 Reference to type stored in constant matrix.
typedef
Array2D::const_column_iterator 
const_row_iterator
 Iterator over constant elements of a row.
typedef Array2D::const_row_iterator const_column_iterator
 Iterator over constant elements of a column.
typedef
Array2D::const_columns_iterator 
const_rows_iterator
 Iterator over row iterators (points to const_row_iterator object for a row).
typedef
Array2D::const_rows_iterator 
const_columns_iterator
 Iterator over column iterators (points to const_column_iterator object for a column).
typedef
Array2D::const_diag_iterator 
const_diag_iterator
 Iterator over constant elements of a matrix diagonal.

Public Member Functions

const Array2D & array () const
 Return matrix that is the basis of the transpose view.
Subscript num_rows () const
 Return number of rows in matrix.
Subscript num_columns () const
 Return number of columns in matrix.
Subscript lbound () const
 Returns lower bound of subscript.
Subscript dim (Subscript i) const
 Return number of rows if argument is 1, number of columns if argument is 2.
Subscript size () const
 Return total number of elements in matrix.
 Transpose_View (const Transpose_View< Array2D > &A)
 Copy constructor.
 Transpose_View (Array2D &A)
 Constructor from matrix.
const_row_iterator operator[] (Subscript i) const
 Return iterator to constant elements in row i+1 (0-offset).
const_reference operator() (Subscript i, Subscript j) const
 Return constant element in row i and column j, where i and j are 1-offset indices.
const_rows_iterator begin_rows () const
 Return iterator pointing to row iterator for first row (iterator over row iterators).
const_rows_iterator end_rows () const
 Return iterator pointing to row iterator for one past last row.
const_columns_iterator begin_columns () const
 Return iterator pointing to column iterator for first column (iterator over column iterators).
const_columns_iterator end_columns () const
 Return iterator pointing to column iterator for one past last column.
const_row_iterator begin_row (Subscript index) const
 Return iterator pointing to first element in row 'index' (1-offset).
const_row_iterator end_row (Subscript index) const
 Return iterator pointing to one past last element in row 'index' (1-offset).
const_column_iterator begin_column (Subscript index) const
 Return iterator pointing to first element in column 'index' (1-offset).
const_column_iterator end_column (Subscript index) const
 Return iterator pointing to one past last element in column 'index' (1-offset).
const_iterator begin () const
 Return iterator pointing to first element of matrix.
const_iterator end () const
 Return iterator pointing to one past last element of matrix.
const_diag_iterator begin_diagonal (Subscript row, Subscript column) const
 Returns iterator pointing to first element of a matrix diagonal.
const_diag_iterator end_diagonal (Subscript row, Subscript column) const


Detailed Description

template<class Array2D>
class SCPPNT::Transpose_View< Array2D >

Allows use of the transpose of a matrix without creating a new matrix.

This class allows working with a tranpose of a matrix without creating a new matrix containing the transpose. The transpose view is read-only. Only operations which do not change the content of the matrix can be performed with a transpose view.

Definition at line 74 of file transv.h.


Member Function Documentation

template<class Array2D>
const_diag_iterator SCPPNT::Transpose_View< Array2D >::begin_diagonal ( Subscript  row,
Subscript  column 
) const [inline]

Returns iterator pointing to first element of a matrix diagonal.

Parameters:
row is the row corresponding to the first element of the diagonal
column is the column corresponding to the first element of the diagonal

Definition at line 251 of file transv.h.

00252     {
00253       return A_.begin_diagonal(column, row);
00254     }

template<class Array2D>
const_diag_iterator SCPPNT::Transpose_View< Array2D >::end_diagonal ( Subscript  row,
Subscript  column 
) const [inline]

Returns iterator pointing to one past last element of matrix diagonal

Parameters:
row is the row corresponding to the first element of the diagonal
column is the column corresponding to the first element of the diagonal

Definition at line 261 of file transv.h.

00262     {
00263       return A_.end_diagonal(column, row);
00264     }


The documentation for this class was generated from the following file:
Generated on Tue Dec 18 23:34:48 2007 for SCPPNT by  doxygen 1.5.4