Overload List
| # | Signature | Description |
|---|---|---|
| 1 | function Size(const Src: TMtxVecBase; const aFloatPrecision: TMtxFloatPrecision): TMtxVec; | Sets sparse matrix size to match Src with new aFloatPrecision. |
| 2 | function Size(const Src: TMtxVecBase; AComplex: Boolean): TMtxVec; | The size of sparse matrix. |
| 3 | procedure Size(const RowCount: Integer; const ColCount: Integer; const NonZeroCount: Integer; const aFloatPrecision: TMtxFloatPrecision); | Define sparse matrix size in single pass. |
| 4 | function Size(const Src: TMtxVecBase): TMtxVec; | Size the object. |
Overload 1: function Size(const Src: TMtxVecBase; const aFloatPrecision: TMtxFloatPrecision): TMtxVec;
Sets sparse matrix size to match Src with new aFloatPrecision.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TMtxVecBase | |
| 2 | aFloatPrecision | TMtxFloatPrecision |
Result: stored in self (calling object), returns self for chaining
Overload 2: function Size(const Src: TMtxVecBase; AComplex: Boolean): TMtxVec;
The size of sparse matrix.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TMtxVecBase | |
| 2 | AComplex | Boolean |
Result: stored in self (calling object), returns self for chaining
Defines the calling matrix size to match those of the AMtxVec objects. If AComplex is true, calling sparse matrix TMtxVec.Complex property is set to true.
SparseA.Size(3,4,5,false);
// is the same as calling this sequence
SparseA.Complex := false;
SparseA.Rows := 3;
SparseA.Cols := 4;
SparseA.NonZeros := 5;
Overload 3: procedure Size(const RowCount: Integer; const ColCount: Integer; const NonZeroCount: Integer; const aFloatPrecision: TMtxFloatPrecision);
Define sparse matrix size in single pass.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | RowCount | Integer | |
| 2 | ColCount | Integer | |
| 3 | NonZeroCount | Integer | |
| 4 | aFloatPrecision | TMtxFloatPrecision |
Result: stored in self (calling object)
Define the sparse matrix size to RowCount TSparseMtx.Rows, ColCount TSparseMtx.Cols, NonZeroCount non-zero elements (the TSparseMtx.NonZeros property) and define the matrix to be complex if IsComplex is true.
Overload 4: function Size(const Src: TMtxVecBase): TMtxVec;
Size the object.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TMtxVecBase | source TVec, TMtx, TVecInt or TMtxInt |
Result: stored in self (calling object), returns self for chaining
Assignes the size of the Src object to the calling object. If the calling object is a TVec object then the Src can be of any type, otherwise TMtx can only obtain size from a TMtx object and TSparseMtx can only obtain size from a TSparseMtx object.
If the calling object and Src are of different types, the complex property can be different, if both objects have a matching TMtxVecBase.Length property. In this case only the Complex property of the calling object will changed, while all other properties describing the size of the object (rows, cols, length, nonZeros) will be preserved. This is different from simply setting the Complex property. Changing the Complex property directly would also change the Length, Cols and NonZeros properties.
A.Rows := 10000; // matrix size = 0
A.Cols := 1; // matrix size = 10000
// ...
A.Cols := 10000; // matrix size = 100 000 000 (problems here)
A.Rows := 1; // matrix size = 10 000