Part of tmath
A generic view onto parts of a Matrix .
Public Types
Public Member Functions
Public Attributes
Detailed Description
A generic view onto parts of a Matrix .
Objects of this kind do not create a data buffer, but use the data buffer of an existing Matrix object. The object saves the indices of the part of the refered matrix object it refers to (start position and size). A matrix block may represent a view onto
the whole matrix
columns
rows
arbitrary submatrices
Matrix blocks themeselves behave like Matrix objects. Most of the operators and some external functions are defined. You can even assign values to the block (which in turn will change the data of the referred matrix).
By using a reference counting system it is guaranteed that the refered object will not be deleted before the MatrixBlock is deleted.
Constructor & Destructor Documentation
MatrixBlock() [1/4]
INTERNAL USE!!!!
Do never use this constructor. Is needed by SWIG only!
MatrixBlock() [2/4]
destructor,
copy constructor
Parameters
MatrixBlock() [3/4]
constructor from Matrix
Parameters
MatrixBlock() [4/4]
constructor from full Matrix
Parameters
Member Function Documentation
__neg__()
Returns
unary minus (B=-A) Used by SWIG.
__str__()
transforms this objects into a string, required by SWIG
Returns
a string
Add() [1/2]
modifies this matrix by the matrix sum A+B
Parameters
Add() [2/2]
modifies this matrix by the matrix sum A+B
Parameters
Assign()
The assignment operator (copy by value)
Parameters
Block()
returns a reference to a block starting at ‘row’,‘column’ with size ‘numrows’*‘numcols’
Parameters
Returns
a matrix block serving as a reference to the specified matrix part
Col()
returns a reference to the ‘col’th column
Parameters
Returns
a matrix block serving as a reference to the column
Cols() [1/2]
Returns
the number of cols
Cols() [2/2]
returns a block containing the ncol columns starting at column index col1
Parameters
Returns
a matrix block serving as a reference to the specified matrix part
Div()
modifies this matrix by the scalar matrix quotient A/s
Parameters
IsApprox() [1/2]
returns true if other and this are approx. identical
Parameters
Returns
the result of the operation
IsApprox() [2/2]
returns true if other and this are approx. identical
Parameters
Returns
the result of the operation
IsApproxToConstant()
returns true if array is constant and approx. equal s
Parameters
Returns
the result of the operation
IsDiagonal()
returns true if array is a diagonal matrix by precision s
Parameters
Returns
the result of the operation
IsIdentity()
returns true if array is the identity matrix by precision s
Parameters
Returns
the result of the operation
IsLowerTriangular()
returns true if array is a lower triangular matrix by precision s
Parameters
Returns
the result of the operation
IsScalar()
Returns
true if array is a scalar
IsUnitary()
returns true if array is a unitary matrix by precision s (is an orthonormal basis)
Parameters
Returns
the result of the operation
IsUpperTriangular()
returns true if array is an upper triangular matrix by precision s
Parameters
Returns
the result of the operation
IsVector()
Returns
true if array is a vector
IsZero()
Returns
true if array is a zero matrix by precision s
Parameters
MinCoeff()
find the smallest element in the array
Returns
returns the minimum element in the array
Parameters
Mul()
modifies this matrix by the scalar matrix product A*s
Parameters
operator*() [1/3]
returns the matrix product A*B
Parameters
Returns
the result of the operation
operator*() [2/3]
returns the matrix product A*B
Parameters
Returns
the result of the operation
operator*() [3/3]
returns the scalar matrix product A*s
Parameters
Returns
the result of the operation
operator+() [1/2]
returns the matrix sum A+B
Parameters
Returns
the result of the operation
operator+() [2/2]
returns the matrix sum A+B
Parameters
Returns
the result of the operation
operator-() [1/2]
returns the matrix difference A-B
Parameters
Returns
the result of the operation
operator-() [2/2]
returns the matrix difference A-B
Parameters
Returns
the result of the operation
operator/()
returns the scalar matrix quotient A/s
Parameters
Returns
the result of the operation
operator<()
returns a matrix of 1 and 0 indicating which element is less than x
Parameters
Returns
the result of the operation
Row()
returns a reference to the ‘row’th row
Parameters
Returns
a matrix block serving as a reference to the row
Rows() [1/2]
Returns
the number of rows
Rows() [2/2]
returns a block containing the nrow columns starting at column index row1
Parameters
Returns
a matrix block serving as a reference to the specified matrix part
SetConstant()
initializes the matrix with constant values
Parameters
SetLinearCols()
initializes the matrix with linear columns
Parameters
SetLinearRows()
initializes the matrix with linear rows
Parameters
Sub() [1/2]
modifies this matrix by the matrix difference A-B
Parameters
Sub() [2/2]
modifies this matrix by the matrix difference A-B
Parameters
Transpose()
Returns
the transpose
Member Data Documentation
int
find the largest element in the array
Returns
returns the maximum element in the array
Parameters