Matrix<T>.AddScaledInPlace Method

Adds a scaled matrix to this matrix.

Definition

Namespace: Numerics.NET
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.2
C#
public virtual Matrix<T> AddScaledInPlace(
	T factor,
	Matrix<T> matrix
)

Parameters

factor  T
The scale factor for matrix.
matrix  Matrix<T>
The matrix to add.

Return Value

Matrix<T>
A reference to this instance.

Remarks

Using this method is more efficient than evaluating the equivalent expression using overloaded operators. In the latter case, two intermediate matrices are created. This method doesn't create any intermediate matrices.

Exceptions

ArgumentNullException

matrix is null.

DimensionMismatchException

The length of matrix does not equal the length of this instance.

See Also