ILNumerics Ultimate VS

ILMathfind32 Method (BaseArraySingle, Int32, Boolean, OutArrayInt32, OutArraySingle)

ILNumerics Ultimate VS Documentation
ILNumerics - Technical Application Development
Find sequential indices of non-zero elements in n-d array, searches from start to end in column major order.

[ILNumerics Computing Engine]

Namespace:  ILNumerics
Assembly:  ILNumerics.Computing (in ILNumerics.Computing.dll) Version: 5.5.0.0 (5.5.7503.3146)
Syntax

public static RetArray<int> find32(
	BaseArray<float> A,
	int n = 0,
	bool backwards = false,
	OutArray<int> C = null,
	OutArray<float> V = null
)

Parameters

A
Type: ILNumericsBaseArraySingle
Source array.
n (Optional)
Type: SystemInt32
[Optional] Maximum number of non-zero elements to find32. Default: (0) find32 all non-zero elements.
backwards (Optional)
Type: SystemBoolean
[Optional] Search direction backwards. Default: (false) start at the first element and search to the last element of A.
C (Optional)
Type: ILNumericsOutArrayInt32
[Optional] If non-null on entry: the function returns the row indices and gives column indices in C. Default: (null) the function returns the sequential indices of elements found only.
V (Optional)
Type: ILNumericsOutArraySingle
[Optional] Return the found non-zero element values in V. Default: (null) don't return the values.

Return Value

Type: RetArrayInt32
Sequential, column major ordered indices of the non-zero-valued elements in A or row indices if C is not null.
Remarks

If C or V are not null on entry they are filled with the requested respective info as column vectors. If C is not null it contains the column indices of non-zero values. If A has more than two dimensions subsequent dimensions are merged into the second dimension and the indices given in C are considered sequential indices of A (column major order).

Note, that the array returned by find32(BaseArraySingle, Int32, Boolean, OutArrayInt32, OutArraySingle) corresponds to the indices of the rows of non-zero values if C is not null and to sequential indices of those non-zero values if C is null.

Negative values of n are considered as abs(n).

If backwards is true find32(BaseArraySingle, Int32, Boolean, OutArrayInt32, OutArraySingle) starts searching for non-zero values from the last element and proceeds in column major order to the first element or until n non-zero elements were found, whatever comes first.

Find() returns and considers indices as 64 bit Int32. Overloads exist for backwards compatibility which expect indices as Int32 values. Such functions are decorated with the suffix '32' in their names.

[ILNumerics Computing Engine]

See Also

Reference