AccumulateMatrix

Declaration: AccumulateMatrix (var Mat: TDouble2DArray; Src: TDouble2DArray; Wgt: double): integer;
The function AccumulateMatrix adds the weighted matrix Src to the matrix Mat. The elements of the matrix Src are multiplied by weight factor Wgt before they are added to Mat. This way it is possible not only to add but also to subtract the matrix Src.

The function returns the following error codes:

 0 ... everything is OK
-1 ... Mat or Src has size zero
-2 ... Mat and Src are not equal in size