Matrix.Map Into<T, U, V>(Func<T, U, V>, Matrix<T>, Vector<U>, Dimension, Matrix<V>) Method
Applies a function to the corresponding elements of two matrices
and returns the result in a third matrix.
Definition
Namespace: Extreme.Mathematics
Assembly: Extreme.Numerics (in Extreme.Numerics.dll) Version: 8.1.23
C#
The result of applying function to the corresponding elements of first and second.
Assembly: Extreme.Numerics (in Extreme.Numerics.dll) Version: 8.1.23
public static Matrix<V> MapInto<T, U, V>(
Func<T, U, V> function,
Matrix<T> first,
Vector<U> second,
Dimension broadcastDimension,
Matrix<V> result
)
Parameters
- function Func<T, U, V>
- A delegate that represents a function of two variables
- first Matrix<T>
- A matrix whose elements serve as the first argument to the function.
- second Vector<U>
- A vector whose elements, broadcast in the dimension specified by broadcastDimension, serve as the second argument to the function.
- broadcastDimension Dimension
- A value that specifies whether the elements in second should be broadcast across rows or columns.
- result Matrix<V>
- The matrix that is to hold the result. May be null.
Type Parameters
- T
- U
- V
Return Value
Matrix<V>The result of applying function to the corresponding elements of first and second.
Exceptions
Argument | function is null.
-or- first is null -or- second is null |
Dimension | The number of rows of first does not equal the number of rows of second. -or- The number of columns of first does not equal the number of columns of second. |