The SDL Component Suite is an industry leading collection of components supporting scientific and engineering computing. Please visit the SDL Web site for more information....



CopyToArrayColumn


Unit:SDL_openarrays
Class: none
Declaration: [1] function CopyToArrayColumn (SrcVec: TDoubleArray; FirstElem, LastELem, CellCol, CellRow: integer; var DstArr: TDouble2DArray): integer;
[2] function CopyToArrayColumn (SrcVec: TIntArray; FirstElem, LastELem, CellCol, CellRow: integer; var DstArr: TInt2DArray): integer;
[3] function CopyToArrayColumn (SrcVec: TBoolArray; FirstElem, LastELem, CellCol, CellRow: integer; var DstArr: TBool2DArray): integer;

The function CopyToArrayColumn copies the vector SrcVec into a column of the target array DstArr. The range of the copied cells is controlled by the parameters FirstElem and LastElem. Set FirstElem and LastElem to zero in order to copy the entire source vector. The first cell of the target array to be filled is specified by the parameters CellCol and CellRow. All other elements of the vector are copied into consecutive cells of column CellCol. Please note that all parameters are zero-based array indices.

The function returns the following error codes:

 0 ... everything is OK
-1 ... FirstElem and/or LastElem are outside the source vector
-2 ... CellCol and/or CellRow are outside of destination matrix


Last Update: 2023-Feb-06