#include <IpGenTMatrix.hpp>
Inheritance diagram for Ipopt::GenTMatrixSpace:
Public Member Functions | |
GenTMatrix * | MakeNewGenTMatrix () const |
Method for creating a new matrix of this specific type. | |
virtual Matrix * | MakeNew () const |
Overloaded MakeNew method for the MatrixSpace base class. | |
Constructors / Destructors | |
GenTMatrixSpace (Index nRows, Index nCols, Index nonZeros, const Index *iRows, const Index *jCols) | |
Constructor, given the number of rows and columns, as well as the number of nonzeros and the position of the nonzero elements. | |
~GenTMatrixSpace () | |
Destructor. | |
Methods describing Matrix structure | |
Index | Nonzeros () const |
Number of non-zeros in the sparse matrix. | |
const Index * | Irows () const |
Row index of each non-zero element (counting starts at 1). | |
const Index * | Jcols () const |
Column index of each non-zero element (counting starts at 1). | |
Private Member Functions | |
Number * | AllocateInternalStorage () const |
This method is only for the GenTMatrix to call in order to allocate internal storage. | |
void | FreeInternalStorage (Number *values) const |
This method is only for the GenTMatrix to call in order to de-allocate internal storage. | |
Private Attributes | |
Sparsity structure of matrices generated by this matrix | |
space. | |
const Index | nonZeros_ |
Index * | jCols_ |
Index * | iRows_ |
Friends | |
class | GenTMatrix |
The sparsity structure is stored here in the matrix space.
Definition at line 148 of file IpGenTMatrix.hpp.
Ipopt::GenTMatrixSpace::GenTMatrixSpace | ( | Index | nRows, | |
Index | nCols, | |||
Index | nonZeros, | |||
const Index * | iRows, | |||
const Index * | jCols | |||
) |
Constructor, given the number of rows and columns, as well as the number of nonzeros and the position of the nonzero elements.
Note that the counting of the nonzeros starts a 1, i.e., iRows[i]==1 and jCols[i]==1 refers to the first element in the first row. This is in accordance with the HSL data structure.
Ipopt::GenTMatrixSpace::~GenTMatrixSpace | ( | ) | [inline] |
GenTMatrix* Ipopt::GenTMatrixSpace::MakeNewGenTMatrix | ( | ) | const [inline] |
Method for creating a new matrix of this specific type.
Definition at line 173 of file IpGenTMatrix.hpp.
References GenTMatrix.
Referenced by MakeNew().
virtual Matrix* Ipopt::GenTMatrixSpace::MakeNew | ( | ) | const [inline, virtual] |
Overloaded MakeNew method for the MatrixSpace base class.
Implements Ipopt::MatrixSpace.
Definition at line 180 of file IpGenTMatrix.hpp.
References MakeNewGenTMatrix().
Index Ipopt::GenTMatrixSpace::Nonzeros | ( | ) | const [inline] |
Number of non-zeros in the sparse matrix.
Definition at line 188 of file IpGenTMatrix.hpp.
References nonZeros_.
Referenced by Ipopt::GenTMatrix::Nonzeros().
const Index* Ipopt::GenTMatrixSpace::Irows | ( | ) | const [inline] |
Row index of each non-zero element (counting starts at 1).
Definition at line 194 of file IpGenTMatrix.hpp.
References iRows_.
Referenced by Ipopt::GenTMatrix::Irows().
const Index* Ipopt::GenTMatrixSpace::Jcols | ( | ) | const [inline] |
Column index of each non-zero element (counting starts at 1).
Definition at line 200 of file IpGenTMatrix.hpp.
References jCols_.
Referenced by Ipopt::GenTMatrix::Jcols().
Number* Ipopt::GenTMatrixSpace::AllocateInternalStorage | ( | ) | const [private] |
This method is only for the GenTMatrix to call in order to allocate internal storage.
void Ipopt::GenTMatrixSpace::FreeInternalStorage | ( | Number * | values | ) | const [private] |
This method is only for the GenTMatrix to call in order to de-allocate internal storage.
friend class GenTMatrix [friend] |
const Index Ipopt::GenTMatrixSpace::nonZeros_ [private] |
Index* Ipopt::GenTMatrixSpace::jCols_ [private] |
Index* Ipopt::GenTMatrixSpace::iRows_ [private] |