|
NTPoly
|
#include <TripletList.h>
Public Member Functions | |
| TripletList (int size=0) | |
| TripletList (const DistributedSparseMatrix &matrix) | |
| void | Resize (int size) |
| void | Append (const Triplet &value) |
| void | SetTripletAt (int index, const Triplet &value) |
| Triplet | GetTripletAt (int index) const |
| int | GetSize () const |
| ~TripletList () | |
| Standard destructor. | |
Static Public Member Functions | |
| static void | SortTripletList (const TripletList &list, int matrix_columns, TripletList &sorted) |
Friends | |
| class | SparseMatrix |
| class | DistributedSparseMatrix |
A data type for a list of triplets. As this is related to matrix multiplication, the referencing indices are rows and columns.
| NTPoly::TripletList::TripletList | ( | int | size = 0 | ) |
Construct the triplet list.
| size | the size of the list. |
| NTPoly::TripletList::TripletList | ( | const DistributedSparseMatrix & | matrix | ) |
Construct a triplet list from a distributed sparse matrix.
| matrix | to construct from. |
| void NTPoly::TripletList::Append | ( | const Triplet & | value | ) |
Add a value to the end of the triplet list.
| value | the triplet value to append. |
| int NTPoly::TripletList::GetSize | ( | ) | const |
Get the number of entries in a triplet list.
| Triplet NTPoly::TripletList::GetTripletAt | ( | int | index | ) | const |
Get the triplet value at a given index.
| index | location to get the triplet at. |
| void NTPoly::TripletList::Resize | ( | int | size | ) |
Increase the size of a triplet list.
| size | the new size. |
| void NTPoly::TripletList::SetTripletAt | ( | int | index, |
| const Triplet & | value | ||
| ) |
Set a triplet value.
| index | location to set the triplet at. |
| value | the triplet value to set. |
|
static |
Sort a triplet list
| list | to be sorted. |
| matrix_columns | this is the highest column value in the list |
| sorted | a now sorted version of the list. |
1.8.14