Matrix.SetIt Method

Overload List

#SignatureDescription
1TMtxVec SetIt(Int32 Index, Double[] A)Sets object values.
2TMtx SetIt(Int32 ARows, Int32 ACols, Boolean AComplex, Double[] A)Sets matrix values.
3TMtxVec SetIt(Int32 Index, Int32 AIndex, Int32 Len, Double[] A)The elements of A array, starting at aIndex, are copied to the calling object elements, starting at Index.

Overload 1: TMtxVec SetIt(Int32 Index, Double[] A)

Sets object values.

#NameTypeDescription
1IndexInt32start index
2ADouble[]

Result: stored in self (calling object), returns self for chaining

Remarks:

Set object values. Method call does not change object's size or Dew.Math.Matrix.Complex property, but it does check for array overrun. The elements of A array are copied to the calling object elements, starting at Index. If the calling object is complex, then real parts of complex numbers are on even (0,2,4..) and imaginary parts on odd indexes.(1,3,5,..).

Overload 2: TMtx SetIt(Int32 ARows, Int32 ACols, Boolean AComplex, Double[] A)

Sets matrix values.

#NameTypeDescription
1ARowsInt32
2AColsInt32
3AComplexBoolean
4ADouble[]

Result: stored in self (calling object), returns self for chaining

Remarks:

Sets matrix values. This method gives you the possibility to pass large arrays of elements without having to declare constant arrays. Pass all elements in A array to the calling matrix. The Dew.Math.Matrix.Rows and Dew.Math.Matrix.Cols properties of the calling matrix are set to ARows and ACols and the Dew.Math.Matrix.Complex property is set to AComplex. An exception is raised if the matrix size (ARows*ACols) does not match the number of complex numbers in A.

Examples
Matrix A;
A.SetIt(2,2,false,[1,2,
2,4]);
See Also: Matrix.SetVal

Overload 3: TMtxVec SetIt(Int32 Index, Int32 AIndex, Int32 Len, Double[] A)

The elements of A array, starting at aIndex, are copied to the calling object elements, starting at Index.

#NameTypeDescription
1IndexInt32start index
2AIndexInt32start index
3LenInt32element count
4ADouble[]

Result: stored in self (calling object), returns self for chaining

Remarks:

If the calling object is complex, then real parts of complex numbers in the A array are on even (0,2,4..) and imaginary parts on odd indexes.(1,3,5,..).