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....



VectorDotProduct


Unit:SDL_openarrays
Class: none
Declaration: [1] function VectorDotProduct (Vec1, Vec2: TIntArray; var Product: ineger): integer;
[2] function VectorDotProduct (Vec1, Vec2: TDoubleArray; var Product: double): integer;

The function VectorDotProduct calculates the dot product of the two one-dimensional arrays Vec1 and Vec2 and returns the result in the variable Product.

The function returns the following error codes:

 0 ... everything is OK
-1 ... Vec1 or Vec2 has zero size
-2 ... Vec1 and Vec2 do not have the same lengths



Last Update: 2017-Nov-25