#include <matrixBD.h>
Inheritance diagram for MatrixBD:

Public Methods | |
| virtual void | stream (ostream& s) |
| output to stream. | |
| MatrixBD | transpose () const |
| return transposed Matrix. | |
| void | multiply (const MatrixBD& A, const MatrixBD& B, const char TRANSA='N', const char TRANSB='N') |
| Multiplication of two symmetric matrices destroys the symmetry. | |
| void | multiply (const VectorD& x, VectorD& y, const char TRANS='N', const double ALPHA=1.0, const double BETA=0.0) const |
| multiplication y=alpha*op(this)*x+beta*y, BLAS level 2. | |
| void | multiply (const double value) |
| multiply with a constant value and write to this. | |
| void | LUdecompose (int* IPIV) |
| LU decomposition of a general banded matrix, see note above. | |
| void | LUsubstitute (MatrixC<double>& B, int* IPIV) |
| solve triangular system by backsubstitution IPIV is an integer vector of order nc() that contains row column permutations. | |
| void | LUsolve (MatrixC<double>& B) |
| solve linear equation system. | |
| void | LUinvert () |
| inversion of a general banded matrix is not implemented. | |
| void | CHdecompose () |
| Cholesky CTC decomposition of a symmetric positive definite band matrix. | |
| void | CHsubstitute (MatrixC<double>& B) |
| solve triangular Cholesky system by backsubstitution. | |
| void | CHsolve (MatrixC<double>& B) |
| solve linear equation system with a symmetric positive definite banded matrix. | |
| void | CHinvert () |
| inversion of a symmetric positive definite matrix is not implemented. | |
constructors and destructor | |
| MatrixBD () | |
| default constructor. | |
| MatrixBD (const int nr, const int nc, const int nu, const double value=0.0) | |
| standard constructor. | |
| MatrixBD (const int nr, const int nc=1, const double value=0.0) | |
| standard constructor for the case of a symmetric band Matrix. | |
| MatrixBD (const MatrixBD& B) | |
| copy constructor. | |
| ~MatrixBD () | |
| virtual destructor. | |
| MatrixBD& | operator= (const double value) |
| assignment with a constant value. | |
overloaded virtual methods of the Matrix base class | |
| int | nr () const |
| number of rows, i.e. bandwith. | |
| int | nr (const int j) const |
| number of rows for column j. | |
| int | nc () const |
| number of columns. | |
| int | nc (const int i) const |
| number of columns for row i. | |
| void | resize (const int nr, const int nc, const double value=0) |
| resize Matrix. | |
| virtual Ref<double> | operator() (const int i, const int j=0) |
| non constant, write access to elements. | |
| virtual double | operator() (const int i, const int j=0) const |
| constant, read only access to elements is overloaded. | |
some special methods of general banded matrices | |
| int | row_begin (const int j) const |
| first element in column j. | |
| int | row_end (const int j) const |
| end element in column j. | |
| int | col_begin (const int i) const |
| first element in row i. | |
| int | col_end (const int i) const |
| end element in row i. | |
| int | ku () const |
| number of superdiagonals. | |
| int | kl () const |
| number of subdiagonals. | |
Protected Methods | |
| double* | ref (const int i, const int j) const |
| low level reference to data returns a pointer, use this with care. | |
| double | read (const int i, const int j) const |
| low level read. | |
| void | write (const int i, const int j, const double v) |
| low level write. | |
| void | add (const int i, const int j, const double v) |
| low level add to. | |
| void | sub (const int i, const int j, const double v) |
| low level sub from. | |
| void | mul (const int i, const int j, const double v) |
| low level mul with. | |
| void | div (const int i, const int j, const double v) |
| low level div by. | |
The Matrix is stored with kl subdiagonals and ku superdiagonals so that nr=ku+kl+1 and elements can be referenced directly. In the case of ku being 0 it is assumed that the Matrix is banded symmetric and that only the lower half is stored. The case of kl=0 is not implemented. Access outside the matrix band will be punished with an error message and program halt. During LU decomposition of a general nonsymmetric banded matrix kl rows are added to the matrix and the matrix contents is shifted appropriately.
|
|
default constructor.
|
|
|
standard constructor.
|
|
|
standard constructor for the case of a symmetric band Matrix.
|
|
|
copy constructor.
|
|
|
virtual destructor.
|
|
|
assignment with a constant value.
|
|
|
number of rows, i.e. bandwith.
|
|
|
number of rows for column j.
Reimplemented from MatrixC. |
|
|
number of columns.
|
|
|
number of columns for row i.
Reimplemented from MatrixC. |
|
|
resize Matrix.
|
|
|
non constant, write access to elements.
Reimplemented from MatrixC. |
|
|
constant, read only access to elements is overloaded.
Reimplemented from MatrixC. |
|
|
first element in column j.
|
|
|
end element in column j.
|
|
|
first element in row i.
|
|
|
end element in row i.
|
|
|
number of superdiagonals.
|
|
|
number of subdiagonals.
|
|
|
low level reference to data returns a pointer, use this with care.
Reimplemented from MatrixC. |
|
|
low level read.
Reimplemented from MatrixC. |
|
|
low level write.
|
|
|
low level add to.
|
|
|
low level sub from.
|
|
|
low level mul with.
|
|
|
low level div by.
|
|
|
output to stream.
Reimplemented from MatrixC. |
|
|
return transposed Matrix.
Reimplemented from MatrixC. |
|
|
Multiplication of two symmetric matrices destroys the symmetry.
|
|
|
multiplication y=alpha*op(this)*x+beta*y, BLAS level 2.
|
|
|
multiply with a constant value and write to this.
|
|
|
LU decomposition of a general banded matrix, see note above.
|
|
|
solve triangular system by backsubstitution IPIV is an integer vector of order nc() that contains row column permutations.
|
|
|
solve linear equation system.
|
|
|
inversion of a general banded matrix is not implemented.
|
|
|
Cholesky CTC decomposition of a symmetric positive definite band matrix.
|
|
|
solve triangular Cholesky system by backsubstitution.
|
|
|
solve linear equation system with a symmetric positive definite banded matrix.
|
|
|
inversion of a symmetric positive definite matrix is not implemented.
|
1.2.1 written by Dimitri van Heesch,
© 1997-2000