Applies a function to the elements of a matrix
and returns the result in a new matrix.
Namespace:
Extreme.Mathematics
Assembly:
Extreme.Numerics (in Extreme.Numerics.dll) Version: 8.1.1
public static Matrix<U> Map<T, U>(
Func<T, U> function,
Matrix<T> matrix
)
Public Shared Function Map(Of T, U) (
function As Func(Of T, U),
matrix As Matrix(Of T)
) As Matrix(Of U)
public:
generic<typename T, typename U>
static Matrix<U>^ Map(
Func<T, U>^ function,
Matrix<T>^ matrix
)
static member Map :
function : Func<'T, 'U> *
matrix : Matrix<'T> -> Matrix<'U>
Parameters
- function
- Type: SystemFuncT, U
A delegate that represents a function of one variable - matrix
- Type: Extreme.MathematicsMatrixT
A matrix whose elements
to apply function to.
Type Parameters
- T
- U
Return Value
Type:
MatrixUA new matrix.
Reference