Overload List
| # | Signature | Description |
|---|---|---|
| 1 | procedure Adopt(AArray: PAPointer; ARows, ACols: integer; aFloatPrecision: TMtxFloatPrecision); overload; | |
| 2 | procedure Adopt(AArray: PAPointer; ARows, ACols: integer; aIsComplex: boolean; aIsDouble: boolean); overload; | Adopts a pointer to one dimensional array. |
| 3 | procedure Adopt(const Src: TMtx); overload; | Adopts TMtx object. |
Overload 1: procedure Adopt(AArray: PAPointer; ARows, ACols: integer; aFloatPrecision: TMtxFloatPrecision); overload;
| # | Name | Type | Description |
|---|---|---|---|
| 1 | AArray | PAPointer | |
| 2 | ARows | integer | |
| 3 | ACols | integer | |
| 4 | aFloatPrecision | TMtxFloatPrecision |
Result: stored in self (calling object)
Overload 2: procedure Adopt(AArray: PAPointer; ARows, ACols: integer; aIsComplex: boolean; aIsDouble: boolean); overload;
Adopts a pointer to one dimensional array.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | AArray | PAPointer | |
| 2 | ARows | integer | |
| 3 | ACols | integer | |
| 4 | aIsComplex | Boolean | |
| 5 | aIsDouble | Boolean |
Result: stored in self (calling object)
Remarks:
Addopts a pointer to AArray array. The method sets the calling matrix TMtxVec.Complex property to aFloatPrecision, Matrix.Rows to ARows, Matrix.Cols to ACols and Values1D and CValues1D to Pointer(AArray).
Notes:
- Required to call the Matrix.Disown method, before freeing the object
- Do not resize the matrix
- Do not call routines relying on Lapack when cross-platform "Core edition" is used (not linking dlls), because pascal version of Lapack will assume that adopted memory is a dynamic array and will modify array Index -2.
- TMtx.Values1D array assignment or passing array by var (internal to library) will cause memory corruption in this case.
- To be used with great care only.
Overload 3: procedure Adopt(const Src: TMtx); overload;
Adopts TMtx object.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Src | TMtx | source TMtx |
Result: stored in self (calling object)
Remarks:
Src object will be adopted by Matrix. When the Matrix gets out of scope, the object will be freed.