Vector.SubAndMul Method

Overload List

#SignatureDescription
1function SubAndMul(const X: TMtxVec; const Y: TCplx; const Z: TCplx): TMtxVec;self = (X - yScalar)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TCplx; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;
2function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TCplx; const Z: TCplx): TMtxVec;self = (X*xScale - yScalar)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TCplx; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;
3function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TCplx; const Z: TMtxVec): TMtxVec;self = (X*xScale - yScalar)*Z
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TCplx; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;
4function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TCplx; const Z: TMtxVec; const zScale: TCplx): TMtxVec;self = (X*xScale - yScalar)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TCplx; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;
5function SubAndMul(const X: TMtxVec; const Y: TCplx; const Z: TMtxVec): TMtxVec;self = (X - yScalar)*Z
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TCplx; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;
6function SubAndMul(const X: TMtxVec; const Y: TCplx; const Z: TMtxVec; const zScale: TCplx): TMtxVec;self = (X - yScalar)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TCplx; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;
7function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TMtxVec; const yScale: TCplx; const Z: TCplx): TMtxVec;self = (X*xScale - Y*yScale)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TMtxVec; YIndex: Integer; const yScale: TCplx; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;
8function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TMtxVec; const yScale: TCplx; const Z: TMtxVec; const zScale: TCplx): TMtxVec;self = (X*xScale - Y*yScale)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TMtxVec; YIndex: Integer; const yScale: TCplx; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;
9function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: TCplx): TMtxVec;self = (X - Y)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;
10function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const yScale: TCplx; const Z: TCplx): TMtxVec;self = (X - Y*yScale)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const yScale: TCplx; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;
11function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const yScale: TCplx; const Z: TMtxVec; const zScale: TCplx): TMtxVec;self = (X - Y*yScale)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const yScale: TCplx; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;
12function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: TMtxVec): TMtxVec;self = (X - Y)*Z
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;
13function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: TMtxVec; const zScale: TCplx): TMtxVec;self = (X - Y)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;
14function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: TMtxVec; const zScale: Double): TMtxVec;self = (X - Y)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;
15function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: Double): TMtxVec;self = (X - Y)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: Double; Index: Integer; Len: Integer): TMtxVec;
16function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const yScale: Double; const Z: TMtxVec; const zScale: Double): TMtxVec;self = (X - Y*yScale)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const yScale: Double; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;
17function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const yScale: Double; const Z: Double): TMtxVec;self = (X - Y*yScale)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const yScale: Double; const Z: Double; Index: Integer; Len: Integer): TMtxVec;
18function SubAndMul(const X: TMtxVec; const Y: Double; const Z: TMtxVec): TMtxVec;self = (X - yScalar)*Z
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: Double; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;
19function SubAndMul(const X: TMtxVec; const Y: Double; const Z: TMtxVec; const zScale: Double): TMtxVec;self = (X - yScalar)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: Double; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;
20function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: TMtxVec; const yScale: Double; const Z: TMtxVec; const zScale: Double): TMtxVec;self = (X*xScale - Y*yScale)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: TMtxVec; YIndex: Integer; const yScale: Double; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;
21function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: TMtxVec; const yScale: Double; const Z: Double): TMtxVec;self = (X*xScale - Y*yScale)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: TMtxVec; YIndex: Integer; const yScale: Double; const Z: Double; Index: Integer; Len: Integer): TMtxVec;
22function SubAndMul(const X: TMtxVec; const Y: Double; const Z: Double): TMtxVec;self = (X - yScalar)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: Double; const Z: Double; Index: Integer; Len: Integer): TMtxVec;
23function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: Double; const Z: TMtxVec): TMtxVec;self = (X*xScale - yScalar)*Z
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: Double; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;
24function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: Double; const Z: TMtxVec; const zScale: Double): TMtxVec;self = (X*xScale - yScalar)*Z*zScale
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: Double; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;
25function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: Double; const Z: Double): TMtxVec;self = (X*xScale - yScalar)*zScalar
└ indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: Double; const Z: Double; Index: Integer; Len: Integer): TMtxVec;

Overload 1: function SubAndMul(const X: TMtxVec; const Y: TCplx; const Z: TCplx): TMtxVec;

Compute (X - yScalar)*zScalar

#NameTypeDescription
1XTMtxVec
2YTCplx
3ZTCplx

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TCplx; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X - yScalar)*zScalar on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTCplx
4ZTCplx
5IndexIntegerstart index
6LenIntegerelement count

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

Overload 2: function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TCplx; const Z: TCplx): TMtxVec;

Compute (X*xScale - yScalar)*zScalar

#NameTypeDescription
1XTMtxVec
2xScaleTCplx
3YTCplx
4ZTCplx

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TCplx; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - yScalar)*zScalar on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleTCplx
4YTCplx
5ZTCplx
6IndexIntegerstart index
7LenIntegerelement count

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

Overload 3: function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TCplx; const Z: TMtxVec): TMtxVec;

Compute (X*xScale - yScalar)*Z

#NameTypeDescription
1XTMtxVec
2xScaleTCplx
3YTCplx
4ZTMtxVec

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TCplx; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - yScalar)*Z on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleTCplx
4YTCplx
5ZTMtxVec
6zIndexInteger
7IndexIntegerstart index
8LenIntegerelement count

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

Overload 4: function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TCplx; const Z: TMtxVec; const zScale: TCplx): TMtxVec;

Compute (X*xScale - yScalar)*Z*zScale

#NameTypeDescription
1XTMtxVec
2xScaleTCplx
3YTCplx
4ZTMtxVec
5zScaleTCplx

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TCplx; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - yScalar)*Z*zScale on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleTCplx
4YTCplx
5ZTMtxVec
6zIndexInteger
7zScaleTCplx
8IndexIntegerstart index
9LenIntegerelement count

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

Overload 5: function SubAndMul(const X: TMtxVec; const Y: TCplx; const Z: TMtxVec): TMtxVec;

Compute (X - yScalar)*Z

#NameTypeDescription
1XTMtxVec
2YTCplx
3ZTMtxVec

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TCplx; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;

Compute (X - yScalar)*Z on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTCplx
4ZTMtxVec
5zIndexInteger
6IndexIntegerstart index
7LenIntegerelement count

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

Overload 6: function SubAndMul(const X: TMtxVec; const Y: TCplx; const Z: TMtxVec; const zScale: TCplx): TMtxVec;

Compute (X - yScalar)*Z*zScale

#NameTypeDescription
1XTMtxVec
2YTCplx
3ZTMtxVec
4zScaleTCplx

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TCplx; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X - yScalar)*Z*zScale on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTCplx
4ZTMtxVec
5zIndexInteger
6zScaleTCplx
7IndexIntegerstart index
8LenIntegerelement count

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

Overload 7: function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TMtxVec; const yScale: TCplx; const Z: TCplx): TMtxVec;

Compute (X*xScale - Y*yScale)*zScalar

#NameTypeDescription
1XTMtxVec
2xScaleTCplx
3YTMtxVec
4yScaleTCplx
5ZTCplx

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TMtxVec; YIndex: Integer; const yScale: TCplx; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - Y*yScale)*zScalar on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleTCplx
4YTMtxVec
5YIndexIntegerY start index
6yScaleTCplx
7ZTCplx
8IndexIntegerstart index
9LenIntegerelement count

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

Overload 8: function SubAndMul(const X: TMtxVec; const xScale: TCplx; const Y: TMtxVec; const yScale: TCplx; const Z: TMtxVec; const zScale: TCplx): TMtxVec;

Compute (X*xScale - Y*yScale)*Z*zScale

#NameTypeDescription
1XTMtxVec
2xScaleTCplx
3YTMtxVec
4yScaleTCplx
5ZTMtxVec
6zScaleTCplx

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: TCplx; const Y: TMtxVec; YIndex: Integer; const yScale: TCplx; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - Y*yScale)*Z*Scale on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleTCplx
4YTMtxVec
5YIndexIntegerY start index
6yScaleTCplx
7ZTMtxVec
8zIndexInteger
9zScaleTCplx
10IndexIntegerstart index
11LenIntegerelement count

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

Overload 9: function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: TCplx): TMtxVec;

Compute (X - Y)*zScalar

#NameTypeDescription
1XTMtxVec
2YTMtxVec
3ZTCplx

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Z, A1, A2, A3: Vector;
    yScalar: Double;
begin
    yScalar := 2.0;
    X := [1,2,3,4];
    Z := [3,3,3,3];
    A1 := (X - yScalar) * Z;
    A2 := SubAndMul(X, yScalar, Z);
    A3.SubAndMul(X, yScalar, Z);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X - Y)*zScalar on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTMtxVec
4YIndexIntegerY start index
5ZTCplx
6IndexIntegerstart index
7LenIntegerelement count

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

Overload 10: function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const yScale: TCplx; const Z: TCplx): TMtxVec;

Compute (X - Y*yScale)*zScalar

#NameTypeDescription
1XTMtxVec
2YTMtxVec
3yScaleTCplx
4ZTCplx

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const yScale: TCplx; const Z: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X - Y*yScale)*zScalar on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTMtxVec
4YIndexIntegerY start index
5yScaleTCplx
6ZTCplx
7IndexIntegerstart index
8LenIntegerelement count

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

Overload 11: function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const yScale: TCplx; const Z: TMtxVec; const zScale: TCplx): TMtxVec;

Compute (X - Y*yScale)*Z*zScale

#NameTypeDescription
1XTMtxVec
2YTMtxVec
3yScaleTCplx
4ZTMtxVec
5zScaleTCplx

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Y, A1, A2, A3: Vector;
    zScalar: Double;
begin
    zScalar := 3.0;
    X := [5,6,7,8];
    Y := [1,2,3,4];
    A1 := (X - Y) * zScalar;
    A2 := SubAndMul(X, Y, zScalar);
    A3.SubAndMul(X, Y, zScalar);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const yScale: TCplx; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X - Y*yScale)*Z*zScale on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTMtxVec
4YIndexIntegerY start index
5yScaleTCplx
6ZTMtxVec
7zIndexInteger
8zScaleTCplx
9IndexIntegerstart index
10LenIntegerelement count

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Z, A1, A2, A3: Vector;
    yScalar, zScale: Double;
begin
    yScalar := 2.0;
    zScale  := 4.0;
    X := [1,2,3,4];
    Z := [2,2,2,2];
    A1 := (X - yScalar) * Z * zScale;
    A2 := SubAndMul(X, yScalar, Z, zScale);
    A3.SubAndMul(X, yScalar, Z, zScale);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Overload 12: function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: TMtxVec): TMtxVec;

Compute (X - Y)*Z

#NameTypeDescription
1XTMtxVec
2YTMtxVec
3ZTMtxVec

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Y, Z, A1, A2, A3: Vector;
    xScale, yScale, zScale: Double;
begin
    xScale := 1.0;
    yScale := 2.0;
    zScale := 3.0;
    X := [1,2,3,4];
    Y := [2,3,4,5];
    Z := [3,4,5,6];
    A1 := (X * xScale - Y * yScale) * Z * zScale;
    A2 := SubAndMul(X, xScale, Y, yScale, Z, zScale);
    A3.SubAndMul(X, xScale, Y, yScale, Z, zScale);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;

Compute (X + Y)*Z on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTMtxVec
4YIndexIntegerY start index
5ZTMtxVec
6zIndexInteger
7IndexIntegerstart index
8LenIntegerelement count

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Y, A1, A2, A3: Vector;
    xScale, yScale, zScalar: Double;
begin
    xScale := 1.0;
    yScale := 2.0;
    zScalar := 3.0;
    X := [1,2,3,4];
    Y := [2,3,4,5];
    A1 := (X * xScale - Y * yScale) * zScalar;
    A2 := SubAndMul(X, xScale, Y, yScale, zScalar);
    A3.SubAndMul(X, xScale, Y, yScale, zScalar);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Overload 13: function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: TMtxVec; const zScale: TCplx): TMtxVec;

Compute (X - Y)*Z*zScale

#NameTypeDescription
1XTMtxVec
2YTMtxVec
3ZTMtxVec
4zScaleTCplx

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, A1, A2, A3: Vector;
    xScale, yScalar, zScalar: Double;
begin
    xScale := 1.0;
    yScalar := 2.0;
    zScalar := 3.0;
    X := [1,2,3,4];
    A1 := (X * xScale - yScalar) * zScalar;
    A2 := SubAndMul(X, xScale, yScalar, zScalar);
    A3.SubAndMul(X, xScale, yScalar, zScalar);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: TMtxVec; zIndex: Integer; const zScale: TCplx; Index: Integer; Len: Integer): TMtxVec;

Compute (X - Y)*Z*zScale on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTMtxVec
4YIndexIntegerY start index
5ZTMtxVec
6zIndexInteger
7zScaleTCplx
8IndexIntegerstart index
9LenIntegerelement count

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Y, Z, A1, A2, A3: Vector;
    zScale: Double;
begin
    zScale := 3.0;
    X := [5,6,7,8];
    Y := [1,2,3,4];
    Z := [2,2,2,2];
    A1 := (X - Y) * Z * zScale;
    A2 := SubAndMul(X, Y, Z, zScale);
    A3.SubAndMul(X, Y, Z, zScale);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Overload 14: function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: TMtxVec; const zScale: Double): TMtxVec;

Compute (X - Y)*Z*zScale

#NameTypeDescription
1XTMtxVec
2YTMtxVec
3ZTMtxVec
4zScaleDouble

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Z, A1, A2, A3: Vector;
    xScale, yScalar, zScale: Double;
begin
    xScale := 1.0;
    yScalar := 2.0;
    zScale := 3.0;
    X := [1,2,3,4];
    Z := [3,4,5,6];
    A1 := (X * xScale - yScalar) * Z * zScale;
    A2 := SubAndMul(X, xScale, yScalar, Z, zScale);
    A3.SubAndMul(X, xScale, yScalar, Z, zScale);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X - Y)*Z*zScale on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTMtxVec
4YIndexIntegerY start index
5ZTMtxVec
6zIndexInteger
7zScaleDouble
8IndexIntegerstart index
9LenIntegerelement count

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Y, Z, A1, A2, A3: Vector;
begin
    X := [5,6,7,8];
    Y := [1,2,3,4];
    Z := [2,2,2,2];
    A1 := (X - Y) * Z;
    A2 := SubAndMul(X, Y, Z);
    A3.SubAndMul(X, Y, Z);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Overload 15: function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const Z: Double): TMtxVec;

Compute (X - Y)*zScalar

#NameTypeDescription
1XTMtxVec
2YTMtxVec
3ZDouble

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Z, A1, A2, A3: Vector;
    xScale, yScalar: Double;
begin
    xScale := 2.0;
    yScalar := 3.0;
    X := [1,2,3,4];
    Z := [2,2,2,2];
    A1 := (X * xScale - yScalar) * Z;
    A2 := SubAndMul(X, xScale, yScalar, Z);
    A3.SubAndMul(X, xScale, yScalar, Z);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const Z: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X - Y)*zScalar on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTMtxVec
4YIndexIntegerY start index
5ZDouble
6IndexIntegerstart index
7LenIntegerelement count

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, A1, A2, A3: Vector;
    yScalar, zScalar: Double;
begin
    yScalar := 2.0;
    zScalar := 3.0;
    X := [1,2,3,4];
    A1 := (X - yScalar) * zScalar;
    A2 := SubAndMul(X, yScalar, zScalar);
    A3.SubAndMul(X, yScalar, zScalar);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Overload 16: function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const yScale: Double; const Z: TMtxVec; const zScale: Double): TMtxVec;

Compute (X - Y*yScale)*Z*zScale

#NameTypeDescription
1XTMtxVec
2YTMtxVec
3yScaleDouble
4ZTMtxVec
5zScaleDouble

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Y, Z, A1, A2, A3: Vector;
    yScale, zScale: Double;
begin
    yScale := 1.5;
    zScale := 2.0;
    X := [5,6,7,8];
    Y := [1,2,3,4];
    Z := [2,2,2,2];
    A1 := (X - Y * yScale) * Z * zScale;
    A2 := SubAndMul(X, yScale, Y, yScale, Z, zScale);  // Parameter order adapted to your implementation
    A3.SubAndMul(X, yScale, Y, yScale, Z, zScale);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const yScale: Double; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X - Y*yScale)*Z*zScale on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTMtxVec
4YIndexIntegerY start index
5yScaleDouble
6ZTMtxVec
7zIndexInteger
8zScaleDouble
9IndexIntegerstart index
10LenIntegerelement count

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

Examples
uses MtxVec, MtxExpr, Math387;

var
    X, Y, A1, A2, A3: Vector;
    yScale, zScalar: Double;
begin
    yScale := 0.5;
    zScalar := 3.0;
    X := [1,2,3,4];
    Y := [2,4,6,8];
    // Compute (X - (Y * 0.5)) * 3
    A1 := (X - Y * yScale) * zScalar;
    A2 := SubAndMul(X, yScale, Y, zScalar);
    A3.SubAndMul(X, yScale, Y, zScalar);
    if not A2.IsEqual(A1) then ERaise('Problem');
    if not A3.IsEqual(A1) then ERaise('Problem');
end;

Overload 17: function SubAndMul(const X: TMtxVec; const Y: TMtxVec; const yScale: Double; const Z: Double): TMtxVec;

Compute (X - Y*yScale)*zScalar

#NameTypeDescription
1XTMtxVec
2YTMtxVec
3yScaleDouble
4ZDouble

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: TMtxVec; YIndex: Integer; const yScale: Double; const Z: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X - Y*yScale)*zScalar on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YTMtxVec
4YIndexIntegerY start index
5yScaleDouble
6ZDouble
7IndexIntegerstart index
8LenIntegerelement count

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

Overload 18: function SubAndMul(const X: TMtxVec; const Y: Double; const Z: TMtxVec): TMtxVec;

Compute (X - yScalar)*Z

#NameTypeDescription
1XTMtxVec
2YDouble
3ZTMtxVec

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: Double; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;

Compute (X - yScalar)*Z on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YDouble
4ZTMtxVec
5zIndexInteger
6IndexIntegerstart index
7LenIntegerelement count

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

Overload 19: function SubAndMul(const X: TMtxVec; const Y: Double; const Z: TMtxVec; const zScale: Double): TMtxVec;

Compute (X - yScalar)*Z*zScale

#NameTypeDescription
1XTMtxVec
2YDouble
3ZTMtxVec
4zScaleDouble

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: Double; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X - yScalar)*Z*zScale on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YDouble
4ZTMtxVec
5zIndexInteger
6zScaleDouble
7IndexIntegerstart index
8LenIntegerelement count

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

Overload 20: function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: TMtxVec; const yScale: Double; const Z: TMtxVec; const zScale: Double): TMtxVec;

Compute (X*xScale - Y*yScale)*Z*zScale

#NameTypeDescription
1XTMtxVec
2xScaleDouble
3YTMtxVec
4yScaleDouble
5ZTMtxVec
6zScaleDouble

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: TMtxVec; YIndex: Integer; const yScale: Double; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - Y*yScale)*Z*Scale on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleDouble
4YTMtxVec
5YIndexIntegerY start index
6yScaleDouble
7ZTMtxVec
8zIndexInteger
9zScaleDouble
10IndexIntegerstart index
11LenIntegerelement count

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

Overload 21: function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: TMtxVec; const yScale: Double; const Z: Double): TMtxVec;

Compute (X*xScale - Y*yScale)*zScalar

#NameTypeDescription
1XTMtxVec
2xScaleDouble
3YTMtxVec
4yScaleDouble
5ZDouble

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: TMtxVec; YIndex: Integer; const yScale: Double; const Z: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - Y*yScale)*zScalar on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleDouble
4YTMtxVec
5YIndexIntegerY start index
6yScaleDouble
7ZDouble
8IndexIntegerstart index
9LenIntegerelement count

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

Overload 22: function SubAndMul(const X: TMtxVec; const Y: Double; const Z: Double): TMtxVec;

Compute (X - yScalar)*zScalar

#NameTypeDescription
1XTMtxVec
2YDouble
3ZDouble

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const Y: Double; const Z: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X - yScalar)*zScalar on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3YDouble
4ZDouble
5IndexIntegerstart index
6LenIntegerelement count

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

Overload 23: function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: Double; const Z: TMtxVec): TMtxVec;

Compute (X*xScale - yScalar)*Z

#NameTypeDescription
1XTMtxVec
2xScaleDouble
3YDouble
4ZTMtxVec

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: Double; const Z: TMtxVec; zIndex: Integer; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - yScalar)*Z on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleDouble
4YDouble
5ZTMtxVec
6zIndexInteger
7IndexIntegerstart index
8LenIntegerelement count

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

Overload 24: function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: Double; const Z: TMtxVec; const zScale: Double): TMtxVec;

Compute (X*xScale - yScalar)*Z*zScale

#NameTypeDescription
1XTMtxVec
2xScaleDouble
3YDouble
4ZTMtxVec
5zScaleDouble

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: Double; const Z: TMtxVec; zIndex: Integer; const zScale: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - yScalar)*Z*zScale on sub-array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleDouble
4YDouble
5ZTMtxVec
6zIndexInteger
7zScaleDouble
8IndexIntegerstart index
9LenIntegerelement count

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

Overload 25: function SubAndMul(const X: TMtxVec; const xScale: Double; const Y: Double; const Z: Double): TMtxVec;

Compute (X*xScale - yScalar)*zScalar

#NameTypeDescription
1XTMtxVec
2xScaleDouble
3YDouble
4ZDouble

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

Indexed: function SubAndMul(const X: TMtxVec; XIndex: Integer; const xScale: Double; const Y: Double; const Z: Double; Index: Integer; Len: Integer): TMtxVec;

Compute (X*xScale - yScalar)*zScalar on sub array

#NameTypeDescription
1XTMtxVec
2XIndexIntegerX start index
3xScaleDouble
4YDouble
5ZDouble
6IndexIntegerstart index
7LenIntegerelement count

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