ILNumerics Ultimate VSILMathcross Method (InArraySingle, InArraySingle, Boolean, NullableUInt32)ILNumerics Ultimate VS Documentation
ILNumerics - Technical Application Development
Computes the cross product along a dimension of two arrays.

[ILNumerics Computing Engine]

Namespace: ILNumerics
Assembly: ILNumerics.Computing (in ILNumerics.Computing.dll) Version: 5.3.0.0 (5.3.7131.2749)
Syntax

public static RetArray<float> cross(
	InArray<float> A,
	InArray<float> B,
	bool normalize = false,
	Nullable<uint> dimension = null
)

Parameters

A
Type: ILNumericsInArraySingle
First array.
B
Type: ILNumericsInArraySingle
Second array.
normalize (Optional)
Type: SystemBoolean
[Optional] If true: normalize resulting vectors to length 1.0. Default: false.
dimension (Optional)
Type: SystemNullableUInt32
[Optional] The working dimension. Default: (null) the first dimension of length 3.

Return Value

Type: RetArraySingle
Array with cross products of vectors from A and B.
Exceptions

ExceptionCondition
ArgumentExceptionIf the size of A and B is not the same or if either of A or B is null, if the working dimension could not be determined or if the determined workign dimension is not at least of length 3.
Remarks

A and B are expected to store the vectors inside the same respective dimensions. This dimension must be of length 3 or longer. If dimension is not specified the working dimension if found by searching for the first dimension of length 3, starting with dimension #0. If no dimension of length 3 is found, cross(InArraySingle, InArraySingle, Boolean, NullableUInt32) uses the first dimension which has more than 3 elements. If no such dimension is found either an exception is thrown.

The dimension argument allows to explicitly determine the index of the working dimension. The length of this dimension must be equal to or larger than 3. Both, A and B must be of the same size.

Elements in the working dimension with indices > #2 are ignored. Corresponding elements in the output array become 0.

[ILNumerics Computing Engine]

See Also

Reference