Vector.AddScaled<T> Method

Adds two vectors.

Definition

Namespace: Numerics.NET
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.7.0
C#
public static Vector<T> AddScaled<T>(
	Vector<T> left,
	T factor,
	Vector<T> right
)

Parameters

left  Vector<T>
The first vector.
factor  T
The scale factor for right.
right  Vector<T>
The second vector.

Type Parameters

T

Return Value

Vector<T>
A vector whose elements are the sum of the corresponding elements of left and right.

Remarks

If result is null, the operation chooses the result representation. Otherwise, result is overwritten, returned, and its representation is preserved. The result may alias either vector operand.

Exceptions

ArgumentNullException

left is null.

-or-

right is null.

DimensionMismatchException

left and right do not have the same length.

See Also